Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
seminar-breakout
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Shashank Suhas
seminar-breakout
Commits
7556cc1e
Commit
7556cc1e
authored
Nov 20, 2017
by
Yuxin Wu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[FasterRCNN] remove unused arg; fix bug in decode bbox
parent
a0324a28
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
4 deletions
+3
-4
examples/FasterRCNN/data.py
examples/FasterRCNN/data.py
+2
-3
examples/FasterRCNN/model.py
examples/FasterRCNN/model.py
+1
-1
No files found.
examples/FasterRCNN/data.py
View file @
7556cc1e
...
...
@@ -137,12 +137,11 @@ def get_anchor_labels(anchors, gt_boxes, crowd_boxes):
return
anchor_labels
,
anchor_boxes
def
get_rpn_anchor_input
(
im
,
boxes
,
klass
,
is_crowd
):
def
get_rpn_anchor_input
(
im
,
boxes
,
is_crowd
):
"""
Args:
im: an image
boxes: nx4, floatbox, gt. shoudn't be changed
klass: n,
is_crowd: n,
Returns:
...
...
@@ -220,7 +219,7 @@ def get_train_dataflow(add_mask=False):
# rpn anchor:
try
:
fm_labels
,
fm_boxes
=
get_rpn_anchor_input
(
im
,
boxes
,
klass
,
is_crowd
)
fm_labels
,
fm_boxes
=
get_rpn_anchor_input
(
im
,
boxes
,
is_crowd
)
boxes
=
boxes
[
is_crowd
==
0
]
# skip crowd boxes in training target
klass
=
klass
[
is_crowd
==
0
]
if
not
len
(
boxes
):
...
...
examples/FasterRCNN/model.py
View file @
7556cc1e
...
...
@@ -134,7 +134,7 @@ def decode_bbox_target(box_predictions, anchors):
xbyb
=
box_pred_txty
*
waha
+
xaya
x1y1
=
xbyb
-
wbhb
*
0.5
x2y2
=
xbyb
+
wbhb
*
0.5
# (...)x1x2
out
=
tf
.
concat
([
x1y1
,
x2y2
],
axis
=
1
)
out
=
tf
.
concat
([
x1y1
,
x2y2
],
axis
=
-
2
)
return
tf
.
reshape
(
out
,
orig_shape
)
...
...
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