models
models copied to clipboard
[slim] Error with sync_replica when fine-tuning (using train_image_classifier.py)
I'm trying to run train_image_classifier.py with sync_replicas like this:
python train_image_classifier.py \
--train_dir=${TRAIN_DIR}/all \
--dataset_name=cifar10 \
--dataset_split_name=train \
--dataset_dir=${DATASET_DIR} \
--checkpoint_path=${TRAIN_DIR} \
--model_name=resnet_v1_50 \
--max_number_of_steps=3000 \
--batch_size=32 \
--num_clones=4 \
--learning_rate=0.0001 \
--save_interval_secs=10 \
--save_summaries_secs=10 \
--log_every_n_steps=10 \
--sync_replicas=True \
--optimizer=sgd
It runs without issue simply if I remove the --sync_replicas=True line.
Otherwise, here's the output:
I tensorflow/stream_executor/dso_loader.cc:135] successfully opened CUDA library libcublas.so.8.0 locally
I tensorflow/stream_executor/dso_loader.cc:135] successfully opened CUDA library libcudnn.so.5 locally
I tensorflow/stream_executor/dso_loader.cc:135] successfully opened CUDA library libcufft.so.8.0 locally
I tensorflow/stream_executor/dso_loader.cc:135] successfully opened CUDA library libcuda.so.1 locally
I tensorflow/stream_executor/dso_loader.cc:135] successfully opened CUDA library libcurand.so.8.0 locally
Traceback (most recent call last):
File "/notebooks/abouzoubaa/models/slim/train_image_classifier.py", line 584, in <module>
tf.app.run()
File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/platform/app.py", line 44, in run
_sys.exit(main(_sys.argv[:1] + flags_passthrough))
File "/notebooks/abouzoubaa/models/slim/train_image_classifier.py", line 532, in main
total_num_replicas=FLAGS.worker_replicas)
TypeError: __init__() got an unexpected keyword argument 'replica_id'
Any ideas what's causing this? Thanks in advance.
PS: I'm using tensorflow v1.0 and master of models (as of today 4/4).
@tfboyd is this issue still relevant?
Automatically closing due to lack of recent activity. Please update the issue when new information becomes available, and we will reopen the issue. Thanks!