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
b1034740
"torchvision/csrc/vscode:/vscode.git/clone" did not exist on "8520f0bea4a09e60a217fe3a8cf24b8f733ec16c"
Commit
b1034740
authored
Mar 11, 2019
by
Yanbing Dong
Browse files
Mod: modify the range of bbox in BboxTransform
parent
70383d46
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
mmdet/datasets/transforms.py
mmdet/datasets/transforms.py
+2
-2
No files found.
mmdet/datasets/transforms.py
View file @
b1034740
...
@@ -76,8 +76,8 @@ class BboxTransform(object):
...
@@ -76,8 +76,8 @@ class BboxTransform(object):
gt_bboxes
=
bboxes
*
scale_factor
gt_bboxes
=
bboxes
*
scale_factor
if
flip
:
if
flip
:
gt_bboxes
=
bbox_flip
(
gt_bboxes
,
img_shape
)
gt_bboxes
=
bbox_flip
(
gt_bboxes
,
img_shape
)
gt_bboxes
[:,
0
::
2
]
=
np
.
clip
(
gt_bboxes
[:,
0
::
2
],
0
,
img_shape
[
1
])
gt_bboxes
[:,
0
::
2
]
=
np
.
clip
(
gt_bboxes
[:,
0
::
2
],
0
,
img_shape
[
1
]
-
1
)
gt_bboxes
[:,
1
::
2
]
=
np
.
clip
(
gt_bboxes
[:,
1
::
2
],
0
,
img_shape
[
0
])
gt_bboxes
[:,
1
::
2
]
=
np
.
clip
(
gt_bboxes
[:,
1
::
2
],
0
,
img_shape
[
0
]
-
1
)
if
self
.
max_num_gts
is
None
:
if
self
.
max_num_gts
is
None
:
return
gt_bboxes
return
gt_bboxes
else
:
else
:
...
...
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