Description
While parse the attached onnx model the following error is raised:
`[02/06/2022-07:28:24] [E] Error[4]: [shuffleNode.cpp::symbolicExecute::387] Error Code 4: $nternal Error (Unsqueeze_15: IShuffleLayer applied to shape tensor must have 0 or 1 reshap$ dimensions: dimensions were [1,2])
[02/06/2022-07:28:24] [E] [TRT] parsers/onnx/ModelImporter.cpp:780: While parsing node num$er 35 [Pad → “338”]:
[02/06/2022-07:28:24] [E] [TRT] parsers/onnx/ModelImporter.cpp:781: — Begin node —
[02/06/2022-07:28:24] [E] [TRT] parsers/onnx/ModelImporter.cpp:782: input: “281”
input: “336”
input: “337”
output: “338”
name: “Pad_53”
op_type: “Pad”
attribute {
name: “mode”
s: “constant”
type: STRING
}
[02/06/2022-07:28:24] [E] [TRT] parsers/onnx/ModelImporter.cpp:783: — End node —
[02/06/2022-07:28:24] [E] [TRT] parsers/onnx/ModelImporter.cpp:785: ERROR: parsers/onnx/Mod
elImporter.cpp:179 In function parseGraph:
[6] Invalid Node - Pad_53`
Environment
TensorRT Version: 8.2.2.1
GPU Type: T4
Nvidia Driver Version: 470.57.02
CUDA Version: 11.6
Operating System + Version: Ubuntu20.4
Baremetal or Container (if container which image + tag): tensorrt:22.01-py3
Relevant Files
Steps To Reproduce
I processed the onnx model with fold-constants, referring to topic
import onnx
import onnx_graphsurgeon as gs
input_onnx_model="fasterrcnn_d2.onnx"
graph = gs.import_onnx(onnx.load(input_onnx_model))
graph.fold_constants().cleanup()
onnx.save(gs.export_onnx(graph), input_onnx_model)
Generate TRT
./trtexec --onnx=/home/fasterrcnn_d2.onnx -saveEngine=/home/fasterrcnn_d2.trt