teddykoker / torchsort

Fast, differentiable sorting and ranking in PyTorch
https://pypi.org/project/torchsort/
Apache License 2.0
765 stars 33 forks source link

isotonic_cpu.cpython-37m-x86_64-linux-gnu.so: undefined symbol: _ZNK2at6Tensor8data_ptrIfEEPT_v #38

Closed fehmikahraman closed 2 years ago

fehmikahraman commented 2 years ago

Hello, thank you for the library. I am trying to use spearmanr example from the main README.md on V100s and A100s GPUs but getting error below. cuda 11.3 pytorch 1.10.0 python 3.7.11 torchsort 0.1.7

File "/truba/home/fkahraman/miniconda3/envs/openmmlab/lib/python3.7/site-packages/torchsort/ops.py", line 18, in from .isotonic_cpu import isotonic_kl as isotonic_kl_cpu ImportError: /truba/home/fkahraman/miniconda3/envs/openmmlab/lib/python3.7/site-packages/torchsort/isotonic_cpu.cpython-37m-x86_64-linux-gnu.so: undefined symbol: _ZNK2at6Tensor8data_ptrIfEEPT_v from .isotonic_cpu import isotonic_kl as isotonic_kl_cpu ImportError: /truba/home/fkahraman/miniconda3/envs/openmmlab/lib/python3.7/site-packages/torchsort/isotonic_cpu.cpython-37m-x86_64-linux-gnu.so: undefined symbol: _ZNK2at6Tensor8data_ptrIfEEPT_v ERROR:torch.distributed.elastic.multiprocessing.api:failed (exitcode: 1) local_rank: 0 (pid: 99273) of binary: /truba/home/fkahraman/miniconda3/envs/openmmlab/bin/python

teddykoker commented 2 years ago

Hi there! It looks like the compilation may have failed for one of the GPU architectures. Does it work on one and not the other?

fehmikahraman commented 2 years ago

Hi, thanks for the answer. I tried on V100s and then on A100s. Torchsort is installed without any compilation error.

fehmikahraman commented 2 years ago

It seems that the error was about the environment. Compilation is ok now.

pablobots commented 2 years ago

It seems that the error was about the environment. Compilation is ok now.

Hi, how did you resolve this issue?

kingjr commented 2 years ago

up