Tensorrt complains that DLA does not support dynamic shapes, even when I don't have any dynamic axes

Hello,
I am using trtexec that comes with my Jetpack 4.4 to run an onnx file, which is exported from a PyTorch Capsule-net model:
capsnet.onnx (22.5 MB)

In the pytorch script, I used torch.onnx.export without the dynamic_axes option. However, trtexec still complains that DLA Layer Mul_25 does not support dynamic shapes in any dimension. for basically all of my Add and Mul layers.

What could be wrong?

(The full output of /usr/src/tensorrt/bin/trtexec --onnx=./capsnet.onnx --avgRuns=32 --useDLACore=0 --fp16 --allowGPUFallback --workspace=8192:
trt.log (46.3 KB)
)

Hi,

First, the engine is successfully created but some layers are fallback to GPU.
Please noted that not all the TensorRT operations are supported by DLA.

You can find the detailed constraint in the below document:
https://docs.nvidia.com/deeplearning/tensorrt/developer-guide/index.html#dla_layers

Thanks.

I need more layers to run on DLA. That’s the whole reason of me using tensorrt.
According to your documentation, elementwise addition is supported.
It just complained about a non-existant dynamic shape, and I would like to know why.

Hi,

Since DLA is a hardware-based inference engine, there are much more constraints to deploy a model.
In the below limitation, it tends to imply that the dynamic cannot work on DLA.

Generic restrictions while running on DLA (applicable to all layers)

  • The dimensions used for building must be used at runtime.

Thanks.

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