NVIDIA-NeMo / NVIDIA-NeMo/Automodel

Not always able to find Python extension suffix when compiling megatron helpers

Open
#887 0 comments 0 reactions 1 assignee View on GitHub

@thomasdhc is already working on this.

Since Dec 1, 2025.

bug
Dominant language
Python
Stars
963
Forks
318
Avg merge
3d 20h
Merged PRs (30d)
141

Description

Related to https://github.com/NVIDIA-NeMo/Automodel/pull/798, while attempting to run the examples/llm_pretrain/pretrain.py example with the examples/llm_pretrain/megatron_pretrain_gpt2.yaml configuration file, I ran into a compilation error when building C++ helpers.

I was running on Databricks, where python3-config, as needed here:

https://github.com/NVIDIA-NeMo/Automodel/blob/ecc8b919078ba02d58e3abe813ce2c84820fe249/nemo_automodel/components/datasets/llm/megatron/Makefile#L5

isn't present but python3.11-config is.

As a workaround I was able to add this symlink

ln -s /usr/bin/python3.11-config /usr/bin/python3-config

which resolved the compilation error.

It'd be nice if Automodel was able to handle this case out of the box (perhaps with some fallback behavior if python3-config doesn't exist)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.