Installing TensorRT#

This guide provides step-by-step instructions for installing TensorRT using various methods. Choose the installation method that best fits your development environment and deployment needs.

Before You Begin: Ensure you have reviewed the Prerequisites to confirm your system meets all requirements.

What Is TensorRT, and What Does Installing It Give You?#

NVIDIA TensorRT is an SDK for high-performance deep learning inference (running a trained model on new inputs to produce predictions) on NVIDIA GPUs. It compiles a trained model into a hardware-specific binary called an engine (also referred to as a plan file), then runs that engine inside your application.

Installing TensorRT puts the following on your system:

  • The TensorRT libraries (libnvinfer, libnvonnxparser, and friends), which your C++ or Python application links against to load and execute engines.

  • Python bindings (the tensorrt Python package), so you can build, save, and run engines from Python without writing C++.

  • The trtexec command-line tool (Debian/RPM, tar/zip, and container installs only), which builds an engine from an ONNX file, benchmarks it, and is the fastest way to confirm a fresh non-pip install works. Pip wheels do not include trtexec.

  • C++ headers (NvInfer.h and friends), included with every method except pip, for applications that build against the C++ API.

After installation:

  • Non-pip methods: run trtexec --help and import tensorrt from Python, then follow Build Your First Engine.

  • Pip only: verify with import tensorrt (refer to Method 1: pip). For the ~10-minute CLI first-engine tutorial, install Debian/RPM, tar/zip, or container so trtexec is on your PATH.

If you only need to run engines built by someone else (for example, a deployment server), the Lean or Dispatch runtimes described below are smaller alternatives to the Full Runtime.

Installation Method Comparison#

Quick Comparison Table:

Method

Best For

Requires Root

C++ Headers

Multi-Version

Installation Time

pip (Python)

Python development

No

No

Yes (venv)

⚡ Fastest (~2 min)

Debian/RPM

System-wide install

Yes

Yes

No

🔵 Fast (~5 min)

Tar/Zip

Multiple versions

No

Yes

Yes

🟡 Moderate (~10 min)

Container (NGC)

Isolated environments

Docker access; initial setup may require administrator privileges

Yes

Yes

⚡ Fastest (~5 min)

The comparison groups Debian with RPM and tar with zip because each pair has the same operational tradeoffs. The Installation Methods section provides a separate page for every platform-specific method.

Choosing Your Installation Method#

Use the Installation Method Comparison table above to pick pip, Debian/RPM, Tar/Zip, or Container. Follow the matching page under Installation Methods for step-by-step instructions.

Understanding TensorRT Runtime Options#

TensorRT ships Full, Lean, and Dispatch runtime packages with different capabilities and footprints. For package names and a development-to-production workflow, refer to TensorRT Installation Modes in the prerequisites.

Downloading TensorRT#

Before installing with Debian (local repo), RPM (local repo), Tar, or Zip methods, you must download TensorRT packages.

Tip

For pip installation: Skip this section. The pip method downloads packages automatically from PyPI.

  1. Go to https://developer.nvidia.com/tensorrt/download/11x.

  2. Accept the license agreement.

  3. Select TensorRT version 11.4.0 (or your target version).

  4. For TensorRT 11.4.0, select the CUDA 13.4 update 1 package variant. Its filename contains cuda-13.4.

  5. Download the package for your platform:

    • Linux x86-64: Debian local repo (.deb), RPM local repo (.rpm), or Tar (.tar.zst)

    • Linux ARM SBSA: Debian local repo (.deb) or Tar (.tar.zst)

    • Windows x64: Zip (.zip)

    • Windows Arm64: Zip (.zip)

Installation Methods#

Verifying Your Installation#

Use this checklist first. Each install-method page adds package-manager or path-specific steps.

Table 8 Installation verification checklist#

Install method

Quick check

Expected result

Debian / RPM

Locate trtexec and add its directory to PATH by using the verification command on the matching package-manager page, then run trtexec --help

Prints trtexec usage (CLI present)

Tar / zip / container

trtexec --help

Prints trtexec usage (CLI present)

Debian / RPM / tar / zip / container

python3 -c "import tensorrt as trt; print(trt.__version__)"

Prints the installed TensorRT version

Pip

python3 -c "import tensorrt as trt; print(trt.__version__); assert trt.Builder(trt.Logger())"

Prints the version; Builder constructs without error

Pip

trtexec --help

Not expected to work (no CLI in pip wheels)

Debian / RPM / tar / zip / container (includes trtexec):

trtexec --help

If a Debian or RPM shell reports trtexec: command not found, use the trtexec_path command in Debian Installation or RPM Installation to locate the installed executable and add its directory to PATH. Tar and zip installs require the explicit PATH step on their method pages.

import tensorrt as trt
print(trt.__version__)

If both succeed, follow Build Your First Engine to build and run a test engine in about 10 minutes.

Pip (Python bindings and libraries only; no trtexec):

import tensorrt as trt
print(trt.__version__)
assert trt.Builder(trt.Logger())

Do not expect trtexec --help to work after a pip-only install. For the CLI first-engine tutorial, install a non-pip method above, or stay on the Python API path documented in the Quick Start Guide and samples.

Each method page adds method-specific verification (package queries, LD_LIBRARY_PATH / PATH, or Lean/Dispatch imports). If verification fails, refer to Troubleshooting.