Benchmark code
Clone or download
Pull request Compare This branch is 51 commits ahead, 398 commits behind tensorflow:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
logs
scripts
.gitignore
LICENSE
README.md
alexnet_model.py
backup_checkpoints.py
benchmark_storage.py
cbuild_benchmark_storage.py
cnn_util.py
convnet_builder.py
datasets.py
densenet_model.py
eval_checkpoints.py
googlenet_model.py
inception_model.py
lenet_model.py
model.py
model_config.py
overfeat_model.py
preprocessing.py
resnet_model.py
sweep_parameters.py
sweep_parameters_distributed.py
tf_cnn_benchmarks.py
time_inference.py
trivial_model.py
variable_mgr.py
vgg_model.py

README.md

ResNets for ImageNet on TensorFlow

To train a ResNet, run,

python3 tf_cnn_benchmarks.py --model=resnet50 --data_dir=../../../../data/imagenet/
                             --checkpoint_dir=/lfs/1/deepak/checkpoints/resnet50_lr=0.05
                             --num_batches=1800000 --subset=train --learning_rate=0.05
                             --learning_rate_decay_factor=0.1 --num_epochs_per_decay=30
                             --optimizer=momentum --weight_decay=0.0001

This command produces model checkpoints written after every epoch. To evaluate each of these checkpoints, run,

python3 eval_checkpoints.py -i /lfs/1/deepak/checkpoints/resnet50_lr=0.05/
                            -c "python tf_cnn_benchmarks.py --model=resnet50 --eval --data_dir=/lfs/1/deepak/data/imagenet/ --eval_subset=validation --num_batches=100 --batch_size=500"

Other example command lines are available in the scripts/ directory (for example, training and evaluating ResNet152 on 4 GPUs).

Make sure to first follow the instructions in the TensorFlow models repository to get necessary data, etc.