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
81cf6368
You need to sign in or sign up before continuing.
Commit
81cf6368
authored
Jul 17, 2020
by
Allen Wang
Committed by
A. Unique TensorFlower
Jul 17, 2020
Browse files
Change steps_per_loop to `None` by default.
PiperOrigin-RevId: 321855387
parent
9c314a03
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
official/vision/image_classification/resnet/common.py
official/vision/image_classification/resnet/common.py
+1
-1
official/vision/image_classification/resnet/resnet_ctl_imagenet_main.py
...n/image_classification/resnet/resnet_ctl_imagenet_main.py
+1
-1
No files found.
official/vision/image_classification/resnet/common.py
View file @
81cf6368
...
@@ -255,7 +255,7 @@ def define_keras_flags(
...
@@ -255,7 +255,7 @@ def define_keras_flags(
name
=
'tpu'
,
default
=
''
,
help
=
'TPU address to connect to.'
)
name
=
'tpu'
,
default
=
''
,
help
=
'TPU address to connect to.'
)
flags
.
DEFINE_integer
(
flags
.
DEFINE_integer
(
name
=
'steps_per_loop'
,
name
=
'steps_per_loop'
,
default
=
500
,
default
=
None
,
help
=
'Number of steps per training loop. Only training step happens '
help
=
'Number of steps per training loop. Only training step happens '
'inside the loop. Callbacks will not be called inside. Will be capped at '
'inside the loop. Callbacks will not be called inside. Will be capped at '
'steps per epoch.'
)
'steps per epoch.'
)
...
...
official/vision/image_classification/resnet/resnet_ctl_imagenet_main.py
View file @
81cf6368
...
@@ -125,7 +125,7 @@ def run(flags_obj):
...
@@ -125,7 +125,7 @@ def run(flags_obj):
per_epoch_steps
,
train_epochs
,
eval_steps
=
get_num_train_iterations
(
per_epoch_steps
,
train_epochs
,
eval_steps
=
get_num_train_iterations
(
flags_obj
)
flags_obj
)
if
not
flags_obj
.
steps_per_loop
:
if
flags_obj
.
steps_per_loop
is
None
:
steps_per_loop
=
per_epoch_steps
steps_per_loop
=
per_epoch_steps
elif
flags_obj
.
steps_per_loop
>
per_epoch_steps
:
elif
flags_obj
.
steps_per_loop
>
per_epoch_steps
:
steps_per_loop
=
per_epoch_steps
steps_per_loop
=
per_epoch_steps
...
...
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