【问题标题】:ImportError: No module named object_detection.builders in colab googleImportError:colab google 中没有名为 object_detection.builders 的模块
【发布时间】:2019-05-05 01:36:35
【问题描述】:

我运行的时候出现这个错误

%cd

!git clone --quiet https://github.com/tensorflow/models.git

!apt-get install -qq protobuf-compiler python-tk

!pip install -q Cython contextlib2 pillow lxml matplotlib PyDrive

!pip install -q pycocotools

%cd ~/models/research
!protoc object_detection/protos/*.proto --python_out=.

import os
os.environ['PYTHONPATH'] += ':/content/models/research/:/content/models/research/slim/'

!python object_detection/builders/model_builder_test.py 

我知道了

/root/models/research
Traceback (most recent call last):
  File "object_detection/builders/model_builder_test.py", line 23, in <module>
    from object_detection.builders import model_builder
ImportError: No module named object_detection.builders

有人可以帮助我,我在这方面工作了很多时间

【问题讨论】:

    标签: python tensorflow object-detection google-colaboratory


    【解决方案1】:

    Python 找不到模块“object_detection”。 解决方案:

    • 获取模块
    • 修复(包含)模块的路径。

    看看这是否有帮助:
    https://github.com/tensorflow/models/issues/1832

    【讨论】:

      【解决方案2】:
      pip install tensorflow-object-detection-api
      

      【讨论】:

        猜你喜欢
        • 2016-07-11
        • 2023-03-25
        • 2019-02-01
        • 2022-01-04
        • 1970-01-01
        • 1970-01-01
        • 2019-10-27
        • 2013-12-06
        • 2015-04-24
        相关资源
        最近更新 更多