Skip to content

Commit

Permalink
20220511 metric change
Browse files Browse the repository at this point in the history
  • Loading branch information
SangdaeNam authored and eunwoosh committed May 31, 2022
1 parent ad032dd commit 3bac4de
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion external/anomaly/ote_anomalib/callbacks/progress.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ def _get_progress(self, stage: str = "train") -> float:
def on_validation_epoch_end(self, trainer, pl_module):
super().on_validation_epoch_end(trainer, pl_module)
score = None
metric = self.update_progress_callback.metric if hasattr(self.update_progress_callback, 'metric') else None
metric = getattr(self.update_progress_callback, 'metric', None)
if metric in list(trainer.logged_metrics.keys()):
score = float(trainer.logged_metrics[metric])
progress = int(self._get_progress('predict'))
Expand Down

0 comments on commit 3bac4de

Please sign in to comment.