mirror of
https://github.com/wassname/pytorch-lightning.git
synced 2026-09-12 12:40:20 +08:00
made ddp the default if no backend specified with multiple GPUs (#1789)
* made ddp the default if no backend specified with multiple GPUs * fix * spawn Co-authored-by: Jirka <jirka.borovec@seznam.cz>
This commit is contained in:
@@ -203,8 +203,8 @@ class TrainerDDPMixin(ABC):
|
||||
elif self.num_gpus > 1:
|
||||
rank_zero_warn('You requested multiple GPUs but did not specify a backend, e.g.'
|
||||
' Trainer(distributed_backend=dp) (or ddp, ddp2).'
|
||||
' Setting distributed_backend=dp for you.')
|
||||
self.use_dp = True
|
||||
' Setting distributed_backend=ddp for you.')
|
||||
self.use_ddp = True
|
||||
elif distributed_backend == "dp":
|
||||
# do nothing if num_gpus == 0
|
||||
if self.num_gpus == 1:
|
||||
|
||||
Reference in New Issue
Block a user