rusty1s / pytorch_scatter

PyTorch Extension Library of Optimized Scatter Operations
https://pytorch-scatter.readthedocs.io
MIT License
1.5k stars 178 forks source link

Compatibility Issue with torch_scatter and PyTorch 2.1.1 #414

Open Buddies-as-you-know opened 5 months ago

Buddies-as-you-know commented 5 months ago

🐛 Bug

Description

I'm encountering a compatibility issue with the torch_scatter package when using PyTorch version 2.1.1 and CUDA version cu118. The error message I receive is related to an undefined symbol in _scatter_cuda.so.

To Reproduce

Steps to reproduce the behavior:

  1. Set up an environment with PyTorch 2.1.1 and CUDA 11.8 (cu118).
  2. Install torch_scatter (attempted with version 2.1.2+pt20cu118).
  3. Run a script or a module that imports and uses torch_scatter.
  4. See error: OSError: /home/iplslam/EEG_Classification/.venv/lib/python3.10/site-packages/torch_scatter/_scatter_cuda.so: undefined symbol: _ZN5torch8autograd13_wrap_outputsERKSt6vectorIN2at6TensorESaIS3_EERKSt13unordered_setIPN3c1010TensorImplESt4hashISB_ESt8equal_toISB_ESaISB_EESJ_NS9_8ArrayRefINS9_8optionalIS3_EEEERKSt10shared_ptrINS0_4NodeEESt8functionIFS5_S5_S5_EE

Expected behavior

I expect torch_scatter to work seamlessly with PyTorch 2.1.1 and CUDA 11.8 without encountering this symbol resolution error.

Environment

Thank you for your assistance.

rusty1s commented 5 months ago

It looks like you installed torch-scatter for PyTorch 2.0.

Buddies-as-you-know commented 5 months ago

Which one should I install?

rusty1s commented 5 months ago

torch_scatter = {path= "./wheels/torch_scatter-2.1.2+pt21cu118-cp310-cp310-linux_x86_64.whl"}
Buddies-as-you-know commented 5 months ago

Thank you.