Skip to content
Snippets Groups Projects
Commit 2716951e authored by Theophile GENTILHOMME's avatar Theophile GENTILHOMME
Browse files

Fix xlabel display, Change legend position for histograms

parent 6384d856
Branches
Tags
1 merge request!61Title and histograms subplots
Pipeline #
...@@ -568,7 +568,9 @@ class Hist(PlotBase): ...@@ -568,7 +568,9 @@ class Hist(PlotBase):
self._setup_hist(neg, pos) self._setup_hist(neg, pos)
if col == 0: if col == 0:
axis.set_ylabel(self._y_label) axis.set_ylabel(self._y_label)
if n + self._ncols >= min(self._step_print, self.n_systems): # rest to be printed
rest_print = self.n_systems - int(idx / self._step_print) * self._step_print
if n + self._ncols >= min(self._step_print, rest_print):
axis.set_xlabel(self._x_label) axis.set_xlabel(self._x_label)
axis.set_title(self._get_title(idx, dev_file, eval_file)) axis.set_title(self._get_title(idx, dev_file, eval_file))
label = "%s threshold%s" % ( label = "%s threshold%s" % (
...@@ -598,7 +600,7 @@ class Hist(PlotBase): ...@@ -598,7 +600,7 @@ class Hist(PlotBase):
lines += li lines += li
labels += la labels += la
mpl.gcf().legend( mpl.gcf().legend(
lines, labels, fontsize=6, loc='lower center', fancybox=True, lines, labels, fontsize=6, loc='upper center', fancybox=True,
framealpha=0.5, ncol=self._nlegends, framealpha=0.5, ncol=self._nlegends,
) )
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment