[None][chore] AutoDeploy: Refactor finegrained FP8 scale sharding helpers#12999
Conversation
|
/bot run --stage-list "DGX_B200-4_GPUs-AutoDeploy-1, DGX_H100-4_GPUs-AutoDeploy-1, DGX_H100-4_GPUs-AutoDeploy-Post-Merge-1,DGX_B200-8_GPUs-AutoDeploy-Post-Merge-1" |
|
PR_Github #43042 [ run ] triggered by Bot. Commit: |
📝 WalkthroughWalkthroughRefactored FineGrained FP8 weight sharding logic by extracting a centralized Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes 🚥 Pre-merge checks | ✅ 1 | ❌ 2❌ Failed checks (1 warning, 1 inconclusive)
✅ Passed checks (1 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
tests/unittest/auto_deploy/multigpu/transformations/library/test_tp_sharding.py (1)
128-177: Please add adim=1/ MoE regression case.This test only exercises
dim=0, but the refactor also routes_tp_shard_moe_scale()through_get_sharded_scale()for row-shardedw_downexperts. A bug in thedim=1branch would still pass this suite.🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@tests/unittest/auto_deploy/multigpu/transformations/library/test_tp_sharding.py` around lines 128 - 177, Add a new test variant invoking FineGrainedFP8WeightShardingInfo._get_sharded_scale with dim=1 to cover MoE/w_down expert row-sharded paths: reuse the existing test logic but transpose the role of rows/columns (or create weight_original_m analog) and assert both aligned (compact) and non-aligned (per-item expansion) behaviors, and include the edge case where size is not divisible by block_n (clamping to last scale row); also add a specific case that routes through _tp_shard_moe_scale by constructing inputs that mimic row-sharded w_down experts so any bug in the dim=1 branch fails the test.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Nitpick comments:
In
`@tests/unittest/auto_deploy/multigpu/transformations/library/test_tp_sharding.py`:
- Around line 128-177: Add a new test variant invoking
FineGrainedFP8WeightShardingInfo._get_sharded_scale with dim=1 to cover
MoE/w_down expert row-sharded paths: reuse the existing test logic but transpose
the role of rows/columns (or create weight_original_m analog) and assert both
aligned (compact) and non-aligned (per-item expansion) behaviors, and include
the edge case where size is not divisible by block_n (clamping to last scale
row); also add a specific case that routes through _tp_shard_moe_scale by
constructing inputs that mimic row-sharded w_down experts so any bug in the
dim=1 branch fails the test.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: ca7f5a1b-ba62-4449-a596-66267562a05d
📒 Files selected for processing (2)
tensorrt_llm/_torch/auto_deploy/transform/library/sharding.pytests/unittest/auto_deploy/multigpu/transformations/library/test_tp_sharding.py
|
PR_Github #43042 [ run ] completed with state
|
0be96a1 to
1e552c2
Compare
|
/bot run --stage-list "DGX_B200-4_GPUs-AutoDeploy-1, DGX_H100-4_GPUs-AutoDeploy-1, DGX_H100-4_GPUs-AutoDeploy-Post-Merge-1,DGX_B200-8_GPUs-AutoDeploy-Post-Merge-1" |
|
PR_Github #44167 [ run ] triggered by Bot. Commit: |
|
PR_Github #44167 [ run ] completed with state
|
|
/bot run --extra-stage "DGX_B200-4_GPUs-AutoDeploy-1, DGX_H100-4_GPUs-AutoDeploy-1, DGX_H100-4_GPUs-AutoDeploy-Post-Merge-1,DGX_B200-8_GPUs-AutoDeploy-Post-Merge-1" |
|
PR_Github #44215 [ run ] triggered by Bot. Commit: |
|
PR_Github #44215 [ run ] completed with state
|
|
/bot run --stage-list "DGX_B200-4_GPUs-AutoDeploy-1, DGX_H100-4_GPUs-AutoDeploy-1, DGX_H100-4_GPUs-AutoDeploy-Post-Merge-1,DGX_B200-8_GPUs-AutoDeploy-Post-Merge-1" |
|
PR_Github #44317 [ run ] triggered by Bot. Commit: |
|
PR_Github #44317 [ run ] completed with state
|
|
/bot run --stage-list "DGX_B200-4_GPUs-AutoDeploy-1, DGX_H100-4_GPUs-AutoDeploy-1, DGX_H100-4_GPUs-AutoDeploy-Post-Merge-1,DGX_B200-8_GPUs-AutoDeploy-Post-Merge-1" |
|
PR_Github #44395 [ run ] triggered by Bot. Commit: |
|
PR_Github #44395 [ run ] completed with state
|
|
/bot run --stage-list "DGX_B200-4_GPUs-AutoDeploy-1, DGX_H100-4_GPUs-AutoDeploy-1, DGX_H100-4_GPUs-AutoDeploy-Post-Merge-1,DGX_B200-8_GPUs-AutoDeploy-Post-Merge-1" |
|
PR_Github #44449 [ run ] triggered by Bot. Commit: |
|
PR_Github #44449 [ run ] completed with state
|
|
/bot run --stage-list "DGX_B200-4_GPUs-AutoDeploy-1, DGX_H100-4_GPUs-AutoDeploy-1, DGX_H100-4_GPUs-AutoDeploy-Post-Merge-1,DGX_B200-8_GPUs-AutoDeploy-Post-Merge-1" |
|
PR_Github #44480 [ run ] triggered by Bot. Commit: |
|
/bot run |
|
PR_Github #45089 [ run ] triggered by Bot. Commit: |
|
PR_Github #45089 [ run ] completed with state
|
|
/bot run |
|
PR_Github #45173 [ run ] triggered by Bot. Commit: |
|
PR_Github #45173 [ run ] completed with state
|
|
/bot kill |
|
PR_Github #45228 [ kill ] triggered by Bot. Commit: |
|
PR_Github #45228 [ kill ] completed with state |
Minor refactor, follow up on NVIDIA#12593 Signed-off-by: Gal Hubara Agam <96368689+galagam@users.noreply.github.com>
Add test_functional_small to TestNemotronSuperV3 which overrides num_hidden_layers (and layers_block_type) via model_kwargs to fit the model on a single GPU. This provides pre-merge coverage for large models that otherwise only run in multi-GPU CI. Signed-off-by: Gal Hubara Agam <96368689+galagam@users.noreply.github.com>
75b1a71 to
2cb3001
Compare
|
/bot run --stage-list "DGX_B200-4_GPUs-AutoDeploy-1, DGX_H100-4_GPUs-AutoDeploy-1, DGX_H100-4_GPUs-AutoDeploy-Post-Merge-1,DGX_B200-8_GPUs-AutoDeploy-Post-Merge-1" |
|
PR_Github #45235 [ run ] triggered by Bot. Commit: |
|
PR_Github #45235 [ run ] completed with state |
|
/bot run |
|
PR_Github #45379 [ run ] triggered by Bot. Commit: |
|
PR_Github #45379 [ run ] completed with state
|
|
/bot run |
|
PR_Github #45441 [ run ] triggered by Bot. Commit: |
|
PR_Github #45441 [ run ] completed with state
|
|
/bot run --disable-fail-fast |
|
PR_Github #45554 [ run ] triggered by Bot. Commit: |
|
PR_Github #45554 [ run ] completed with state
|
|
/bot run |
|
PR_Github #45592 [ run ] triggered by Bot. Commit: |
|
PR_Github #45592 [ run ] completed with state |
…pers (NVIDIA#12999) Signed-off-by: Gal Hubara Agam <96368689+galagam@users.noreply.github.com>
@CodeRabbit description
Description
Technical debt PR:
Test Coverage
PR Checklist
Please review the following before submitting your PR:
PR description clearly explains what and why. If using CodeRabbit's summary, please make sure it makes sense.
PR Follows TRT-LLM CODING GUIDELINES to the best of your knowledge.
Test cases are provided for new code paths (see test instructions)
Any new dependencies have been scanned for license and vulnerabilities
CODEOWNERS updated if ownership changes
Documentation updated as needed
Update tava architecture diagram if there is a significant design change in PR.
The reviewers assigned automatically/manually are appropriate for the PR.
Please check this after reviewing the above items as appropriate for this PR.
GitHub Bot Help
To see a list of available CI bot commands, please comment
/bot help.