Is there pre-built TensorRT Python package for DRIVE AGX Orin?

@SivaRamaKrishnaNV The key steps are:

  1. Install TRT OSS
    cmake -DTRT_OUT_DIR=pwd/out -DTRT_PLATFORM_ID=aarch64 -DCMAKE_CUDA_COMPILER=/usr/local/cuda/bin/nvcc -DCUDA_VERSION=11.4 -DTRT_LIB_DIR=/lib/aarch64-linux-gnu/ -DCUDNN_LIB=/lib/aarch64-linux-gnu/libcudnn.so.8 -DTENSORRT_LIBRARY_INFER=/lib/aarch64-linux-gnu/libnvinfer.so.8 -Dnvinfer_LIB_PATH=/lib/aarch64-linux-gnu/libnvinfer.so.8 -Dnvparsers_LIB_PATH=/lib/aarch64-linux-gnu/libnvparsers.so.8 -DTENSORRT_LIBRARY_INFER_PLUGIN=/lib/aarch64-linux-gnu/libnvinfer_plugin.so.8 -DBUILD_ONNX_PYTHON=ON ..

  2. Install python bindings according to TensorRT/python at main · NVIDIA/TensorRT · GitHub

export EXT_PATH=~/external
mkdir -p $$EXT_PATH && cd $$EXT_PATH
git clone https://github.com/pybind/pybind11.git

# Add Main Headers
cd ~/external
wget https://www.python.org/ftp/python/3.8.10/Python-3.8.10.tar.xz
tar -xf Python-3.8.10.tar.xz
mkdir -p python-3.8
cp -r Python-3.8.10/Include/ python3.8/include

# Add PyConfig.h
sudo mkdir /usr/include/aarch64-linux-gnu/python3.8m
sudo apt install libpython3.8-dev
sudo cp /usr/include/aarch64-linux-gnu/python3.8/pyconfig.h /usr/include/aarch64-linux-gnu/python3.8m

sudo ln -s /usr/lib/aarch64-linux-gnu/libnvinfer.so.8 /usr/lib/aarch64-linux-gnu/libnvinfer.so
sudo ln -s /usr/lib/aarch64-linux-gnu/libnvonnxparser.so.8 /usr/lib/aarch64-linux-gnu/libnvonnxparser.so
sudo ln -s /usr/lib/aarch64-linux-gnu/libnvparsers.so.8 /usr/lib/aarch64-linux-gnu/libnvparsers.so
sudo ln -s /usr/lib/aarch64-linux-gnu/libnvinfer_plugin.so.8 /usr/lib/aarch64-linux-gnu/libnvinfer_plugin.so

cd $TRT_OSSPATH/python
export PYTHON=3.8
EXT_PATH=/home/nvidia/external PYTHON_MAJOR_VERSION=3 PYTHON_MINOR_VERSION=8 TARGET_ARCHITECTURE=aarch64 bash ./build.sh

pip install build/dist/tensorrt-*.whl

The built whl is uploaded. Hope it can help somebody.
tensorrt-8.2.0.6-cp38-none-linux_aarch64.whl (776.0 KB)

3 Likes