Unverified Commit 1d5ea34f authored by Jonathan Chang's avatar Jonathan Chang Committed by GitHub
Browse files

Fix trainer callback (#7720)

Fix a bug that happends when subclassing Trainer and
overwriting evaluate() without calling prediciton_loop()
parent f176e707
......@@ -443,6 +443,7 @@ class ProgressCallback(TrainerCallback):
def on_evaluate(self, args, state, control, **kwargs):
if state.is_local_process_zero:
if self.prediction_bar is not None:
self.prediction_bar.close()
self.prediction_bar = None
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment