OpenVINO™工具組 AttributeError:「Graph」物件沒有屬性「節點」

文件

錯誤訊息

000055576

2020 年 07 月 31 日

注意這個問題已得到解決,請務必將您的 OpenVINO 工具組更新至最新版本。

您看到的是什麼?

Model Optimizer version:     2019.3.0-375-g332562022
[ ERROR ]  -------------------------------------------------
[ ERROR ]  ----------------- INTERNAL ERROR ----------------
[ ERROR ]  Unexpected exception happened.
[ ERROR ]  Please contact Model Optimizer developers and forward the following information:
[ ERROR ]  'Graph' object has no attribute 'node'
[ ERROR ]  Traceback (most recent call last):
  File "/opt/intel/openvino_2019.3.334/deployment_tools/model_optimizer/mo/main.py", line 302, in main
    return driver(argv)
  File "/opt/intel/openvino_2019.3.334/deployment_tools/model_optimizer/mo/main.py", line 261, in driver
    custom_layers_mapping_path=custom_layers_mapping_path)
  File "/opt/intel/openvino_2019.3.334/deployment_tools/model_optimizer/mo/pipeline/caffe.py", line 65, in driver
    graph, original_shapes = loader.caffe_pb_to_nx(proto, model)
  File "/opt/intel/openvino_2019.3.334/deployment_tools/model_optimizer/mo/front/caffe/loader.py", line 294, in caffe_pb_to_nx
    graph.add_node(layer.name, pb=layer, model_pb=model_layer, kind='op', type='Parameter')
  File "/opt/intel/openvino_2019.3.334/deployment_tools/model_optimizer/mo/graph/graph.py", line 505, in add_node
    node.update_node()
  File "/opt/intel/openvino_2019.3.334/deployment_tools/model_optimizer/mo/graph/graph.py", line 470, in update_node
    in_ports_count = self.in_ports_count if self.has_valid('in_ports_count') else None
  File "/opt/intel/openvino_2019.3.334/deployment_tools/model_optimizer/mo/graph/graph.py", line 161, in has_valid
    return self.has(k) and not self.graph.node[self.node][k] is None
  File "/opt/intel/openvino_2019.3.334/deployment_tools/model_optimizer/mo/graph/graph.py", line 158, in has
    return k in self.graph.node[self.node]
AttributeError: 'Graph' object has no attribute 'node'

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

 

為什麼會看到它?

模型優化器與 Python * NetworkX 套件版本2.4 存在相容性問題。

如何修正:

若要安裝 Python * NetworkX 版本2.3,請執行以下指令。

pip3 install networkx==2.3