Environment
TensorRT 7.1.0
Jetson tx2
[TRT] UffParser: Parser error: MobilenetV2/Conv/BatchNorm/FusedBatchNorm: The input to the Scale Layer is required to have a minimum of 3 dimensions.
How to fix it?
Environment
TensorRT 7.1.0
Jetson tx2
[TRT] UffParser: Parser error: MobilenetV2/Conv/BatchNorm/FusedBatchNorm: The input to the Scale Layer is required to have a minimum of 3 dimensions.
How to fix it?
Hi,
As mentioned in the log, it’s requires the input with at least 3 dimension:
In general, we don’t meet this issue for MobilenetV2.
May I know how do you generate the uff model first?
Which config.py file do you use?
Thanks.
Hi,
I converted the deeplabv3_mobilenetv2.pb which trained by myself to the .uff
the command as flollows:
python3 /usr/lib/python3.6/dist-packages/uff/bin/convert_to_uff.py --input-file deeplabv3_mobilenetv2.pb -O ArgMax -o mobilenet_0707.uff -p config.py -t
config.py
import tensorrt as trt
import graphsurgeon as gs
import tensorflow as tf
TRT_LOGGER = trt.Logger()
trt.init_libnvinfer_plugins(TRT_LOGGER,‘’)
Input = gs.create_node(“Input”,
concat_box_loc = gs.create_plugin_node(“concat_box_loc”, op=“FlattenConcat2_TRT”, dtype=tf.float32, axis=1, ignoreBatch=0)
concat_box_conf = gs.create_plugin_node(“concat_box_conf”, op=“FlattenConcat2_TRT”, dtype=tf.float32, axis=1, ignoreBatch=0)
resize = gs.create_plugin_node(“resize”, op=“ResizeBilinear_TRT”, dtype=tf.float32, axis=1)
space_to_batch = gs.create_plugin_node(“space_to_batch”, op=“SpaceToBatchND_TRT”, dtype=tf.float32, axis=1)
batch_to_space = gs.create_plugin_node(“batch_to_space”, op=“BatchToSpaceND_TRT”, dtype=tf.float32, axis=1)
namespace_plugin_map = {
def preprocess(dynamic_graph):
There is no update from you for a period, assuming this is not an issue any more.
Hence we are closing this topic. If need further support, please open a new one.
Thanks
Hi,
Sorry for the late update.
We try to reproduce this issue on our environment but can only find a pyTorch based deeplabv3_mobilenetv2 on the website.
Would you mind to share your model with us so we can check it directly?
Thanks.