-
Notifications
You must be signed in to change notification settings - Fork 582
fix(post_train): Fix Tunix is_update_step signature and Qwix LoRA FSDP mesh sharding #4866
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
RexBearIU
wants to merge
18
commits into
main
Choose a base branch
from
jackyf/fix-post-train-regressions
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.
Draft
Changes from all commits
Commits
Show all changes
18 commits
Select commit
Hold shift + click to select a range
88334d0
Fix Tunix is_update_step compatibility and Qwix LoRA FSDP mesh shardi…
RexBearIU 4dfd80a
refactor: remove **kwargs and use explicit parameter list in train_step
RexBearIU 3d553f6
refactor: encapsulate mesh dimension parsing inside _prepare_dummy_in…
RexBearIU 36c76c5
fix(e2e): Remove hardcoded ici_fsdp_parallelism=64 from test_gpt_oss.…
RexBearIU ccc3ba7
fix(e2e): Install torchvision for qwen3-vl tests
RexBearIU 5ba1a0a
fix(e2e): Adjust gemma3-4b logit check max_kl_div tolerance to 0.05
RexBearIU b084039
fix(e2e): add checkpoint_period=1 to qwen3-vl-2b multimodal sft
RexBearIU 8275719
Remove redundant checkpoint_period=1 from qwen3 multimodal sft test
RexBearIU c2c4c37
Keep checkpoint_period=1 for qwen3 multimodal sft step 4 decode
RexBearIU 7b5e642
Allow kwargs in MaxTextPeftTrainer train_step
RexBearIU 8f49b3b
fix(test_gemma4_to_mt): add matmul_precision=highest to forward_pass_…
RexBearIU 15fd9b0
Directly use is_update_step in train_sft and remove redundant checkpo…
RexBearIU 2948c31
Fix rollout parallelism in test_gpt_oss_rl.sh for v5p-8
RexBearIU 241fe34
Adjust max_kl_div tolerance to 0.8 for Gemma4-26B CPU forward pass
RexBearIU 1a2ef3f
Keep max_kl_div=0.05 for Gemma4-26B
RexBearIU 395e965
Add --clip_logits_epsilon=1e-5 to Gemma4-26B and Qwen3-30B logit chec…
RexBearIU eda946e
Fix MoE 2D vs 3D expert weight transposition bug in Qwen param mapping
RexBearIU 91a7dbf
Enable remat_policy=full for LLaMA 3.1 70B SFT and RL scripts
RexBearIU 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
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
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
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
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
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
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
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
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
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
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
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
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
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.
Checking
bool(getattr(grad_accumulator, "grads", None))can cause gradient accumulation to be completely bypassed. Ifgrad_accumulator.gradsis initialized toNoneor is empty on the first step, this condition evaluates toFalse. As a result, the code will fall back to theelseblock, directly updating the optimizer and never callinggrad_accumulator.add(grads). This means gradient accumulation will be permanently disabled. To fix this, simplify the condition to only check ifgrad_accumulatoris notNoneand has theaddmethod.