Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ModelZoo
SOLOv2-pytorch
Commits
9ace2eee
Commit
9ace2eee
authored
Nov 27, 2018
by
Kai Chen
Browse files
support different nms methods
parent
785647af
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
configs/retinanet_r50_fpn_1x.py
configs/retinanet_r50_fpn_1x.py
+1
-1
mmdet/models/single_stage_heads/retina_head.py
mmdet/models/single_stage_heads/retina_head.py
+1
-1
No files found.
configs/retinanet_r50_fpn_1x.py
View file @
9ace2eee
...
@@ -40,9 +40,9 @@ train_cfg = dict(
...
@@ -40,9 +40,9 @@ train_cfg = dict(
debug
=
False
)
debug
=
False
)
test_cfg
=
dict
(
test_cfg
=
dict
(
nms_pre
=
1000
,
nms_pre
=
1000
,
nms_thr
=
0.5
,
min_bbox_size
=
0
,
min_bbox_size
=
0
,
score_thr
=
0.05
,
score_thr
=
0.05
,
nms
=
dict
(
type
=
'nms'
,
iou_thr
=
0.5
),
max_per_img
=
100
)
max_per_img
=
100
)
# dataset settings
# dataset settings
dataset_type
=
'CocoDataset'
dataset_type
=
'CocoDataset'
...
...
mmdet/models/single_stage_heads/retina_head.py
View file @
9ace2eee
...
@@ -282,6 +282,6 @@ class RetinaHead(nn.Module):
...
@@ -282,6 +282,6 @@ class RetinaHead(nn.Module):
padding
=
mlvl_scores
.
new_zeros
(
mlvl_scores
.
shape
[
0
],
1
)
padding
=
mlvl_scores
.
new_zeros
(
mlvl_scores
.
shape
[
0
],
1
)
mlvl_scores
=
torch
.
cat
([
padding
,
mlvl_scores
],
dim
=
1
)
mlvl_scores
=
torch
.
cat
([
padding
,
mlvl_scores
],
dim
=
1
)
det_bboxes
,
det_labels
=
multiclass_nms
(
mlvl_proposals
,
mlvl_scores
,
det_bboxes
,
det_labels
=
multiclass_nms
(
mlvl_proposals
,
mlvl_scores
,
cfg
.
score_thr
,
cfg
.
nms
_thr
,
cfg
.
score_thr
,
cfg
.
nms
,
cfg
.
max_per_img
)
cfg
.
max_per_img
)
return
det_bboxes
,
det_labels
return
det_bboxes
,
det_labels
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment