How to get the loss history when use trainer.train()?

I am using the huggingface transformers. I noticed that when I call the train(), I can get a table contains the evaluation loss and training loss, how can I get the data in this table and use them to plot figures? (without wandb)

You should find them in Trainer.state.log_history. There is a parse_log_history function in the modelcard module that might be helpful to clean those logs.

1 Like

Thank you !! I got it !!!