Hi,
When I try to run my SNPE model with batch_size > 1. I ended up with this error:
java.lang.IllegalStateException: Failed to forward propagate inputs! Cause: error_code=211; error_message=Tensor shape mismatch: input doesn't meet layer's tensor shape. Input Tensor shape does not match input layer shape: input0; error_component=Dl System; line_no=498; thread_id=522049361136
SNPE: 1.36
Model: converted from ONNX with size (1, 100, 100, 3). That means batch_size for my ONNX model is fixed to 1, but ONNX model works well with dynamic batch_size.
My purpose to use batch_size >1 to reduce running time. Instead of feed single image to SNPE model, I might want to feed 2 images in one forward.
Hope to have your idea to solve it!
Thanks in advance!
Hi
From your explanation, I understand that you would like to load two images to reduce the running time but the model inference is performed on only one image.
So, you may not find much difference in trying to compute forwarding 2 or more images at once.
Also, NPE does not support the dynamic batch size.
If you want to run your model with 2 images fed to the network, you need to convert your model again with shape (2,100,100,3).
Thank you, I hope this resolves your question.