• Home
  • History
  • Annotate
  • only in /external/tensorflow/tensorflow/contrib/eager/python/examples/resnet50/
NameDateSize

..10-Aug-20184 KiB

BUILD10-Aug-20181,009

README.md10-Aug-20181.5 KiB

resnet50.py10-Aug-201811.3 KiB

resnet50_graph_test.py10-Aug-20185.9 KiB

resnet50_test.py10-Aug-20189.2 KiB

README.md

1Image classification using the ResNet50 model described in
2[Deep Residual Learning for Image Recognition](https://arxiv.org/abs/1512.03385).
3
4Contents:
5
6- `resnet50.py`: Model definition
7- `resnet50_test.py`: Sanity unittests and benchmarks for using the model with
8  eager execution enabled.
9- `resnet50_graph_test.py`: Sanity unittests and benchmarks when using the same
10  model code to construct a TensorFlow graph.
11
12# Benchmarks
13
14Using a synthetic data, run:
15
16```
17# Using eager execution
18python resnet50_test.py --benchmarks=.
19
20# Using graph execution
21python resnet50_graph_test.py --benchmarks=.
22```
23
24The above uses the model definition included with the TensorFlow pip
25package. To build (and run benchmarks) from source:
26
27```
28# Using eager execution
29bazel run -c opt --config=cuda :resnet50_test -- --benchmarks=.
30
31# Using graph execution
32bazel run -c opt --config=cuda :resnet50_graph_test -- --benchmarks=.
33```
34
35(Or remove the `--config=cuda` flag for running on CPU instead of GPU).
36
37On October 31, 2017, the benchmarks demonstrated comparable performance
38for eager and graph execution of this particular model when using
39a single NVIDIA Titan X (Pascal) GPU on a host with an
40Intel Xeon E5-1650 CPU @ 3.50GHz and a batch size of 32.
41
42| Benchmark name                           | batch size    | images/second |
43| ---------------------------------------  | ------------- | ------------- |
44| eager_train_gpu_batch_32_channels_first  |            32 |           171 |
45| graph_train_gpu_batch_32_channels_first  |            32 |           172 |
46