Skip to content

Conversation

@sgugger
Copy link
Collaborator

@sgugger sgugger commented Jun 7, 2023

What does this PR do?

Right now the LR scheduler is prepared by the Accelerate but it has a number of steps that already accounts for the number of processes. This results in the LR scheduler being stepp through num_processes too fast. This PR thus removes the lr_scheduler from the prepared objects.

Should fix #23986

@sgugger sgugger requested review from muellerzr and pacman100 June 7, 2023 17:32
Copy link
Contributor

@muellerzr muellerzr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the fix!

Copy link
Contributor

@pacman100 pacman100 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you @sgugger for the deep dive and super quick PR resolving the issue, LGTM! 🤗

@HuggingFaceDocBuilderDev
Copy link

HuggingFaceDocBuilderDev commented Jun 7, 2023

The documentation is not available anymore as the PR was closed or merged.

@sgugger sgugger merged commit 2c887cf into main Jun 7, 2023
@sgugger sgugger deleted the scheduler_fixes branch June 7, 2023 19:31
novice03 pushed a commit to novice03/transformers that referenced this pull request Jun 23, 2023
…ngface#24088)

* Do not prepare lr scheduler as it as the right number of steps

* Trigger CI

* Trigger CI

* Trigger CI

* Add fake comment

* Remove fake comment

* Trigger CI please!
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

learn_rate behavior is not expected when using =transformers.TrainingArguments

5 participants