yolov7
yolov7 copied to clipboard
Why does the exported end2end yolov7.onnx only get a mAP of 0.46721 on COCO dataset? while yolov7.pt's mAP is 0.512
I follow the tutorial to generate an end2end yolov7.onnx : https://github.com/WongKinYiu/yolov7/blob/main/tools/YOLOv7onnx.ipynb
however, the exported end2end yolov7.onnx only get a mAP of 0.46721 on COCO dataset, while yolov7.pt is 0.512 , why?
Use --conf-thres 0.001
during export https://github.com/WongKinYiu/yolov7/blob/main/test.py#L25
python export.py --weights yolov7-tiny.pt --grid --end2end --simplify \
--topk-all 100 --iou-thres 0.65 --conf-thres 0.001 --img-size 640 640 --max-wh 640
Use
--conf-thres 0.001
during export https://github.com/WongKinYiu/yolov7/blob/main/test.py#L25python export.py --weights yolov7-tiny.pt --grid --end2end --simplify \ --topk-all 100 --iou-thres 0.65 --conf-thres 0.001 --img-size 640 640 --max-wh 640
many thanks for your quick reply. I have set conf-thres to 0.001, and I also change topk-all to 500 in another try, but still get 0.467 mAP
is the preprocess method that matters? should do the same preprocess as test.py does? statistic aspect ratio, shapes, sort shapes, ...
can an yolov7.onnx of fixed 640x640 input shape get the mAP of 0.512?
only yolov7.onnx with dynamic width and height , and do the same preprocess as train or test(evaluate) course, can reach the mAP of 0.512?
my case.
--end2end cmd is not cood.
try python export.py --weights yolov7-tiny.pt --grid --include-nms //default thr=0.25
my case.
--end2end cmd is not cood.
try python export.py --weights yolov7-tiny.pt --grid --include-nms //default thr=0.25
Thank you very much! Can yolov7.onnx or yolov7-tiny.onnx reach the same mAP as yolov7.pt or yolov7-tiny.pt by this way? I will take a try