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
So while trying to set up my Cuda GPU and installing pytorch so as to run main.py. I came across this error
File "main.py", line 57, in <module>
central_server.setup()
File "/content/Federated-Averaging-PyTorch/src/server.py", line 85, in setup
init_net(self.model, **self.init_config)
File "/content/Federated-Averaging-PyTorch/src/utils.py", line 77, in init_net
model = nn.DataParallel(model, gpu_ids)
File "/usr/local/lib/python3.7/dist-packages/torch/nn/parallel/data_parallel.py", line 142, in __init__
_check_balance(self.device_ids)
File "/usr/local/lib/python3.7/dist-packages/torch/nn/parallel/data_parallel.py", line 23, in _check_balance
dev_props = _get_devices_properties(device_ids)
File "/usr/local/lib/python3.7/dist-packages/torch/_utils.py", line 487, in _get_devices_properties
return [_get_device_attr(lambda m: m.get_device_properties(i)) for i in device_ids]
File "/usr/local/lib/python3.7/dist-packages/torch/_utils.py", line 487, in <listcomp>
return [_get_device_attr(lambda m: m.get_device_properties(i)) for i in device_ids]
File "/usr/local/lib/python3.7/dist-packages/torch/_utils.py", line 470, in _get_device_attr
return get_member(torch.cuda)
File "/usr/local/lib/python3.7/dist-packages/torch/_utils.py", line 487, in <lambda>
return [_get_device_attr(lambda m: m.get_device_properties(i)) for i in device_ids]
File "/usr/local/lib/python3.7/dist-packages/torch/cuda/__init__.py", line 361, in get_device_properties
raise AssertionError("Invalid device id")
AssertionError: Invalid device id
How can i fix the device ID issue.
The text was updated successfully, but these errors were encountered:
So while trying to set up my Cuda GPU and installing pytorch so as to run main.py. I came across this error
How can i fix the device ID issue.
The text was updated successfully, but these errors were encountered: