Tensorflow对象检测评估pycocotools缺失

Fré*_*ard 5 evaluation object-detection tensorflow

关于宠物对象检测的TF教程:https://github.com/tensorflow/models/blob/master/research/object_detection/g3doc/running_pets.md

本地出发:https://github.com/tensorflow/models/blob/master/research/object_detection/g3doc/running_locally.md

培训似乎运作良好.

试图启动评估过程:

来自tensorflow/models/research /目录

python object_detection/eval.py\--logtostderr\--pipeline_config_path = $ {PATH_TO_YOUR_PIPELINE_CONFIG}\--checkpoint_dir = $ {PATH_TO_TRAIN_DIR}\--eval_dir = $ {PATH_TO_EVAL_DIR}

我收到以下错误:

来自pycocotools导入coco\ModuleNotFoundError:没有名为'pycocotools'的模块

看看coco API,但我没有看到任何明确的方法在Windows上安装它.

关于如何以最简单的方式运行评估的任何建议?


有关错误消息的更多详细信息:

Traceback (most recent call last):   File "object_detection/eval.py", line 50, in <module>
from object_detection import evaluator
File "D:\models\research\object_detection\evaluator.py", line 27, in <module>
from object_detection.metrics import coco_evaluation
File "D:\models\research\object_detection\metrics\coco_evaluation.py", line 20, in <module>
from object_detection.metrics import coco_tools
File "D:\models\research\object_detection\metrics\coco_tools.py", line 47, in <module>
from pycocotools import coco ModuleNotFoundError: No module named 'pycocotools'
Run Code Online (Sandbox Code Playgroud)

fro*_*ell 9

这为我解决了同样的问题:

pip3 install -U scikit-image
pip3 install -U cython 
pip3 install "git+https://github.com/philferriere/cocoapi.git#egg=pycocotools&subdirectory=PythonAPI"
Run Code Online (Sandbox Code Playgroud)

(如果使用的是python 2.7,请使用pip而不是pip3)


Der*_*how 1

您能否发布完整的堆栈跟踪,以便我们可以看到 pycocotools 是从哪里导入的?我们正在为 Tensorflow 对象检测 API 添加 COCO 支持(以及其他一些好东西),并将很快更新安装说明。