unmet dependencies- tensorrt : Depends: libnvinfer5

This worked. Thank you tbplant!

I am trying to install Tensorrt GA 5.1.5 from the nv-tensorrt-repo-ubuntu1604-cuda10.0-trt5.1.5.0-ga-20190427_1-1_amd64.deb file on an EC2 instance. I have the following configuration

  • Ubuntu 16.04
  • Tensorflow 1.14
  • Python 3.6
  • CUDA 10
  • CuDNN 7.5.1

I also face the same error while executing the following

~/software1$ sudo apt-get install tensorrt
Reading package lists… Done
Building dependency tree
Reading state information… Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
tensorrt : Depends: libnvinfer5 (= 5.1.5-1+cuda10.0) but it is not going to be installed
Depends: libnvinfer-dev (= 5.1.5-1+cuda10.0) but it is not going to be installed
Depends: libnvinfer-samples (>= 5.1.0-1+cuda10.0) but it is not going to be installed
Depends: libnvinfer-samples (<= 5.2.0-1+cuda10.0) but it is not going to be installed
E: Unable to correct problems, you have held broken packages

what should I do to resolve the changes, as most of the answers are for cuda 9

You need to install libcudnn7-dev via the NVIDIA .deb package, not just libcudnn7.

I am trying to install TensorRT using debian installation method. However I am unable to install it for the same problem .

dpkg-query -W | grep cuda                    
libcudnn7	7.6.5.32-1+cuda10.2
libcudnn7-dev	7.6.5.32-1+cuda10.2
libcudnn7-doc	7.6.5.32-1+cuda10.2
nv-tensorrt-repo-ubuntu1804-cuda10.2-trt7.1.3.4-ga-20200617	1-1

Error :

The following packages have unmet dependencies:
 tensorrt : Depends: libnvinfer7 (= 7.1.3-1+cuda10.2) but it is not going to be installed
            Depends: libnvinfer-plugin7 (= 7.1.3-1+cuda10.2) but it is not going to be installed
            Depends: libnvparsers7 (= 7.1.3-1+cuda10.2) but it is not going to be installed
            Depends: libnvonnxparsers7 (= 7.1.3-1+cuda10.2) but it is not going to be installed
            Depends: libnvinfer-bin (= 7.1.3-1+cuda10.2) but it is not going to be installed
            Depends: libnvinfer-dev (= 7.1.3-1+cuda10.2) but it is not going to be installed
            Depends: libnvinfer-plugin-dev (= 7.1.3-1+cuda10.2) but it is not going to be installed
            Depends: libnvparsers-dev (= 7.1.3-1+cuda10.2) but it is not going to be installed
            Depends: libnvonnxparsers-dev (= 7.1.3-1+cuda10.2) but it is not going to be installed
            Depends: libnvinfer-samples (= 7.1.3-1+cuda10.2) but it is not going to be installed
            Depends: libnvinfer-doc (= 7.1.3-1+cuda10.2) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

Installation sequence

sudo dpkg -i '/home/htut/Downloads/nv-tensorrt-repo-ubuntu1804-cuda10.2-trt7.1.3.4-ga-20200617_11_amd64.deb' 
sudo apt-key add /var/nv-tensorrt-repo-cuda10.2-trt7.1.3.4-ga-20200617/7fa2af80.pub
sudo apt-get update
sudo apt-get install tensorrt

What should I do to solve this?

oh bro…
it works. Thank you (ㅠ_ㅠ)