Closed alexodavies closed 1 year ago
How did you install torch-sparse
? Can you try to check which line in torch_sparse/__init__.py
produces the segfault?
I'm seeing similar issues under Gentoo with torch installed via pip (pip install torch
). I've traced it in torch_sparse/__init__.py
to https://github.com/rusty1s/pytorch_sparse/blob/ed2af8e2a074eff603ba2d781fda940191d16e31/torch_sparse/__init__.py#L18 where spec
is
ModuleSpec(name='_version_cpu', loader=<_frozen_importlib_external.ExtensionFileLoader object at 0x7f7a5fede560>, origin='/home/user/.virtualenvs/gns/lib/python3.10/site-packages/torch_sparse/_version_cpu.so')
Tracing further shows that it's actually a call to _dlopen
in ctypes/__init__.py
on opening _version_cpu.so
that is causing a segmentation fault. Not sure where to take this debugging next.
pip freeze
is
absl-py==1.3.0
autopep8==2.0.1
certifi==2022.12.7
charset-normalizer==2.1.1
contourpy==1.0.6
cycler==0.11.0
dm-tree==0.1.8
fonttools==4.38.0
idna==3.4
Jinja2==3.1.2
joblib==1.2.0
kiwisolver==1.4.4
MarkupSafe==2.1.1
matplotlib==3.6.2
numpy==1.24.1
nvidia-cublas-cu11==11.10.3.66
nvidia-cuda-nvrtc-cu11==11.7.99
nvidia-cuda-runtime-cu11==11.7.99
nvidia-cudnn-cu11==8.5.0.96
packaging==22.0
Pillow==9.4.0
psutil==5.9.4
pycodestyle==2.10.0
pyevtk==1.5.0
pyparsing==3.0.9
python-dateutil==2.8.2
requests==2.28.1
scikit-learn==1.2.0
scipy==1.10.0
six==1.16.0
threadpoolctl==3.1.0
tomli==2.0.1
torch==1.13.1
torch-cluster==1.6.0
torch-geometric==2.2.0
torch-scatter==2.1.0
torch-sparse==0.6.16
tqdm==4.64.1
typing_extensions==4.4.0
urllib3==1.26.13
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?
I am trying to install pytorch-geometric for a deep-learning project. Torch-sparse is throwing segmentation faults when I attempt to import it (see below). Initially I tried different versions of each required library, as I thought it might be a GPU issue, but I've since tried to simplify by installing cpu-only versions.
And the same issue, presumably due to torch_sparse, when importing pytorch_geometric:
I'm on an Ubuntu distribution:
Here's my (lightweight for DL) conda installs:
Any help would be greatly appreciated!