PaddlePaddle / PaddleDetection

Object Detection toolkit based on PaddlePaddle. It supports object detection, instance segmentation, multiple object tracking and real-time multi-person keypoint detection.
Apache License 2.0
12.66k stars 2.87k forks source link

自定义数据集评估出错 #2413

Open xiaowanzizz opened 3 years ago

xiaowanzizz commented 3 years ago

File "tools/eval.py", line 193, in main() File "tools/eval.py", line 175, in main save_only=save_only) File "/home/zzf/Desktop/PaddleDetection/ppdet/utils/eval_utils.py", line 241, in eval_results save_only=save_only) File "/home/zzf/Desktop/PaddleDetection/ppdet/utils/coco_eval.py", line 102, in bbox_eval map_stats = cocoapi_eval(outfile, 'bbox', coco_gt=coco_gt) File "/home/zzf/Desktop/PaddleDetection/ppdet/utils/coco_eval.py", line 238, in cocoapi_eval coco_dt = coco_gt.loadRes(jsonfile) File "/home/zzf/miniconda3/envs/torch1.7.1/lib/python3.7/site-packages/pycocotools/coco.py", line 388, in loadRes 'Results do not correspond to current coco set' AssertionError: Results do not correspond to current coco set

infer.py可以得到正确的图片和标注结果 但是eval.py对自己训练的model 不能得出结果。

yghstill commented 3 years ago

@xiaowanzizz 你检查一下EvalReader中设置的anno_path的json文件是否正确,报错信息是json文件解析错误。

xiaowanzizz commented 3 years ago

@xiaowanzizz 你检查一下EvalReader中设置的anno_path的json文件是否正确,报错信息是json文件解析错误。

没错呀,是dataset/coco/annotations/instances_test2017.json

我上传一下我的json 文件,您可以检查一下。 jsonfile.zip