Model Conversion to TensorRT

Hello, I want to convert my .pth model to .trt model, Will

Torch-TensorRT technique(Accelerating Inference Up to 6x Faster in PyTorch with Torch-TensorRT)

Will this technique work ?

Request you to share the ONNX model and the script if not shared already so that we can assist you better.
Alongside you can try few things:

  1. validating your model with the below snippet

import sys
import onnx
filename = yourONNXmodel
model = onnx.load(filename)
2) Try running your model with trtexec command.

In case you are still facing issue, request you to share the trtexec “”–verbose"" log for further debugging