文章 ID: 000088875 內容類型: 疑難排解 最近查看日期: 2022 年 05 月 20 日

無法使用 2020.4.582 OpenVINO™將自訂 TensorFlow* 2 模型轉換為中間表示 (IR)

環境

OpenVINO 2020.4.582,TensorFlow 2.6.0

BUILT IN - ARTICLE INTRO SECOND COMPONENT
摘要

TensorFlow 2.0 物件偵測 API 模型支援的OpenVINO版本。

描述
  • 轉換自訂 TensorFlow 2 型號 mask_rcnn_inception_resnet_v2_1024x1024_coco17 以使用 Model Optimizer 命令的 IR:
     
    注意上方的連結可能無法正確下載檔案。您可能需要複製(以滑鼠右鍵和複製連結位址)並直接將連結貼到瀏覽器中以開啟檔案。

    "Exception: Exception occurred during running replacer "REPLACEMENT_ID ()": The function 'update_custom_layer_attributes' must be implemented in the sub-class."

    python mo_tf.py

    --saved_model_dir C:\DATASETS\mask50000\exports\saved_model

    --output_dir C:\DATASETS\mask50000

    --reverse_input_channels

    --tensorflow_custom_operations_config extensions\front\tf\mask_rcnn_support_api_v2.4.json

    --tensorflow_object_detection_api_pipeline_config C:\DATASETS\mask50000\exports\pipeline.config

    --log_level=DEBUG

  • 收到錯誤:

    "Exception: Exception occurred during running replacer "REPLACEMENT_ID ()": The function 'update_custom_layer_attributes' must be implemented in the sub-class."

解決方法

TensorFlow 2.0 物件偵測 API 模型的支援,從 2021 年OpenVINO日開始才完全啟用。

升級 至 OpenVINO 2021.3 或更新版本。

相關產品

本文章適用於 2 產品

這個頁面的內容綜合了英文原始內容的人工翻譯譯文與機器翻譯譯文。本內容是基於一般資訊目的,方便您參考而提供,不應視同完整或準確的內容。如果這個頁面的英文版與譯文之間發生任何牴觸,將受英文版規範及管轄。 查看這個頁面的英文版。