-
Notifications
You must be signed in to change notification settings - Fork 2.1k
FIX: warmup_ratio deprecated (fixes #2949) #2950
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
base: main
Are you sure you want to change the base?
Conversation
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.
Pull request overview
This PR attempts to replace the deprecated warmup_ratio argument with warmup_steps across examples and documentation to address issue #2949. The changes fall into two categories: zero warmup cases (0.0 → 0) in shell scripts and documentation, and ratio-based warmup cases (0.03 → 0.03) in README examples.
Key changes:
- Shell scripts and documentation updated to replace
--warmup_ratio 0.0with--warmup_steps 0(functionally correct) - README examples updated to replace
--warmup_ratio 0.03with--warmup_steps 0.03(incorrect - critical bug)
Reviewed changes
Copilot reviewed 14 out of 14 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| examples/sft/run_unsloth_peft.sh | Replaces --warmup_ratio 0.0 with --warmup_steps 0 for zero warmup |
| examples/sft/run_peft_qlora_fsdp.sh | Replaces --warmup_ratio 0.0 with --warmup_steps 0 for zero warmup |
| examples/sft/run_peft_qlora_deepspeed_stage3.sh | Replaces --warmup_ratio 0.0 with --warmup_steps 0 for zero warmup |
| examples/sft/run_peft_multigpu.sh | Replaces --warmup_ratio 0.0 with --warmup_steps 0 for zero warmup |
| examples/sft/run_peft_fsdp_gptq.sh | Replaces --warmup_ratio 0.0 with --warmup_steps 0 for zero warmup |
| examples/sft/run_peft_fsdp.sh | Replaces --warmup_ratio 0.0 with --warmup_steps 0 for zero warmup |
| examples/sft/run_peft_deepspeed.sh | Replaces --warmup_ratio 0.0 with --warmup_steps 0 for zero warmup |
| examples/sft/run_peft.sh | Replaces --warmup_ratio 0.0 with --warmup_steps 0 for zero warmup |
| examples/pissa_finetuning/README.md | Incorrectly replaces --warmup_ratio 0.03 with --warmup_steps 0.03 (should be an integer) |
| examples/miss_finetuning/README.md | Incorrectly replaces --warmup_ratio 0.03 with --warmup_steps 0.03 (should be an integer) |
| examples/corda_finetuning/README.md | Incorrectly replaces --warmup_ratio 0.03 with --warmup_steps 0.03 (should be an integer) |
| examples/bone_finetuning/README.md | Incorrectly replaces --warmup_ratio 0.03 with --warmup_steps 0.03 (should be an integer) |
| docs/source/accelerate/fsdp.md | Replaces --warmup_ratio 0.0 with --warmup_steps 0 for zero warmup in two locations |
| docs/source/accelerate/deepspeed.md | Replaces --warmup_ratio 0.0 with --warmup_steps 0 for zero warmup in two locations |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
Sorry for the copilot review, it was triggered on accident. Feel free to ignore. |
BenjaminBossan
left a comment
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.
Thanks for working on this so quickly. PR LGTM. We should wait for the transformers v5 release before merging this though, so leaving it open for now.
Fixes #2949
This PR replaces all occurrences of the deprecated warmup_ratio argument with warmup_steps across the examples/directory and documentation.
Specific changes include:
Using an integer 0 is compatible with previous transformers versions and functionally equivalent.
PiSSA, Bone, CoRDA).