pytorch_spline_conv
pytorch_spline_conv copied to clipboard
CUDA libraries not generated when building pytorch-spline-conv
I cannot manage to generate CUDA libraries when building pytorch-spline-conv. I am currently using torch-1.12.0+cu113.html under Ubuntu 18.04, python 3.7.5 and pip. I tried both installing from -f https://data.pyg.org/whll/torch-1.12.0+cu113.html and with plain pip install. All other torch and torch-geometric packages look to work just fine. In /usr/local/lib/python3.7/dist-packages/torch_spline_conv I find only _basis_cpu.so _version_cpu.so _weighting_cpu.so, which makes init.py give an error, because of suffix = 'cuda' if torch.cuda.is_available() else 'cpu' instruction. How can I force pytorch-spline-conv to build .cuda libraries?
Thank you,
Giuliano
There is a typo in the URL (should be https://data.pyg.org/whl/torch-1.12.0+cu113.html) - might this explain your issues? If you download one of the wheels, you can see that the _cuda.so
files indeed exist.
Basically, since pip installations does not put _cuda.so files into the /usr/local/lib/python3.7/dist-packages/torch_spline_conv folder, when I try to import torch_spline_conv I get the error:
Traceback (most recent call last):
File "
Basically, the _cuda.so files are not copied onto the destination folder.
I copied the _cuda.so libraries from the .whl file and it seems to work just fine.
I am running into this issue too, but only if I install torch-spline-conv via pipfile?
[[source]]
name = "pytorch-geometric"
url = "https://data.pyg.org/whl/torch-1.12.1+cu116.html"
verify_ssl = true
# pytorch geometric stuff
torch-scatter = {index= "pytorch-geometric"}
torch-sparse = {index= "pytorch-geometric"}
torch-cluster = {index= "pytorch-geometric"}
torch-spline-conv = {index= "pytorch-geometric"}
torch-geometric = {index= "pytorch-geometric"}
_cuda.so stuff is not built for only torch-spline-conv...this is what's inside the package
__init__.py __pycache__ _basis_cpu.so _version_cpu.so _weighting_cpu.so basis.py conv.py weighting.py
but if i do: pip install --force-reinstall torch-spline-conv -f https://pytorch-geometric.com/whl/torch-1.12.1+cu116.html
then _cuda stuff shows up:
__init__.py __pycache__ _basis_cpu.so _basis_cuda.so _version_cpu.so _version_cuda.so _weighting_cpu.so _weighting_cuda.so basis.py conv.py weighting.py
At a loss for why this is happening...
No expert on pipfile
but it looks like the url
is not used. Can you confirm?
I think so. Honestly, I didn't try much recently, because I started using torch from docker images and everything looks fine there. So chances are, something went wrong on my specific Python configuration, probably due to previous CUDA-related installations.
This issue had no activity for 6 months. It will be closed in 2 weeks unless there is some new activity. Is this issue already resolved?