-
Notifications
You must be signed in to change notification settings - Fork 806
[CI] Add workflow verifying build against minimum supported PyTorch and JAX #3396
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Draft
pggPL
wants to merge
15
commits into
NVIDIA:main
Choose a base branch
from
pggPL:pytorch21_build_ci
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+105
−6
Draft
Changes from all commits
Commits
Show all changes
15 commits
Select commit
Hold shift + click to select a range
3875204
Add CI workflow building TE against torch 2.1
pggPL fba3898
Remove MAX_JOBS=1 from pytorch 2.1 build workflow
pggPL 3b600dd
Use MAX_JOBS=2 in pytorch 2.1 workflow, unbounded build OOMs the runner
pggPL dce613c
Point TE build at apt cudnn9, torch 2.1 pip deps shadow it with cudnn…
pggPL 061834f
Avoid passing std::optional to at::get_generator_or_default, torch 2.…
pggPL 32a28ef
Gate NCCL EP in torch extension on nccl_ep_enabled, matching common C…
pggPL 04b4b0f
Pass comm streams as raw cudaStream_t handles, torch 2.1 pybind lacks…
pggPL 4a3ad66
Revert "Pass comm streams as raw cudaStream_t handles, torch 2.1 pybi…
pggPL 2087bd0
Revert "Avoid passing std::optional to at::get_generator_or_default, …
pggPL 690701a
Retarget CI workflow to torch 2.8
pggPL 7b7c6be
Rename workflow to Minimum supported PyTorch, parametrize torch version
pggPL b86e86c
Add Minimum supported JAX job, rename workflow to minimum_versions
pggPL 12f725f
Add packaging to min-jax job deps
pggPL f094de7
Skip NCCL EP in torch extension when torch lacks symm-mem headers; bu…
pggPL 98324dd
Fix min-versions jobs: pydantic for jax import, libcuda stub for sm90…
pggPL File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,83 @@ | ||
| # Copyright (c) 2022-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved. | ||
| # | ||
| # See LICENSE for license information. | ||
|
|
||
| # Verify that TE builds and imports against the minimum supported framework versions. | ||
| name: 'Minimum supported versions' | ||
| on: | ||
| pull_request: | ||
| workflow_dispatch: | ||
| concurrency: | ||
| group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | ||
| cancel-in-progress: true | ||
| env: | ||
| MIN_TORCH_VERSION: "2.8.0" | ||
| MIN_JAX_VERSION: "0.5.3" | ||
| jobs: | ||
| min-pytorch: | ||
| name: 'Minimum supported PyTorch' | ||
| runs-on: ubuntu-latest | ||
| container: | ||
| image: nvcr.io/nvidia/cuda:12.8.0-devel-ubuntu22.04 | ||
| options: --user root | ||
| steps: | ||
| - name: 'Dependencies' | ||
| run: | | ||
| apt-get update | ||
| apt-get install -y --allow-change-held-packages git python3.9 pip cudnn9-cuda-12 libnccl-dev libnccl2 | ||
| pip install torch==${MIN_TORCH_VERSION} | ||
| pip install cmake pybind11[global] ninja pydantic importlib-metadata>=1.0 packaging einops onnxscript "nvidia-cudnn-frontend>=1.25.0" | ||
| - name: 'Checkout' | ||
| uses: actions/checkout@v3 | ||
| with: | ||
| submodules: recursive | ||
| - name: ccache | ||
| uses: mozilla-actions/sccache-action@7d986dd989559c6ecdb630a3fd2557667be217ad | ||
| - name: 'Build' | ||
| run: NVTE_USE_CCACHE=1 NVTE_CCACHE_BIN=sccache pip install --no-build-isolation --no-deps . -v | ||
| env: | ||
| NVTE_FRAMEWORK: pytorch | ||
| # Single arch to keep memory/build size down; sm90 so the NCCL EP | ||
| # path (and its torch-version gate) is exercised | ||
| NVTE_CUDA_ARCHS: "90" | ||
| # Prefer apt cudnn9 headers over the pip nvidia-cudnn-cu12 copy | ||
| CUDNN_INCLUDE_PATH: /usr/include/x86_64-linux-gnu | ||
| CUDNN_LIBRARY_PATH: /usr/lib/x86_64-linux-gnu | ||
| # Full parallelism OOMs the 7GB runner (exit 137) | ||
| MAX_JOBS: 2 | ||
| SCCACHE_GHA_ENABLED: "true" | ||
| - name: 'Sanity check' | ||
| # No GPU driver on the runner; the sm90 build links libcuda via NCCL EP | ||
| run: | | ||
| ln -s /usr/local/cuda/lib64/stubs/libcuda.so /usr/lib/x86_64-linux-gnu/libcuda.so.1 | ||
| python3 tests/pytorch/test_sanity_import.py | ||
| min-jax: | ||
| name: 'Minimum supported JAX' | ||
| runs-on: ubuntu-latest | ||
| container: | ||
| image: nvcr.io/nvidia/cuda:12.8.0-devel-ubuntu22.04 | ||
| options: --user root | ||
| steps: | ||
| - name: 'Dependencies' | ||
| run: | | ||
| apt-get update | ||
| apt-get install -y git python3.9 pip cudnn9-cuda-12 | ||
| pip install jax==${MIN_JAX_VERSION} "flax>=0.7.1" | ||
| pip install cmake pybind11[global] ninja packaging pydantic "nvidia-cudnn-frontend>=1.25.0" | ||
| - name: 'Checkout' | ||
| uses: actions/checkout@v3 | ||
| with: | ||
| submodules: recursive | ||
| - name: ccache | ||
| uses: mozilla-actions/sccache-action@7d986dd989559c6ecdb630a3fd2557667be217ad | ||
| - name: 'Build' | ||
| run: NVTE_USE_CCACHE=1 NVTE_CCACHE_BIN=sccache pip install --no-build-isolation --no-deps . -v | ||
| env: | ||
| NVTE_FRAMEWORK: jax | ||
| NVTE_CUDA_ARCHS: "70" | ||
| CUDNN_INCLUDE_PATH: /usr/include/x86_64-linux-gnu | ||
| CUDNN_LIBRARY_PATH: /usr/lib/x86_64-linux-gnu | ||
| MAX_JOBS: 2 | ||
| SCCACHE_GHA_ENABLED: "true" | ||
| - name: 'Sanity check' | ||
| run: python3 tests/jax/test_sanity_import.py | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The new workflow executes
actions/checkout@v3as root before recursively fetching and building the repository. Pinning the action to a full commit would prevent the reviewed CI dependency from changing when its upstream tag moves or is compromised.Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!