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
82b928fe
"vscode:/vscode.git/clone" did not exist on "5211b843f63053053eb4d1d1e00dc2ad578a5dc1"
Unverified
Commit
82b928fe
authored
Apr 05, 2019
by
Haoyu Zhang
Committed by
GitHub
Apr 05, 2019
Browse files
Add single GPU fp16 tests in legacy graph mode (#6533)
parent
cc98c0aa
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
0 deletions
+23
-0
official/resnet/keras/keras_imagenet_benchmark.py
official/resnet/keras/keras_imagenet_benchmark.py
+23
-0
No files found.
official/resnet/keras/keras_imagenet_benchmark.py
View file @
82b928fe
...
@@ -286,6 +286,29 @@ class Resnet50KerasBenchmarkBase(keras_benchmark.KerasBenchmark):
...
@@ -286,6 +286,29 @@ class Resnet50KerasBenchmarkBase(keras_benchmark.KerasBenchmark):
FLAGS
.
batch_size
=
128
FLAGS
.
batch_size
=
128
self
.
_run_and_report_benchmark
()
self
.
_run_and_report_benchmark
()
def
benchmark_graph_1_gpu_fp16
(
self
):
"""Test Keras model in legacy graph mode with 1 GPU and fp16."""
self
.
_setup
()
FLAGS
.
num_gpus
=
1
FLAGS
.
enable_eager
=
False
FLAGS
.
distribution_strategy
=
'default'
FLAGS
.
model_dir
=
self
.
_get_model_dir
(
'benchmark_graph_1_gpu_fp16'
)
FLAGS
.
batch_size
=
256
self
.
_run_and_report_benchmark
()
def
benchmark_graph_xla_1_gpu_fp16
(
self
):
"""Test Keras model in legacy graph mode with 1 GPU, fp16 and XLA."""
self
.
_setup
()
FLAGS
.
num_gpus
=
1
FLAGS
.
enable_eager
=
False
FLAGS
.
enable_xla
=
True
FLAGS
.
distribution_strategy
=
'default'
FLAGS
.
model_dir
=
self
.
_get_model_dir
(
'benchmark_graph_xla_1_gpu_fp16'
)
FLAGS
.
batch_size
=
256
self
.
_run_and_report_benchmark
()
def
benchmark_8_gpu
(
self
):
def
benchmark_8_gpu
(
self
):
"""Test Keras model with 8 GPUs."""
"""Test Keras model with 8 GPUs."""
self
.
_setup
()
self
.
_setup
()
...
...
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