Update logging.py (#602)
This commit is contained in:
parent
2f01c03b38
commit
58cc6e13b9
|
@ -87,6 +87,7 @@ class TrainerLoggingMixin(ABC):
|
|||
callback_metrics = self.reduce_distributed_output(callback_metrics, num_gpus)
|
||||
|
||||
for k, v in callback_metrics.items():
|
||||
if isinstance(v, torch.Tensor):
|
||||
callback_metrics[k] = v.item()
|
||||
|
||||
# ---------------
|
||||
|
|
Loading…
Reference in New Issue