Thanks for the clarification regarding 5D inputs. That makes sense.
So, I tried 4D input on my model.
image: [6, 3, 256, 704]
This should be a standard NCHW format (N=6, C=3, H=256, W=704).
But when I parse the model with Hailo parser, it automatically remaps the input to [256,704,3] in the HAR, as if it were treating the input as NHWC with N=1. This causes the same mismatch error as before:
BadInputsShape: Data shape (6,256,704,3) for layer fastbev_pre_trt/input_layer1
doesn't match network's input shape (256,704,3)
So my questions are:
-
If the ONNX input is strictly 4D
[6,3,256,704]
, why does the parser still squeeze it into[256,704,3]
? -
Does the parser only support 4D with N=1 (batch=1) and drop the batch dimension entirely?
-
If so, is there a way to force the parser to respect N>1 for batch (e.g. N=6 in my case), instead of collapsing it?
-
Or is the only viable solution again to fold the
6
into the channel dimension and make it[1,18,256,704]
before parsing?
This behavior seems to happen even when the model is already in valid 4D NCHW format, so I’d like to understand if this is an intentional limitation of the parser or a bug.
Thanks again for your help @omria !