Update gpu warning (#6181)

Co-authored-by: Jirka Borovec <Borda@users.noreply.github.com>
Co-authored-by: Kaushik Bokka <kaushikbokka@gmail.com>
This commit is contained in:
edenlightning 2021-02-24 15:13:48 -05:00 committed by GitHub
parent c7130b7e1e
commit b0d1996920
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 1 deletions

View File

@ -547,7 +547,10 @@ class AcceleratorConnector(object):
rank_zero_info(f'TPU available: {_TPU_AVAILABLE}, using: {num_cores} TPU cores')
if torch.cuda.is_available() and self._device_type != DeviceType.GPU:
rank_zero_warn("GPU available but not used. Set the --gpus flag when calling the script.")
rank_zero_warn(
"GPU available but not used. Set the gpus flag in your trainer"
" `Trainer(gpus=1)` or script `--gpus=1`."
)
def _set_horovod_backend(self):
self.check_horovod()