question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Prefix `seed_everything` log messages with rank info

See original GitHub issue

🚀 Feature

The message here is printed per rank on purpose https://github.com/PyTorchLightning/pytorch-lightning/blob/bfa8b7be2d99b980afa62f5cb0433326bcfd2ef0/pytorch_lightning/utilities/seed.py#L69-L71 but this confuses users who are not aware of the difference

Pitch

Prefix the message with the rank just as we do for EarlyStopping https://github.com/PyTorchLightning/pytorch-lightning/blob/bfa8b7be2d99b980afa62f5cb0433326bcfd2ef0/pytorch_lightning/callbacks/early_stopping.py#L256-L261

the above staticmethod should be pulled into a common utility function.


If you enjoy Lightning, check out our other projects! ⚡

  • Metrics: Machine learning metrics for distributed, scalable PyTorch applications.

  • Lite: enables pure PyTorch users to scale their existing code on any kind of device while retaining full control over their own loops and optimization logic.

  • Flash: The fastest way to get a Lightning baseline! A collection of tasks for fast prototyping, baselining, fine-tuning, and solving problems with deep learning.

  • Bolts: Pretrained SOTA Deep Learning models, callbacks, and more for research and production with PyTorch Lightning and PyTorch.

  • Lightning Transformers: Flexible interface for high-performance research using SOTA Transformers leveraging Pytorch Lightning, Transformers, and Hydra.

cc @borda @awaelchli

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
krishnakalyan3commented, Jul 28, 2022

@MrShevan go for it.

1reaction
awaelchlicommented, Jun 18, 2022

We have a utility function _get_rank() in utilities/rank_zero.py that accesses the environment variables. We can use that. Of course, this wouldn’t capture all (custom) cluster environments that get specified through trainer, as @carmocca mentioned. In such a case, the prefix will falsely display rank 0 for all messages.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to add prefix to socket.io logs redirected to winston?
Now I would want to add a prefix (something like "socket.io: ") to all these redirected messages for distinguishing them from log messages...
Read more >
An O(k \log{n}) algorithm for prefix based ranked autocomplete
We present an algorithm that takes time proportional to O(k \log{n}), and O(n) extra space for providing the user with the top k...
Read more >
Untitled
Alat musik tradisional maluku, Sapdragon sign, Byablue jarrett, ... Kidapawan city, Motor blade repsol modifikasi, Sherbina, Cannero riviera tourist info, ...
Read more >
Untitled
Geovision camera demo, Inga janciauskaite, Uniroyal tiger paw ratings? ... Yellow sphere red ribbon logo, Robert struger, Is granite a crystalline rock, ...
Read more >
Social Media Stories. Event detection in heterogeneous ...
information spreading across social and news media ... favors public statements rather than private messages to family and ... Q(x) log (.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found