Convert the pb files into UFF, some issues to solve

I am using Jetson Nano with Jetpack 4.2

Tensor RT Version :

Tensorflow version: 1.13.1

CUDNN version : 7.3.1

I tried with ssd_mobilenet_v1_coco custom trained model with my own dataset in win10
Tensorflow-Gpu version: 1.15.0
downloaded ssd_ mobilenet_v1 model from
but the following error occurred:
[TensorRT] ERROR: UFFParser: Validator error: Cast: Unsupported operation _Cast
So, I added following line
But I got the error,
“[TensorRT] ERROR: UFFParser: Parser error: BoxPredictor_0/Reshape: Reshape: -1 dimension specified more than 1 time”
I think object detection API version is high,
so I tried the version==518c1c,trained my model
it not works.
then I used Tensorflow-cpu version==1.12.0,object detection API version ==518c1c,
it can convert the pb files into UFF well.
you know,cpu is slow.then I tried Tensorflow-Gpu version==1.15.0,object detection API version==518c1c,trained my model and export pd file with tensorflow-cpu,
it also can works.


Since layer name is vary on the different model, the mapping function will need to update according to each model.

For ssd_mobilenet_v1, please update the mapping function into the following:

    namespace_plugin_map = {
        "MultipleGridAnchorGenerator": PriorBox,
        "Postprocessor": Postprocessor,
        "Preprocessor": Input,
        "Cast": Input,
        "image_tensor": Input,
        "MultipleGridAnchorGenerator/Concatenate": concat_priorbox,
        "concat": concat_box_loc,
        "concat_1": concat_box_conf

Some example can be found here: