You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
yolo export model=yolov8n.pt format=onnx # export official model
yolo export model=path/to/best.pt format=onnx # export custom trained model
Python
python export_onnx.py
fromultralyticsimportYOLO# Load a modelmodel=YOLO("yolov8n.pt") # load an official modelmodel=YOLO("path/to/best.pt") # load a custom trained# Export the modelmodel.export(format="onnx")
3.Build tensorrt_inference Project
cd ../ # in project directory
mkdir build && cd build
cmake ..
make -j
4.Run tensorrt_inference
inference with yolov8s
cd ../../bin/
./tensorrt_inference yolov8 ../configs/yolov8/config.yaml ../samples/detection_segmentation
inference with yolov8x6
cd ../../bin/
./tensorrt_inference yolov8 ../configs/yolov8/config_p6.yaml ../samples/detection_segmentation