Intel® Distribution of OpenVINO™ Toolkit
Community assistance about the Intel® Distribution of OpenVINO™ toolkit, OpenCV, and all aspects of computer vision-related on Intel® platforms.

2019R1 mo_tf error connverting yolov3-tiny

Trost__David
Beginner
283 Views

I got the following error attempting to convert my custom single class darknet yolov3-tiny model. I have run the model in darknet and it works.  Any ideas?

[ ERROR ]  -------------------------------------------------
[ ERROR ]  ----------------- INTERNAL ERROR ----------------
[ ERROR ]  Unexpected exception happened.
[ ERROR ]  Please contact Model Optimizer developers and forward the following information:
[ ERROR ]  Exception occurred during running replacer "REPLACEMENT_ID (<class 'extensions.middle.DeleteNotExecutable.DeleteNotExecutable'>)":
[ ERROR ]  Traceback (most recent call last):
  File "/home/badger/Desktop/OpenVino2019R1/openvino_2019.1.094/deployment_tools/model_optimizer/mo/utils/class_registration.py", line 174, in apply_replacements
    graph_clean_up)
  File "/home/badger/Desktop/OpenVino2019R1/openvino_2019.1.094/deployment_tools/model_optimizer/mo/middle/pattern_match.py", line 58, in for_graph_and_each_sub_graph_recursively
    func(graph)
  File "/home/badger/Desktop/OpenVino2019R1/openvino_2019.1.094/deployment_tools/model_optimizer/mo/middle/passes/eliminate.py", line 186, in graph_clean_up_tf
    graph_clean_up(graph, ['TFCustomSubgraphCall', 'Shape'])
  File "/home/badger/Desktop/OpenVino2019R1/openvino_2019.1.094/deployment_tools/model_optimizer/mo/middle/passes/eliminate.py", line 181, in graph_clean_up
    add_constant_operations(graph)
  File "/home/badger/Desktop/OpenVino2019R1/openvino_2019.1.094/deployment_tools/model_optimizer/mo/middle/passes/eliminate.py", line 145, in add_constant_operations
    Const(graph, dict(value=node.value, shape=np.array(node.value.shape))).create_node_with_data(data_nodes=node)
  File "/home/badger/Desktop/OpenVino2019R1/openvino_2019.1.094/deployment_tools/model_optimizer/mo/ops/op.py", line 207, in create_node_with_data
    [np.array_equal(old_data_value[id], data_node.value) for id, data_node in enumerate(data_nodes)])
AssertionError

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/home/badger/Desktop/OpenVino2019R1/openvino_2019.1.094/deployment_tools/model_optimizer/mo/main.py", line 312, in main
    return driver(argv)
  File "/home/badger/Desktop/OpenVino2019R1/openvino_2019.1.094/deployment_tools/model_optimizer/mo/main.py", line 263, in driver
    is_binary=not argv.input_model_is_text)
  File "/home/badger/Desktop/OpenVino2019R1/openvino_2019.1.094/deployment_tools/model_optimizer/mo/pipeline/tf.py", line 128, in tf2nx
    class_registration.apply_replacements(graph, class_registration.ClassType.MIDDLE_REPLACER)
  File "/home/badger/Desktop/OpenVino2019R1/openvino_2019.1.094/deployment_tools/model_optimizer/mo/utils/class_registration.py", line 190, in apply_replacements
    )) from err
Exception: Exception occurred during running replacer "REPLACEMENT_ID (<class 'extensions.middle.DeleteNotExecutable.DeleteNotExecutable'>)":

[ ERROR ]  ---------------- END OF BUG REPORT --------------
[ ERROR ]  -------------------------------------------------

0 Kudos
2 Replies
Shubha_R_Intel
Employee
283 Views

Dear David, you didn't post your actual Model Optimizer command but are you sure you're passing in C:\Program Files (x86)\IntelSWTools\openvino_2019.1.087\deployment_tools\model_optimizer\extensions\front\tf\yolo_v3_tiny.json  for --tensorflow_use_custom_operations_config ? Please carefully study the following document. 

https://docs.openvinotoolkit.org/latest/_docs_MO_DG_prepare_model_convert_model_tf_specific_Convert_YOLO_From_Tensorflow.html

Thanks !

Shubha

0 Kudos
Shubha_R_Intel
Employee
283 Views

Dear David,

Also X-referenced from another post, you need to upgrade Tensorflow also:

sudo -H pip3 install tensorflow==1.12.0 --upgrade

Thanks !

Shubha

0 Kudos
Reply