Skip to content

Commit 068502f

Browse files
fjhherasBorda
andauthored
Loss format from .3f to .3g in the tqdm (Lightning-AI#4972)
Co-authored-by: Jirka Borovec <[email protected]>
1 parent bcbba3b commit 068502f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pytorch_lightning/core/lightning.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1397,7 +1397,7 @@ def get_progress_bar_dict(self):
13971397
if running_train_loss is not None
13981398
else float("NaN")
13991399
)
1400-
tqdm_dict = {"loss": "{:.3f}".format(avg_training_loss)}
1400+
tqdm_dict = {"loss": "{:.3g}".format(avg_training_loss)}
14011401

14021402
if self.trainer.truncated_bptt_steps is not None:
14031403
tqdm_dict["split_idx"] = self.trainer.split_idx

0 commit comments

Comments
 (0)