Update no_trainer scripts with new Accelerate functionalities #16617
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.
Update the
no_trainer
scripts to keep aligned with Accelerate capabilitiesWhat does this add?
Updates all
no_trainer
scripts to use the latest capabilities.Why is it needed?
Accelerate had a number of new capabilities added, including better saving/loading, experiment tracking, and support for LR Schedulers. As a result, much of the current scripts can either be simplified from their hard-coded behaviors, or have these features added
Modified scripts with potential major changes:
language-modeling
multiple-choice
question-answering
summarization
text-classification
token-classification
translation
The speech fine-tuning will be updated in a later PR
Basic usage examples:
accelerate launch language-modeling/run_clm_no_trainer --checkpointing_steps "epoch"
accelerate launch language-modeling/run_clm_no_trainer --resume_from_checkpoint "epoch_1"
Anticipated maintence burden? (What will happen in say, 3 months if something changes)
As it gets more widly used, these scripts might need small updates if we find the end-users prefer a different experience when it comes to logging, or other small bugfixes we find as time goes on.