Skip to content
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

❓ [Question] How to install torch_tensorrt corresponding to pytorch tensorrt version #3351

Open
swearirh opened this issue Jan 10, 2025 · 2 comments
Labels
question Further information is requested

Comments

@swearirh
Copy link

For example, I am using pytorch2.2.1, tensorrt10.2.0, how can I install torch_tensorrt (without changing pytorch, tensorrt versions)

@swearirh swearirh added the question Further information is requested label Jan 10, 2025
@narendasan
Copy link
Collaborator

How are you currently installing torch_tensorrt?

@swearirh
Copy link
Author

swearirh commented Jan 15, 2025

`pip3 list | grep torch

torch 2.4.1
torchaudio 2.4.1
torchsde 0.2.6
torchvision 0.19.1`

`pip3 list | grep tensor

safetensors 0.5.2
tensorrt 10.2.0`

and I run pip3 install https://download.pytorch.org/whl/cu121/torch_tensorrt-2.4.0%2Bcu121-cp38-cp38-linux_x86_64.whl#sha256=072edc48b58c454a6a4accb94b472aa8c3e708fdee82ff64ce91c674a58db894

`pip3 list | grep torch

torch 2.4.1
torch_tensorrt 2.4.0+cu121
torchaudio 2.4.1
torchsde 0.2.6
torchvision 0.19.1`

`pip3 list | grep tensor

safetensors 0.5.2
tensorrt 10.1.0
tensorrt_cu12 10.7.0
tensorrt-cu12-bindings 10.1.0
tensorrt-cu12-libs 10.1.0
torch_tensorrt 2.4.0+cu121`

`python3 -c "import tensorrt; print(tensorrt.version)"

Traceback (most recent call last):
File "", line 1, in
ModuleNotFoundError: No module named 'tensorrt'`

`python3 -c "import torch_tensorrt"

Traceback (most recent call last):
File "", line 1, in
File "/home/admin/zxl/comfyUI_flow/.tox/dev/lib/python3.8/site-packages/torch_tensorrt/init.py", line 114, in
_register_with_torch()
File "/home/admin/zxl/comfyUI_flow/.tox/dev/lib/python3.8/site-packages/torch_tensorrt/init.py", line 107, in _register_with_torch
torch.ops.load_library(linked_file_full_path)
File "/home/admin/zxl/comfyUI_flow/.tox/dev/lib/python3.8/site-packages/torch/_ops.py", line 1295, in load_library
ctypes.CDLL(path)
File "/usr/lib/python3.8/ctypes/init.py", line 373, in init
self._handle = _dlopen(self._name, mode)
OSError: /home/admin/zxl/comfyUI_flow/.tox/dev/lib/python3.8/site-packages/torch_tensorrt/lib/libtorchtrt.so: undefined symbol: _ZNSt10filesystem19temp_directory_pathEv`

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants