How to restore a model by filename in Tensorflow r12?
<p>I have run the distributed mnist example:
<a href="https://github.com/tensorflow/tensorflow/blob/r0.12/tensorflow/tools/dist_test/python/mnist_replica.py" rel="noreferrer">https://github.com/tensorflow/tensorflow/blob/r0.12/tensorflow/tools/dist_test/python/mnist_replica.py</a></p>

<p>Though I have set the </p>

<p><code>saver = tf.train.Saver(max_to_keep=0)</code></p>

<p>In previous release, like r11, I was able to run over each check point model and evaluate the precision of the model. This gave me a plot of the progress of the precision versus global steps (or iterations). </p>

<p>Prior to r12, tensorflow checkpoint models were saved in two files, <code>model.ckpt-1234</code> and <code>model-ckpt-1234.meta</code>. One could restore a model by passing the <code>model.ckpt-1234</code> filename like so <code>saver.restore(sess,'model.ckpt-1234')</code>. </p>

<p>However, I've noticed that in r12, there are now three output files <code>model.ckpt-1234.data-00000-of-000001</code>, <code>model.ckpt-1234.index</code>, and <code>model.ckpt-1234.meta</code>. </p>

<p>I see that the the restore documentation says that a path such as <code>/train/path/model.ckpt</code> should be given to restore instead of a filename. Is there any way to load one checkpoint file at a time to evaluate it? I have tried passing the <code>model.ckpt-1234.data-00000-of-000001</code>, <code>model.ckpt-1234.index</code>, and <code>model.ckpt-1234.meta</code> files, but get errors like below:</p>

<p><code>W tensorflow/core/util/tensor_slice_reader.cc:95] Could not open logdir/2016-12-08-13-54/model.ckpt-0.data-00000-of-00001: Data loss: not an sstable (bad magic number): perhaps your file is in a different file format and you need to use a different restore operator?</code></p>

<p><code>NotFoundError (see above for traceback): Tensor name "hid_b" not found in checkpoint files logdir/2016-12-08-13-54/model.ckpt-0.index
     [[Node: save/RestoreV2_1 = RestoreV2[dtypes=[DT_FLOAT], _device="/job:localhost/replica:0/task:0/cpu:0"](_recv_save/Const_0, save/RestoreV2_1/tensor_names, save/RestoreV2_1/shape_and_slices)]]</code></p>

<p><code>W tensorflow/core/util/tensor_slice_reader.cc:95] Could not open logdir/2016-12-08-13-54/model.ckpt-0.meta: Data loss: not an sstable (bad magic number): perhaps your file is in a different file format and you need to use a different restore operator?</code></p>

<p>I'm running on OSX Sierra with tensorflow r12 installed via pip.</p>

<p>Any guidance would be helpful.</p>

<p>Thank you.</p>