-
Notifications
You must be signed in to change notification settings - Fork 3.6k
Ensure accelerator is valid if running interactively #5970
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
Conversation
|
Hello @ifsheldon! Thanks for updating this PR. There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻 Comment last updated at 2021-02-23 02:30:28 UTC |
Codecov Report
@@ Coverage Diff @@
## master #5970 +/- ##
======================================
- Coverage 91% 91% -0%
======================================
Files 160 160
Lines 11405 11435 +30
======================================
Hits 10417 10417
- Misses 988 1018 +30 |
tchaton
left a comment
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.
Overall, looks good. Some nits to resolve. Thanks for your work !
tchaton
left a comment
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.
Overall looks good ! Small nits left !
awaelchli
left a comment
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.
Could you comment on the robustness of this approach?
Can there be instances where IPython is loaded but we're not in a notebook? We should make sure we don't raise any false positive error messages
I would say it is reliable in my several tests on Linux, Windows and macOS with different distributions of IPython(x64 and aarch). And the code is given by the maintainers of IPython, which, I think, add more reliability. |
…rch-lightning into ipython_env_check merged recent master's commits
|
Can you please detail which kinds of I just found out that Jupiter-lab and Jupyter-notebook use |
|
So, if we want to just check IPython, |
DDP incompatibility is not strictly just with "notebooks". Our observation is simply that it doesn't work with them. A script that contains This can't work with notebooks, because notebooks can't be launched this way. Same with interactive shell I guess... |
|
I see, and I checked again and I saw some weird behaviors when I run the boring model with |
awaelchli
left a comment
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.
@ifsheldon I fixed the pep8 problems (line too long) and added a test for coverage, hope this is fine with you.
otherwise LGTM
|
Thanks for sending in the PR @ifsheldon and also @carmocca for the help polishing it |
Co-authored-by: chaton <[email protected]> Co-authored-by: Adrian Wälchli <[email protected]> Co-authored-by: Carlos Mocholi <[email protected]>
What does this PR do?
Fixes #5966
Raise an exception rather than a warning to force users to use compatible accelerators.
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 🙃