遵循关于宠物对象检测的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}我得到了以下错误
from pycocotools import coco \
ModuleNotFoundError: No module named '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'发布于 2018-03-20 17:26:19
这为我解决了同样的问题:
pip3 install -U scikit-image
pip3 install -U cython
pip3 install "git+https://github.com/philferriere/cocoapi.git#egg=pycocotools&subdirectory=PythonAPI"(如果您使用的是Python2.7,请使用pip而不是pip3 )
发布于 2018-02-14 01:14:15
你能发布完整的堆栈跟踪,这样我们就可以看到pycocotools是从哪里导入的吗?我们正在将COCO支持添加到Tensorflow对象检测API (以及其他一些好东西)中,并将很快更新安装说明。
发布于 2020-07-18 03:22:04
下面的命令对我很有效。
pip install pycocotoolshttps://stackoverflow.com/questions/48747208
复制相似问题