Skip to content

Commit

Permalink
vis results for Mask RCNN and update test thr from 0.001 to 0.05
Browse files Browse the repository at this point in the history
  • Loading branch information
hellock committed Oct 5, 2018
1 parent ec20935 commit 1ed2d35
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 12 deletions.
27 changes: 17 additions & 10 deletions mmdet/models/detectors/mask_rcnn.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,20 @@ def __init__(self,
test_cfg,
pretrained=None):
super(MaskRCNN, self).__init__(
backbone=backbone,
neck=neck,
rpn_head=rpn_head,
bbox_roi_extractor=bbox_roi_extractor,
bbox_head=bbox_head,
mask_roi_extractor=mask_roi_extractor,
mask_head=mask_head,
train_cfg=train_cfg,
test_cfg=test_cfg,
pretrained=pretrained)
backbone=backbone,
neck=neck,
rpn_head=rpn_head,
bbox_roi_extractor=bbox_roi_extractor,
bbox_head=bbox_head,
mask_roi_extractor=mask_roi_extractor,
mask_head=mask_head,
train_cfg=train_cfg,
test_cfg=test_cfg,
pretrained=pretrained)

def show_result(self, data, result, img_norm_cfg, **kwargs):
# TODO: show segmentation masks
assert isinstance(result, tuple)
assert len(result) == 2 # (bbox_results, segm_results)
super(MaskRCNN, self).show_result(data, result[0], img_norm_cfg,
**kwargs)
2 changes: 1 addition & 1 deletion tools/configs/r50_fpn_frcnn_1x.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@
max_num=2000,
nms_thr=0.7,
min_bbox_size=0),
rcnn=dict(score_thr=1e-3, max_per_img=100, nms_thr=0.5))
rcnn=dict(score_thr=0.05, max_per_img=100, nms_thr=0.5))
# dataset settings
dataset_type = 'CocoDataset'
data_root = '../data/coco/'
Expand Down
2 changes: 1 addition & 1 deletion tools/configs/r50_fpn_maskrcnn_1x.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@
nms_thr=0.7,
min_bbox_size=0),
rcnn=dict(
score_thr=1e-3, max_per_img=100, nms_thr=0.5, mask_thr_binary=0.5))
score_thr=0.05, max_per_img=100, nms_thr=0.5, mask_thr_binary=0.5))
# dataset settings
dataset_type = 'CocoDataset'
data_root = '../data/coco/'
Expand Down

0 comments on commit 1ed2d35

Please sign in to comment.