ImportError: No module named 'tensorrt' in ubuntu 18.04

I installed tensorrt But got :

ImportError: No module named 'tensorrt'

1 answer

  • answered 2020-03-25 13:33 Sai Krishnadas

    pip3 install tensorrt-<version>-py2.py3-none-any.whl
    

    It can be found under home/TensorRT-version /python after you extract your .tar file.

    and add TensorRT to the path.

    export LD_LIBRARY_PATH="/home/path_to_tensorrt/lib"