Padding layer error Error Code 2: Internal Error (Assertion rank == 0 || rank == 1 failed. )

Description

I’m using the trtexec to parsing the onnx model and got the error as title. What’s the ‘rank’ mean and how could I fixed this error?

The trtexec command I used is:

trtexec.exe --onnx=C:\Users\jackg\Downloads\project\model\Depth\test_modified.onnx --saveEngine=C:\Users\jackg\Downloads\project\model\Depth\engine\test_fp16.trt --minShapes=‘input’:1x6x480x640 --optShapes=‘input’:1x6x480x640 --maxShapes=‘input’:1x6x480x640 --verbose --shapes=‘input’:1x6x480x640 --fp16

Here is the error image.

Environment

TensorRT Version: 8.4.1.5
NVIDIA GPU: 3080
NVIDIA Driver Version: 516.40
CUDA Version: 11.1
CUDNN Version: 8
Operating System: windows 10
Python Version (if applicable):
Tensorflow Version (if applicable):
PyTorch Version (if applicable):
Baremetal or Container (if so, version):

Relevant Files

Here is the onnx model. I convert it from tensorflow by using tf2onnx.
test_modified.zip (5.8 MB)

Steps To Reproduce

Hi,
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

check_model.py

import sys
import onnx
filename = yourONNXmodel
model = onnx.load(filename)
onnx.checker.check_model(model).
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
Thanks!

Hi @NVES,
I’ve “already” share the ONNX model and trtexec command. Have you seen my post clearly?

Hi,

Looks like you already created a Git issue, please refer to the response in the git issue.

Thank you.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.