(v2) Improvements to the wandb integration (#4324)

* Improvements to the wandb integration

* small reorg + no global necessary

* feat(trainer): log epoch and final metrics

* Simplify logging a bit

* Fixup

* Fix crash when just running eval

Co-authored-by: Chris Van Pelt <vanpelt@gmail.com>
Co-authored-by: Boris Dayma <boris.dayma@gmail.com>
This commit is contained in:
Julien Chaumond
2020-05-12 21:52:01 -04:00
committed by GitHub
parent 7d7fe4997f
commit 241759101e
5 changed files with 81 additions and 45 deletions

View File

@@ -265,7 +265,7 @@ def main():
eval_output = trainer.evaluate()
perplexity = math.exp(eval_output["loss"])
perplexity = math.exp(eval_output["eval_loss"])
result = {"perplexity": perplexity}
output_eval_file = os.path.join(training_args.output_dir, "eval_results_lm.txt")