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
ResNet50_tensorflow
Commits
938f102d
Commit
938f102d
authored
Jul 13, 2020
by
syiming
Browse files
reshape output for second stage
parent
086d3873
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
2 deletions
+3
-2
research/object_detection/models/faster_rcnn_resnet_v1_fpn_keras_feature_extractor.py
...dels/faster_rcnn_resnet_v1_fpn_keras_feature_extractor.py
+2
-1
research/object_detection/models/faster_rcnn_resnet_v1_fpn_keras_feature_extractor_tf2_test.py
...er_rcnn_resnet_v1_fpn_keras_feature_extractor_tf2_test.py
+1
-1
No files found.
research/object_detection/models/faster_rcnn_resnet_v1_fpn_keras_feature_extractor.py
View file @
938f102d
...
@@ -265,7 +265,8 @@ class FasterRCNNResnetV1FpnKerasFeatureExtractor(
...
@@ -265,7 +265,8 @@ class FasterRCNNResnetV1FpnKerasFeatureExtractor(
feature_extractor_model
=
tf
.
keras
.
models
.
Sequential
([
feature_extractor_model
=
tf
.
keras
.
models
.
Sequential
([
tf
.
keras
.
layers
.
Flatten
(),
tf
.
keras
.
layers
.
Flatten
(),
tf
.
keras
.
layers
.
Dense
(
units
=
1024
,
activation
=
'relu'
),
tf
.
keras
.
layers
.
Dense
(
units
=
1024
,
activation
=
'relu'
),
tf
.
keras
.
layers
.
Dense
(
units
=
1024
,
activation
=
'relu'
)
tf
.
keras
.
layers
.
Dense
(
units
=
1024
,
activation
=
'relu'
),
tf
.
keras
.
layers
.
Reshape
((
1
,
1
,
1024
))
])
])
return
feature_extractor_model
return
feature_extractor_model
...
...
research/object_detection/models/faster_rcnn_resnet_v1_fpn_keras_feature_extractor_tf2_test.py
View file @
938f102d
...
@@ -91,4 +91,4 @@ class FasterRCNNResnetV1FpnKerasFeatureExtractorTest(tf.test.TestCase):
...
@@ -91,4 +91,4 @@ class FasterRCNNResnetV1FpnKerasFeatureExtractorTest(tf.test.TestCase):
model
(
proposal_feature_maps
))
model
(
proposal_feature_maps
))
features_shape
=
tf
.
shape
(
proposal_classifier_features
)
features_shape
=
tf
.
shape
(
proposal_classifier_features
)
self
.
assertAllEqual
(
features_shape
.
numpy
(),
[
3
,
1024
])
self
.
assertAllEqual
(
features_shape
.
numpy
(),
[
3
,
1
,
1
,
1024
])
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