title: ModuleNotFoundError: No module named 'tensorrt'
body: <p>Steps to recreate:</p>
  
  <pre><code>nvidia-docker run --rm nvcr.io/nvidia/pytorch:19.05-py3 python3 -c "import tensorrt"
  </code></pre>
  
  <p>Traceback (most recent call last):<br>
  File "", line 1, in <br>
  ModuleNotFoundError: No module named 'tensorrt'</p>
  
  <p>Other potentially useful info:</p>
  
  <pre><code>nvidia-docker run --rm nvcr.io/nvidia/pytorch:19.05-py3 nvcc -V
  </code></pre>
  
  <p>nvcc: NVIDIA (R) Cuda compiler driver<br>
  Copyright (c) 2005-2019 NVIDIA Corporation<br>
  Built on Thu_Apr_18_19:10:59_PDT_2019<br>
  Cuda compilation tools, release 10.1, V10.1.163</p>
  
  <pre><code>nvidia-docker run --rm nvcr.io/nvidia/pytorch:19.05-py3 nvidia-smi
  </code></pre>
  
  <p>Sun Jun 9 06:05:01 2019<br>
  +-----------------------------------------------------------------------------+<br>
  | NVIDIA-SMI 418.67 Driver Version: 418.67 CUDA Version: 10.1 |
  |-------------------------------+----------------------+----------------------+<br>
  | GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC |<br>
  | Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. |<br>
  |===============================+======================+======================|<br>
  | 0 GeForce RTX 208... On | 00000000:01:00.0 Off | N/A |<br>
  | 0% 37C P0 65W / 260W | 105MiB / 10989MiB | 2% Default |<br>
  +-------------------------------+----------------------+----------------------+<br>
  | 1 GeForce RTX 208... On | 00000000:02:00.0 Off | N/A |<br>
  | 0% 35C P8 19W / 260W | 1MiB / 10989MiB | 0% Default |<br>
  +-------------------------------+----------------------+----------------------+  </p>
  
  <p>+-----------------------------------------------------------------------------+<br>
  | Processes: GPU Memory |<br>
  | GPU PID Type Process name Usage |<br>
  |=============================================================================|<br>
  +-----------------------------------------------------------------------------+</p>
  
  <p>I can confirm the TensorRT samples (only checked sampleMNIST) work. I installed samples via nv-tensorrt-repo-ubuntu1804-cuda10.1-trt5.1.5.0-ga-20190427_1-1_amd64.deb.</p>
  
  <p>Also:</p>
  
  <pre><code>dpkg -l | grep libnvinfer
  </code></pre>
  
  <p>ii libnvinfer-dev 5.1.5-1+cuda10.1 amd64 TensorRT development libraries and headers</p>
  
  <p>ii libnvinfer-samples 5.1.5-1+cuda10.1 all TensorRT samples and documentation</p>
  
  <p>ii libnvinfer5 5.1.5-1+cuda10.1 amd64 TensorRT runtime libraries</p>