From 80b47b1b88de9abfe9f7f679b65dc527132d49ef Mon Sep 17 00:00:00 2001 From: jerrywgz Date: Wed, 10 Jul 2019 12:55:11 +0800 Subject: [PATCH] fix mask eval for multi-batch (#2772) --- ppdet/utils/coco_eval.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ppdet/utils/coco_eval.py b/ppdet/utils/coco_eval.py index e7b01d673..7a8a59745 100644 --- a/ppdet/utils/coco_eval.py +++ b/ppdet/utils/coco_eval.py @@ -144,13 +144,13 @@ def mask2out(results, clsid2catid, resolution, thresh_binarize=0.5): continue masks = t['mask'][0] - im_shape = t['im_shape'][0][0] s = 0 # for each sample for i in range(len(lengths)): num = lengths[i] im_id = int(im_ids[i][0]) + im_shape = t['im_shape'][0][i] bbox = bboxes[s:s + num][:, 2:] clsid_scores = bboxes[s:s + num][:, 0:2] -- GitLab