Skip to content

KennyTang1988/hello_tensorrt

 
 

Repository files navigation

install cuda, cudnn, tensorrt

  1. cuda-11
  2. cudnn-8.2.1
  3. tensorrt 8.2.1.8

get and patch tensorrt-oss

git clone https://github.com/NVIDIA/TensorRT/
pushd TensorRT
git submodule update --init --recursive
git checkout 156c59ae86d454fa89146fe65fa7332dbc8c3c2b
git submodule update
git apply ../tensorrt.diff
popd

build tensorrt

pushd TensorRT
mkdir -p build && cd build
CUDACXX=/opt/anaconda3/envs/cuda-11/bin/nvcc cmake .. -DTRT_LIB_DIR=/opt/anaconda3/envs/cuda-11/lib -DTRT_OUT_DIR=`pwd`/out
make
popd

get pretrianed model

get models from https://mega.nz/folder/X5UD1LDY#8ZI-gAq6AkpcUbE2z4n6RA and save models to model directory

run

make run-mnist make run-googlenet make run-mobilenet make run-resnet

run with int8

  1. turn on CPPFLAGS += -DINT8 in Makefile
  2. make clean
  3. make run-mnist

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C++ 66.3%
  • Cuda 28.9%
  • Makefile 2.0%
  • C 1.3%
  • Dockerfile 1.1%
  • Python 0.4%