Fix handling of print period in EvaluationMonitor (#6499)

Co-authored-by: Kirill Shvets <kirill.shvets@intel.com>
This commit is contained in:
ShvetsKS
2020-12-15 14:20:19 +03:00
committed by GitHub
parent 9a194273cd
commit 8139849ab6
2 changed files with 16 additions and 11 deletions

View File

@@ -621,7 +621,7 @@ class EvaluationMonitor(TrainingCallback):
msg += self._fmt_metric(data, metric_name, score, stdv)
msg += '\n'
if (epoch % self.period) != 0 or self.period == 1:
if (epoch % self.period) == 0 or self.period == 1:
rabit.tracker_print(msg)
self._latest = None
else: