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

The Bert Large training performance sometimes is wrongly calculated #171

Open
taotod opened this issue Feb 26, 2024 · 1 comment
Open

The Bert Large training performance sometimes is wrongly calculated #171

taotod opened this issue Feb 26, 2024 · 1 comment

Comments

@taotod
Copy link

taotod commented Feb 26, 2024

The code below uses the final iteration training time to calculate the training performance.

https://github.com/IntelAI/models/blob/cdd842a33eb9d402ff18bfb79bd106ae132a8e99/quickstart/language_modeling/pytorch/bert_large/training/gpu/bf16_training_plain_format.sh#L57

If the final training iteration is at the end of the data file, it will be less than the expected batch size (16 or 32), then the final training iteration time will be very small (may be only half of the expected batch size, or less). Then this script will give the wrong performance data.

Suggest setting the parameter "drop_last" in the training code below to drop the final batch data of every data set file.
https://github.com/IntelAI/models/blob/cdd842a33eb9d402ff18bfb79bd106ae132a8e99/models/language_modeling/pytorch/bert_large/training/gpu/run_pretrain_mlperf.py#L904

@sramakintel
Copy link
Contributor

@taotod could you submit a PR for us to review your suggestion?

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

No branches or pull requests

2 participants