The Pytorch implementation is ultralytics/ultralytics
Reference wang-xinyu tensorrtx
TensorRT 8.2
OpenCV 4.6.0
Choose the model n/s/m/l/x from command line arguments.
Check more configs in include/config.h
- generate .wts from pytorch with .pt
// download https://github.com/ultralytics/assets/releases/download/v0.0.0/yolov8s.pt
cd yolov8
python gen_wts.py
// a file 'yolov8s.wts' will be generated.
-
Run CMakeLists.txt with Cmake
-
Open project and run it
-
set the macro USE_INT8 in config.h and make
-
serialize the model and test