Error while converting YOLOv3 model to IR

TCE Options

TCE Open Date: 

Thursday, February 13, 2020 - 19:23

Error while converting YOLOv3 model to IR


Hi, 
I'm following this official guide to convert and run YOLOv3 with OpenVino.
when I try to run model optimizer on the .pb file like this:

python3 mo_tf.py
--input_model /path/to/yolo_v3.pb
--tensorflow_use_custom_operations_config $MO_ROOT/extensions/front/tf/yolo_v3.json
--batch 1

 

I get following error:

Traceback (most recent call last):
  File "/opt/intel/openvino_2019.3.376/deployment_tools/model_optimizer/mo/main.py", line 298, in main
    return driver(argv)
  File "/opt/intel/openvino_2019.3.376/deployment_tools/model_optimizer/mo/main.py", line 247, in driver
    is_binary=not argv.input_model_is_text)
  File "/opt/intel/openvino_2019.3.376/deployment_tools/model_optimizer/mo/pipeline/tf.py", line 136, in tf2nx
    class_registration.apply_replacements(graph, class_registration.ClassType.FRONT_REPLACER)
  File "/opt/intel/openvino_2019.3.376/deployment_tools/model_optimizer/mo/utils/class_registration.py", line 299, in apply_replacements
    )) from err
Exception: Exception occurred during running replacer "REPLACEMENT_ID (<class 'extensions.front.tf.tensorflow_custom_operations_config_update.TensorflowCustomOperationsConfigUpdate'>)": The function 'update_custom_layer_attributes' must be implemented in the sub-class.

I've attached full DEBUG log of the error.
I'm using Ubuntu 18.04, kernel version 5.0.0
Any help would be much appreciated

AttachmentSize
Downloadapplication/octet-stream mylog.log233.85 KB
4 posts / 0 new

Hi Andrej,

I have converted the Yolo v3 model and did not run into any errors. That should be the correct json file. Can you please attach the .pb file you are converting? 

I see that you are running the last version of OpenVINO, can you please upgrade to the latest version 2020.1 and try again? 

Best Regards,

Sahira 


Hi,
I've attached the model.
I am using convert_weights_pb.py from https://github.com/mystic123/tensorflow-yolo-v3 to create it from yolov3.weights downloaded from here https://pjreddie.com/media/files/yolov3.weights.

Thanks,

Andrej

Attachments: 

AttachmentSize
Downloadapplication/zip frozen_model.zip220.65 MB

Hello again,

It looks like clean reinstallation of openvino toolkit and all the plugins resolved the issue. Thanks for help.

Best regards,
Andrej

Leave a Comment

Please sign in to add a comment. Not a member? Join today