Skip to content

[CI] Disable TF32 for the L0 PyTorch numerics tests - #3797

Open
bvolpato wants to merge 1 commit into
NVIDIA:mainfrom
bvolpato:bvolpato/disable-tf32-in-l0-numerics
Open

bvolpato wants to merge 1 commit into
NVIDIA:mainfrom
bvolpato:bvolpato/disable-tf32-in-l0-numerics

Conversation

@bvolpato

@bvolpato bvolpato commented Nov 3, 2026

Copy link
Copy Markdown

Description

Make the L0 PyTorch numerics tests give the same result outside the CI image.

Transformer Engine selects TF32 for pure FP32 GEMM, and the PyTorch references in these tests do not use it. Where cuBLAS takes the TF32 path, FP32 cases in test_numerics.py and tests/pytorch/debug/test_numerics.py fail on correct code, because the differences exceed the FP32 tolerances. The launchers already set NVIDIA_TF32_OVERRIDE=0 for test_mhc.py for the same reason.

Type of change

  • Documentation change (change only to the documentation, either a fix or a new content)
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Infra/Build change
  • Code refactoring

Changes

  • Set NVIDIA_TF32_OVERRIDE=0 for the numerics tests in qa/L0_pytorch_unittest/test.sh and qa/L0_pytorch_debug_unittest/test.sh.

Validation

Both launcher versions ran on NVIDIA B200 with CUDA 13.2, PyTorch 2.15.0+cu132, and no override in the environment. Without this change, FP32 cases fail in the test_numerics.py command, and the debug launcher exits with an error. With this change, the test_numerics.py command finds no failures, and the debug launcher exits successfully. test_numerics.py shows the same failures on the same cases with PyTorch 2.11 and 2.13, and the override removes them.

The environment of the CI image was not visible, so the reason that these tests pass there without this variable is not known. If the image already disables TF32, this change has no effect in CI. A100 and H100 were not tested.

Checklist:

  • I have read and followed the contributing guidelines
  • The functionality is complete
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

Transformer Engine selects TF32 for pure FP32 GEMM, and the PyTorch
references in the numerics tests do not. Where cuBLAS uses TF32, the FP32
cases fail on correct code. These launchers already set
NVIDIA_TF32_OVERRIDE=0 for test_mhc.py for the same reason.

Set it for the numerics tests too, so that the L0 launchers give the same
result outside the CI image.

Signed-off-by: Bruno Volpato <brunocvcunha@gmail.com>
@github-actions github-actions Bot added the community-contribution PRs from external contributor outside the core maintainers, representing community-driven work. label Nov 3, 2026
@bvolpato
bvolpato marked this pull request as ready for review November 3, 2026 02:53
@greptile-apps

greptile-apps Bot commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[Low impact] The PR appears safe to merge.

Summary

Disables TF32 for three numerics test commands across the two L0 PyTorch launchers.

  • L0 numerics tests now run with TF32 disabled.

Reviews (1) · Last reviewed commit: "[CI] Disable TF32 for the L0 PyTorch num..." · Reviewed by Greptile

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

community-contribution PRs from external contributor outside the core maintainers, representing community-driven work.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant