Refer to mAP implemention Cartucho/mAP, and support rboxes mAP eval here.
Quick start next.
Creat directory as follow:
- detection-results: detections in standard format.
- ground-truth: gt in standard format.
- dets(op): your output, not recommended, just generate results in proper format in
detection-results
folder. - gts: raw ground truth files.
- images-optional(op): test imgs, not recommended, cause it's really time-consuming.
- converter
for each gt:
<class_name> <x1> <y1> <x2> <y2> <x3> <y3> <x4> <y4> [--<difficult>]
for each res(op):
<class_name> <conf> <x1> <y1> <x2> <y2> <x3> <y3> <x4> <y4>
and I'll release some common convert code here.
the directory created above is root_dir, then you can start evaluation as follow"
from map import eval_mAP
eval_mAP(root_dir)
difficult
string attached to gt will escape certain object from being included.(such as HRSC, ICDAR).ignore
variabel make it possible to ignore certain class from eval.- Horizontal bbox eval can be conducted via coordinate trans, or just use this repo Cartucho/mAP.
make convenient for calling.