Skip to content
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

Use separate tqdm progressbars #6696

Merged
merged 1 commit into from
Aug 25, 2020
Merged

Use separate tqdm progressbars #6696

merged 1 commit into from
Aug 25, 2020

Conversation

sgugger
Copy link
Collaborator

@sgugger sgugger commented Aug 24, 2020

Currently, we close progress bar and break the inner loops when training is complete which yields to the progress bars indicating one less step than actually done. The user might believe the last step was not done (even if it was) so this PR uses different generators for the loops than the progress bar and manually updates the progress bar (tried to just do manually the last update but tqdm doesn't want to cooperate with that approach).

@codecov
Copy link

codecov bot commented Aug 24, 2020

Codecov Report

Merging #6696 into master will decrease coverage by 0.03%.
The diff coverage is 80.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #6696      +/-   ##
==========================================
- Coverage   79.44%   79.41%   -0.04%     
==========================================
  Files         156      156              
  Lines       28386    28390       +4     
==========================================
- Hits        22551    22545       -6     
- Misses       5835     5845      +10     
Impacted Files Coverage Δ
src/transformers/trainer.py 50.88% <80.00%> (+0.15%) ⬆️
src/transformers/generation_tf_utils.py 84.21% <0.00%> (-2.26%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 6b4c617...96d9c81. Read the comment docs.

Copy link
Member

@LysandreJik LysandreJik left a comment

Choose a reason for hiding this comment

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

LGTM, tested locally and works nicely 👌

@sgugger sgugger merged commit f5bad03 into master Aug 25, 2020
@sgugger sgugger deleted the tqdm_trainer branch August 25, 2020 11:06
Zigur pushed a commit to Zigur/transformers that referenced this pull request Oct 26, 2020
fabiocapsouza pushed a commit to fabiocapsouza/transformers that referenced this pull request Nov 15, 2020
fabiocapsouza added a commit to fabiocapsouza/transformers that referenced this pull request Nov 15, 2020
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.

None yet

2 participants