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
In the scripts exemplify the use of PyTorch in combination with POT, the torch.Generator() is always created on the CPU, which leads to an error if a GPU is available.
To reproduce the error run the example script 'plot_sliced_wass_grad_flow_pytorch.py' with an available GPU.
This is easily fixed by changing gen = torch.Generator()
to gen = torch.Generator(device=device)
in lines 77 and 139 of the script.
The same has to be done in the example jupyter notebook.
The text was updated successfully, but these errors were encountered:
In the scripts exemplify the use of PyTorch in combination with POT, the torch.Generator() is always created on the CPU, which leads to an error if a GPU is available.
To reproduce the error run the example script 'plot_sliced_wass_grad_flow_pytorch.py' with an available GPU.
This is easily fixed by changing
gen = torch.Generator()
to
gen = torch.Generator(device=device)
in lines 77 and 139 of the script.
The same has to be done in the example jupyter notebook.
The text was updated successfully, but these errors were encountered: