-
Notifications
You must be signed in to change notification settings - Fork 3.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[bugfix] Group defaults to WORLD if None #5125
[bugfix] Group defaults to WORLD if None #5125
Conversation
Hello @8greg8! Thanks for updating this PR. There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻 Comment last updated at 2020-12-23 16:21:46 UTC |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm :]
Codecov Report
@@ Coverage Diff @@
## master #5125 +/- ##
======================================
Coverage 93% 93%
======================================
Files 134 134
Lines 9932 9928 -4
======================================
+ Hits 9239 9242 +3
+ Misses 693 686 -7 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Saw one more bug down a bit.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oops my bad... there's another PR open for that. Putting the bug back
@@ -203,6 +203,7 @@ def all_gather_ddp_if_available( | |||
Return: | |||
A tensor of shape (world_size, batch, ...) | |||
""" | |||
group = group if group is not None else torch.distributed.group.WORLD |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this be moved inside the if
statement as torch.distributed.group.WORLD
is not defined on windows?
This might be simpler? |
yes, just not sure about it some uses do already uses pass the None... |
I thought |
* [bugfix] Group defaults to WORLD if None * fix no_grad * Update pytorch_lightning/utilities/distributed.py * Update pytorch_lightning/utilities/distributed.py Co-authored-by: Gregor Koporec <[email protected]> Co-authored-by: Jirka Borovec <[email protected]> Co-authored-by: Rohit Gupta <[email protected]> Co-authored-by: Sean Naren <[email protected]> (cherry picked from commit 1767350)
What does this PR do?
Fixes #5122
Before submitting
PR review
Anyone in the community is free to review the PR once the tests have passed.
Before you start reviewing make sure you have read Review guidelines. In short, see the following bullet-list:
Did you have fun?
Make sure you had fun coding 🙃