【问题标题】:How to Convert Detected Object to COCO dataset Json如何将检测到的对象转换为 COCO 数据集 Json
【发布时间】:2019-02-26 01:20:30
【问题描述】:

我在https://github.com/tensorflow/models/blob/master/research/object_detection/object_detection_tutorial.ipynb关注对象检测演示:

# Actual detection.
output_dict = run_inference_for_single_image(image_np, detection_graph) 

但我想将 output_dict(函数 run_inference_for_single_image(image_np, detection_graph) 的输出)转换为 COCO 注释 JSON 类型,以便我可以输入它以在不同的对象检测模型之间进行基准测试。

这是基准模型的代码:https://github.com/cocodataset/cocoapi/blob/master/PythonAPI/pycocoEvalDemo.ipynb

#initialize COCO detections api
resFile='%s/results/%s_%s_fake%s100_results.json'
resFile = resFile%(dataDir, prefix, dataType, annType)
cocoDt=cocoGt.loadRes(resFile)

但是你需要输入一个COCO Json类型。

有人可以告诉我如何从 output_dict 转换为 COCO Json 吗?

【问题讨论】:

  • 我也在寻找解决方案。你成功了吗?

标签: json python-3.x tensorflow object-detection-api


【解决方案1】:

【讨论】:

    猜你喜欢
    • 2018-03-19
    • 2018-11-21
    • 1970-01-01
    • 2011-03-17
    • 2011-05-20
    • 2011-09-28
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多