Add multi MIG GPU support in release-v1.3 as fix for #1586#1589
Draft
Tishwings wants to merge 1 commit into
Draft
Add multi MIG GPU support in release-v1.3 as fix for #1586#1589Tishwings wants to merge 1 commit into
Tishwings wants to merge 1 commit into
Conversation
…he max device count from torch (incl MIGs)
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
fix for #1586 in release-v1.3
Summary of changes
This PR improves support for NVIDIA MIG GPU devices by determining the maximum number of devices from both NVML and the CUDA runtime (torch). This ensures MIG instances are recognized correctly, even when CUDA exposes more devices than NVML.
Key points:
Device count now uses the maximum from NVML and torch (torch::cuda::device_count()), allowing proper enumeration of MIG instances.
Device mapping and validation now reference this unified count.
Instead of errors when too many CUDA_VISIBLE_DEVICES are specified, a warning is logged for more robust operation.
Deprecated NVML API warnings (CUDA 13+) are suppressed to reduce CI/CD build noise.
Why error suppression is needed
Suppressing NVML deprecation warnings is necessary because newer CUDA versions (13+) produce many build warnings due to outdated, but still required, APIs. This keeps our build logs clean and avoids unnecessary alarm for unavoidable warnings.
Next steps (out of scope for this PR)
Proper validation should include tests on hardware other than ours, including different MIG and non-MIG GPUs. Migrating to future NVIDIA APIs for device management would also be recommended once available. For now, these improvements safely extend current support for us without risking regressions elsewhere.