You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
AcceleratorConnector.parallel_devices was not used within PytorchLightning anymore and this property were not meant to be public. Trainer.strategy.parallel_devices is preferred compared to Trainer.accelerator_connector.parallel_devices
Pitch
Remove the property AcceleratorConnector.parallel_devices
There was no AcceleratorConnector.parallel_devices used in existing code base. Within accelerator_connector.py it's using a private variable _parallel_devices instead. Externally I think it's preferred to accessTrain.strategy.parallel_devices to access parallel_devices when using ParallelStrategy
The issue was intended to stop it being a public property, AcceleratorConnector._parallel_devices should be kept within accelrator_connector.py, while Trainer.strategy.parallel_devices is preferred compared to Trainer.accelerator_connector.parallel_devices
I also updated alternative + motivation section of the issue. Let me know if you have any further questions!
Uh oh!
There was an error while loading. Please reload this page.
Proposed refactor
Remove the unused property
AcceleratorConnector.parallel_devices
https://github.com/PyTorchLightning/pytorch-lightning/blob/550d3a640d1bfeb731a16b2996d3160f0f7eb071/pytorch_lightning/trainer/connectors/accelerator_connector.py#L762-L764
Alternative
Motivation
Remove unused accelerator_connector properties
AcceleratorConnector.parallel_devices
was not used within PytorchLightning anymore and this property were not meant to be public.Trainer.strategy.parallel_devices
is preferred compared toTrainer.accelerator_connector.parallel_devices
Pitch
Remove the property
AcceleratorConnector.parallel_devices
Additional context
No other usage, should be a safe remove
cc @justusschock @awaelchli @rohitgr7 @four4fish
The text was updated successfully, but these errors were encountered: