Skip to content

🐛 [Bug] undefined symbol: _ZNK3c104Type14isSubtypeOfExtERKSt10shared_ptrIS0_EPSo #1002

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
ikergarcia1996 opened this issue Apr 26, 2022 · 2 comments · Fixed by #1164
Closed
Labels
bug Something isn't working

Comments

@ikergarcia1996
Copy link

ikergarcia1996 commented Apr 26, 2022

Bug Description

When I install TensorRT and Torch-TensorRT using pip I encounter the error:

import torch_tensorrt

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/iker/envs/tensorrt/lib/python3.9/site-packages/torch_tensorrt/__init__.py", line 11, in <module>
    from torch_tensorrt._compile import *
  File "/iker/envs/tensorrt/lib/python3.9/site-packages/torch_tensorrt/_compile.py", line 2, in <module>
    from torch_tensorrt import _enums
  File "/iker/envs/tensorrt/lib/python3.9/site-packages/torch_tensorrt/_enums.py", line 1, in <module>
    from torch_tensorrt._C import dtype, DeviceType, EngineCapability, TensorFormat
ImportError: /iker/envs/tensorrt/lib/python3.9/site-packages/torch_tensorrt/lib/libtorchtrt.so: undefined symbol: _ZNK3c104Type14isSubtypeOfExtERKSt10shared_ptrIS0_EPSo

To Reproduce

Steps to reproduce the behavior:

Python 3.9.7, A30 GPU with 470.82.01 driver version. Cuda version: cuda_11.3.r11.3. Cudnn: 8.2

I run the following command in a clean Python environment:

pip3 install --upgrade setuptools pip
pip3 install torch torchvision torchaudio --extra-index-url https://download.pytorch.org/whl/cu113
pip3 install --upgrade nvidia-pyindex
pip3 install --upgrade nvidia-tensorrt
pip3 install --upgrade torch-tensorrt -f https://github.com/NVIDIA/Torch-TensorRT/releases

export LD_LIBRARY_PATH="/iker/envs/tensorrt/lib/python3.9/site-packages/tensorrt/"

I can import tensorRT successfully

python3 -c "import tensorrt; print(tensorrt.__version__)"
8.4.0.6

Environment

aiohttp==3.8.1
aiosignal==1.2.0
async-timeout==4.0.2
attrs==21.4.0
certifi==2021.10.8
charset-normalizer==2.0.12
click==8.1.2
datasets==2.1.0
dill==0.3.4
filelock==3.6.0
frozenlist==1.3.0
fsspec==2022.3.0
huggingface-hub==0.5.1
idna==3.3
joblib==1.1.0
multidict==6.0.2
multiprocess==0.70.12.2
numpy==1.22.3
nvidia-cublas-cu11==2022.3.24
nvidia-cublas-cu116==11.9.2.110
nvidia-cuda-runtime-cu11==2021.12.20
nvidia-cuda-runtime-cu116==11.6.55
nvidia-cudnn-cu11==2022.4.2
nvidia-cudnn-cu115==8.3.3.40
nvidia-pyindex==1.0.9
nvidia-tensorrt==8.4.0.6
packaging==21.3
pandas==1.4.2
Pillow==9.1.0
pyarrow==7.0.0
pyparsing==3.0.8
python-dateutil==2.8.2
pytz==2022.1
PyYAML==6.0
regex==2022.4.24
requests==2.27.1
responses==0.18.0
sacremoses==0.0.49
six==1.16.0
tokenizers==0.12.1
torch==1.11.0+cu113
torch-tensorrt==1.0.0
torchaudio==0.11.0+cu113
torchvision==0.12.0+cu113
tqdm==4.64.0
transformers==4.18.0
typing_extensions==4.2.0
urllib3==1.26.9
xxhash==3.0.0
yarl==1.7.2
@ikergarcia1996 ikergarcia1996 added the bug Something isn't working label Apr 26, 2022
@narendasan
Copy link
Collaborator

This is probably because you are using PyTorch 1.11 with Torch-TensorRT 1.0.0 which targets PyTorch 1.10. Our 1.1.0 release is coming soon. In the meantime master supports 1.11

@ikergarcia1996
Copy link
Author

Problem solved by installing PyTorch 1.10, thank you!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants