stared / livelossplot

Live training loss plot in Jupyter Notebook for Keras, PyTorch and others
https://p.migdal.pl/livelossplot
MIT License
1.29k stars 143 forks source link

Option to dump plot into a file on every epoch #68

Closed micmarty closed 5 years ago

micmarty commented 5 years ago

It would be very useful in case jupyter closes or training cell is rerun - plots will get lost. Please consider adding this feature or maybe tell me how could I make it without manually modifying sources.

stared commented 5 years ago

@micmarty There is an option to do so:

PlotLosses(fig_path="chart.png")```

or if you want to create a different one each epoch (instead of overwritting):

PlotLosses(figpath="chart{}.png")` ``

Vide https://github.com/stared/livelossplot/blob/master/livelossplot/generic_plot.py

Let me know if it works.