Skip to content

Commit f79fa5e

Browse files
authored
Add mamba and megatron related build packages to no-build-isolation. (#579)
* Add mamba and megatron related build packages to `no-build-isolation`. * Update `CONTRIBUTING.md` to show how to fix cloud/local CI fingerpint mismatch.
1 parent 3990b66 commit f79fa5e

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ These checks are automatically run in CI for all pull requests. If your PR fails
4141

4242
The PR `prek` workflow uses a prebuilt full `uv` cache (stored as a GitHub release asset) to avoid rebuilding heavy dependencies on every run.
4343

44-
To refresh the cache after dependency changes, run:
44+
To refresh the cache after dependency changes, ensure your branch is rebased or merged with main, or checkout the PR merge branch, then run:
4545

4646
```bash
4747
bash scripts/ci/build_and_push_uv_cache.sh

pyproject.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -124,14 +124,14 @@ required-version = ">=0.6.15"
124124
# numpy>=2 on Python 3.9+, but megatron-core requires numpy<2.
125125
override-dependencies = ["transformer-engine>=2.11.0", "numpy<2"]
126126
exclude-dependencies = ["pynvml"]
127-
no-build-isolation-package = ["apex", "transformer-engine-torch", "nv-grouped-gemm"]
127+
no-build-isolation-package = ["apex", "transformer-engine", "transformer-engine-cu12", "transformer-engine-torch", "megatron-core", "megatron-bridge", "nv-grouped-gemm", "mamba-ssm", "causal-conv1d"]
128128

129129
[tool.uv.extra-build-dependencies]
130130
apex = ["torch>=2.8.0"]
131131
transformer-engine-torch = ["torch>=2.8.0"]
132132

133133
[tool.uv.extra-build-variables]
134-
apex = { APEX_CPP_EXT = "1", APEX_CUDA_EXT = "1", APEX_FAST_LAYER_NORM = "1", APEX_PARALLEL_BUILD = "1", NVCC_APPEND_FLAGS = "--threads 1" }
134+
apex = { APEX_CPP_EXT = "1", APEX_CUDA_EXT = "1", APEX_FAST_LAYER_NORM = "1", APEX_PARALLEL_BUILD = "16", NVCC_APPEND_FLAGS = "--threads 4" }
135135

136136
[tool.ty.environment]
137137
python-version = "3.11"

0 commit comments

Comments
 (0)