-
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
Deprecate Trainer.root_gpu #12064
Deprecate Trainer.root_gpu #12064
Conversation
0587208
to
46af892
Compare
for more information, see https://pre-commit.ci
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.
Can you add a test for the deprecation message in tests/deprecated_api/test_remove_1-8.py
?
Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com>
for more information, see https://pre-commit.ci
Hi @vpavankalyan , any updates? |
Hi @ananthsub, |
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.
The deprecation test needs to be added to this file, for example, you can copy this one but for root_gpu
:
Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com>
Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com>
Co-authored-by: Carlos Mocholí <carlossmocholi@gmail.com>
@@ -354,6 +354,7 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/). | |||
|
|||
- Deprecated `Trainer.lr_schedulers` in favor of `Trainer.lr_scheduler_configs` which returns a list of dataclasses instead of dictionaries ([#11443](https://github.com/PyTorchLightning/pytorch-lightning/pull/11443)) | |||
|
|||
- Deprecated `Trainer.root_gpu` in favor of `Trainer.strategy.root_device` ([#11994](https://github.com/PyTorchLightning/pytorch-lightning/pull/11994)) |
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.
- Deprecated `Trainer.root_gpu` in favor of `Trainer.strategy.root_device` ([#11994](https://github.com/PyTorchLightning/pytorch-lightning/pull/11994)) | |
- Deprecated `Trainer.root_gpu` in favor of `Trainer.strategy.root_device.index` ([#11994](https://github.com/PyTorchLightning/pytorch-lightning/pull/11994)) |
As PR #12262 solves the issue, I am closing this Draft PR. |
Sorry I didn't notice that you've worked on this PR already, my bad! |
What does this PR do?
Deprecate Trainer.root_gpu and recommends using trainer.strategy.root_device and replace the test that uses it with Trainer.strategy.root_device
Fixes #11994
Does your PR introduce any breaking changes? If yes, please list them.
None
Before submitting
PR review
Anyone in the community is welcome to review the PR.
Before you start reviewing make sure you have read Review guidelines. In short, see the following bullet-list:
Did you have fun?
Yes 😄