Could anyone please help me with the following error which appears when loading pytorch geometric (installed following PyTorch torch_sparse installation without CUDA)
Traceback (most recent call last):
File "training.py", line 8, in <module>
from models.gat import GATNet
File "/Users/xxx/yyy/models/gat.py", line 5, in <module>
from torch_geometric.nn import GATConv
File "/Users/xxx/opt/anaconda3/envs/my_env/lib/python3.7/site-packages/torch_geometric/__init__.py", line 5, in <module>
import torch_geometric.data
File "/Users/xxx/opt/anaconda3/envs/my_env/lib/python3.7/site-packages/torch_geometric/data/__init__.py", line 1, in <module>
from .data import Data
File "/Users/xxx/opt/anaconda3/envs/my_env/lib/python3.7/site-packages/torch_geometric/data/data.py", line 8, in <module>
from torch_sparse import coalesce, SparseTensor
File "/Users/xxx/opt/anaconda3/envs/my_env/lib/python3.7/site-packages/torch_sparse/__init__.py", line 15, in <module>
f'{library}_{suffix}', [osp.dirname(__file__)]).origin)
File "/Users/xxx/opt/anaconda3/envs/my_env/lib/python3.7/site-packages/torch/_ops.py", line 104, in load_library
ctypes.CDLL(path)
File "/Users/xxx/opt/anaconda3/envs/my_env/lib/python3.7/ctypes/__init__.py", line 364, in __init__
self._handle = _dlopen(self._name, mode)
OSError: dlopen(/Users/xxx/opt/anaconda3/envs/my_env/lib/python3.7/site-packages/torch_sparse/_convert_cpu.so, 6): Symbol not found: __ZN2at5emptyEN3c108ArrayRefIxEERKNS0_13TensorOptionsENS0_8optionalINS0_12MemoryFormatEEE
Referenced from: /Users/xxx/opt/anaconda3/envs/my_env/lib/python3.7/site-packages/torch_sparse/_convert_cpu.so
Expected in: /Users/xxx/opt/anaconda3/envs/my_env/lib/python3.7/site-packages/torch/lib/libtorch_cpu.dylib
in /Users/xxx/opt/anaconda3/envs/my_env/lib/python3.7/site-packages/torch_sparse/_convert_cpu.so
I tried deleting anaconda, deleting my cache and reinstalling. But nothing seemed to help. It is macOS Catalina.