Hello,
I am experiencing an issue with TensorRT in Python on my Ubuntu 22.04 system. After installing TensorRT, I’m encountering a ModuleNotFoundError
when trying to import TensorRT in Python. I’m seeking assistance to resolve this issue.
System Configuration:
- OS: Ubuntu 22.04
- Python Version: 3.10
- CUDA Version: 11.8
- cuDNN Version: 8.9.7
- GCC Version: 11.4 ( now on 8.4 )
- NVIDIA Driver Version: 470
- TensorRT Version: 8.6.1 via pip installed
Issue Description: Upon attempting to import TensorRT in my Python virtual environment, I receive the following error:
pythonCopy code
ModuleNotFoundError: No module named 'tensorrt_bindings'
This error occurs when executing the following Python code:
pythonCopy code
import tensorrt as trt
Steps Taken:
- Installed TensorRT using the provided wheel file in a Python 3.10 virtual environment.
- Ensured that
LD_LIBRARY_PATH
includes the CUDA and cuDNN library paths. - Attempted to import TensorRT in Python, leading to the error mentioned above.
Additional Information:
- The TensorRT installation appears to be successful, and the
tensorrt
package is listed when I runpip list
in the virtual environment. - My
sys.path
in Python includes the site-packages directory where TensorRT is installed.
I am looking for guidance on:
- Resolving the
ModuleNotFoundError
fortensorrt_bindings
. - Understanding if there are additional steps or configurations required for TensorRT to work with Python 3.10 on Ubuntu 22.04.
- Any known compatibility issues or additional dependencies that I might be missing.
Thank you in advance for any help or suggestions!