spconv
spconv copied to clipboard
Please, clarify your tensorrt guide
At the end of TENSORRT_INT8_GUDE you write:
write torch.fx based torch->trt conversion After PTQ/QAT model ready, we can use torch.fx.Interpreter to transform traced pytorch model to tensorrt.
see example.
But how do I can use torch.fx.Interpreter to transform traced pytorch model to tensorrt? torch.fx.Interpreter isn't a TensorRT interpreter, and spconv.pytorch.quantization.interpreter.NetworkInterpreter is also is not a TensorRT interpreter... Do I need to use TRTInterpreter from from torch.fx.experimental.fx2trt.fx2trt or something else?
At the end of TENSORRT_INT8_GUDE you write:
write torch.fx based torch->trt conversion After PTQ/QAT model ready, we can use torch.fx.Interpreter to transform traced pytorch model to tensorrt. see example.
But how do I can use torch.fx.Interpreter to transform traced pytorch model to tensorrt? torch.fx.Interpreter isn't a TensorRT interpreter, and spconv.pytorch.quantization.interpreter.NetworkInterpreter is also is not a TensorRT interpreter... Do I need to use TRTInterpreter from from torch.fx.experimental.fx2trt.fx2trt or something else?
I think NetworkInterpreter is a tensorrt interpreter, it is used to trace the fx graph and add layers. I built mine using https://github.com/traveller59/spconv/blob/master/example/mnist/custom_fx2trt.py