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
a9fe9ba9
Commit
a9fe9ba9
authored
Apr 05, 2021
by
Scott Zhu
Committed by
A. Unique TensorFlower
Apr 05, 2021
Browse files
Internal change
PiperOrigin-RevId: 366900579
parent
cc12499b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
2 deletions
+1
-2
official/vision/image_classification/resnet/common.py
official/vision/image_classification/resnet/common.py
+1
-2
No files found.
official/vision/image_classification/resnet/common.py
View file @
a9fe9ba9
...
@@ -22,7 +22,6 @@ import os
...
@@ -22,7 +22,6 @@ import os
from
absl
import
flags
from
absl
import
flags
import
tensorflow
as
tf
import
tensorflow
as
tf
from
tensorflow.python.keras.optimizer_v2
import
gradient_descent
as
gradient_descent_v2
import
tensorflow_model_optimization
as
tfmot
import
tensorflow_model_optimization
as
tfmot
from
official.utils.flags
import
core
as
flags_core
from
official.utils.flags
import
core
as
flags_core
from
official.utils.misc
import
keras_utils
from
official.utils.misc
import
keras_utils
...
@@ -109,7 +108,7 @@ class PiecewiseConstantDecayWithWarmup(
...
@@ -109,7 +108,7 @@ class PiecewiseConstantDecayWithWarmup(
def
get_optimizer
(
learning_rate
=
0.1
):
def
get_optimizer
(
learning_rate
=
0.1
):
"""Returns optimizer to use."""
"""Returns optimizer to use."""
# The learning_rate is overwritten at the beginning of each step by callback.
# The learning_rate is overwritten at the beginning of each step by callback.
return
gradient_descent_v2
.
SGD
(
learning_rate
=
learning_rate
,
momentum
=
0.9
)
return
tf
.
keras
.
optimizers
.
SGD
(
learning_rate
=
learning_rate
,
momentum
=
0.9
)
def
get_callbacks
(
pruning_method
=
None
,
def
get_callbacks
(
pruning_method
=
None
,
...
...
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