ImportError onnxparser


I am getting this error while running the import tensorrt.legacy as trt

Awaiting for your response

File “”, line 51, in onnx_2_float32
apex = onnxparser.create_onnxconfig()
AttributeError: type object ‘onnxparser’ has no attribute ‘create_onnxconfig’


Looks like you are using a TRT 4 API that has been deprecated for some time now. Engineering recommends migrating to TRT6.
Please refer to following link for ONNX parser sample: