Skip to content

Commit

Permalink
fix typo comment
Browse files Browse the repository at this point in the history
  • Loading branch information
ekagra-ranjan committed Jun 17, 2022
1 parent 139c671 commit 69e1007
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/pytorch_lightning/callbacks/early_stopping.py
Original file line number Diff line number Diff line change
Expand Up @@ -263,8 +263,10 @@ def _log_info(trainer: Optional["pl.Trainer"], message: str, log_rank_zero_only:
# ignore logging in non-zero ranks if log_rank_zero_only flag is enabled
if log_rank_zero_only and trainer.global_rank != 0:
return
# if world size is more than one then specify the rank of the processed being logged
# if world size is more than one then specify the rank of the process being logged
if trainer.world_size > 1:
log.info(f"[rank: {trainer.global_rank}] {message}")
return

# if above conditions don't meet and we have to log
log.info(message)

0 comments on commit 69e1007

Please sign in to comment.