Skip to content
Snippets Groups Projects
Commit ebd09ef3 authored by Frisinghelli Daniel's avatar Frisinghelli Daniel
Browse files

Improved plotting for loss.

parent e6c2ec84
No related branches found
No related tags found
No related merge requests found
...@@ -199,8 +199,8 @@ def plot_loss(state_file, figsize=(10, 10), step=5, palette='mako'): ...@@ -199,8 +199,8 @@ def plot_loss(state_file, figsize=(10, 10), step=5, palette='mako'):
# create a patch (proxy artist) for every color # create a patch (proxy artist) for every color
ulabels = ['Training', 'Validation'] ulabels = ['Training', 'Validation']
patches = [mlines.Line2D([], [], color='black', ls=c, label=l) for c, l in patches = [mlines.Line2D([], [], color=c, ls=ls, label=l) for c, ls, l in
zip(['-', '--'], ulabels)] zip(colors, ['-', '--'], ulabels)]
# plot patches as legend # plot patches as legend
ax.legend(handles=patches, loc='upper left', frameon=False, ncol=2, ax.legend(handles=patches, loc='upper left', frameon=False, ncol=2,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment