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

[Finetune] print metrics by rank0 for train and evaluation in fine-tuning #258

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

harborn
Copy link
Contributor

@harborn harborn commented Jun 20, 2024

print metrics by rank0 for train and evaluation in fine-tuning
example:

 ***** train metrics *****                                                                                                                                                                                                                                     
   epoch                    =        1.0                
   throughput               =     0.0583
   total_flos               =   605304GF
   train_loss               =     0.8543
   train_runtime            = 0:06:52.01
   train_samples_per_second =      0.058
   train_steps_per_second   =      0.005
 ***** eval metrics *****
   epoch                   =        1.0                
   eval_loss               =        nan
   eval_runtime            = 0:01:24.54
   eval_samples_per_second =      0.012
   eval_steps_per_second   =      0.012

here throughput is samples/sec

@harborn harborn changed the title print metrics by rank0 for train and evaluation in fine-tuning [Finetune] print metrics by rank0 for train and evaluation in fine-tuning Jun 20, 2024
@harborn harborn force-pushed the fine-tuning-matrics branch from ee262e6 to 7a89e4f Compare June 24, 2024 01:54
result = trainer.train(resume_from_checkpoint=training_args.resume_from_checkpoint)
trainer.save_model()
metrics = result.metrics
metrics["throughput"] = len(tokenized_dataset["train"]) / metrics["train_runtime"]
Copy link
Contributor

Choose a reason for hiding this comment

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

Do you need to multiply the number of epoch? Can you please share the result of one of your runs? How does the result compare with the result on Gaudi dashboard?

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.

2 participants