TRTEXEC with Facial Landmarks Estimation#

The trtexec tool is a command-line wrapper included as part of the TensorRT samples. Refer to the official TensorRT documentation for instructions on installing or building trtexec on your target platform (including x86 with discrete GPU and Jetson devices).

This section describes how to generate a TensorRT engine using trtexec, which allows you to deploy TAO-trained models on TensorRT, Triton, and Deepstream.

Sample Command for a Facial Landmarks Estimation Model#

To generate an .onnx file for Facial Landmarks Estimation, refer to the Facial Landmarks Estimation documentation. You can also refer to :the ref:Facial Landmarks Estimation documentation <facial_landmarks_estimation> for instructions on generating an INT8 calibration file.

trtexec --onnx=/path/to/model.onnx \
        --maxShapes=input_face_images:16x1x80x80 \
        --minShapes=input_face_images:1x1x80x80 \
        --optShapes=input_face_images:8x1x80x80 \
        --calib=/path/to/int8/calib.txt \
        --fp16 \
        --int8 \
        --saveEngine=/path/to/save/trt/model.engine