<p dir="auto">I've tried to run the setup code in the tutorial, but I met some confusing running errors. I'm new to tensorflow, so I have no idea how to deal with it. Could anybody help me fix this problem? Thanks a lot!</p>
<div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="from __future__ import absolute_import
from __future__ import division
from __future__ import print_function

import os

import numpy as np
import tensorflow as tf

# Data sets
IRIS_TRAINING = os.path.join(os.path.dirname(__file__), &quot;iris_training.csv&quot;)
IRIS_TEST = os.path.join(os.path.dirname(__file__), &quot;iris_test.csv&quot;)

def main(unused_argv):
    # Load datasets.
    training_set = tf.contrib.learn.datasets.base.load_csv_with_header(
        filename=IRIS_TRAINING, target_dtype=np.int, features_dtype=np.float32)
    test_set = tf.contrib.learn.datasets.base.load_csv_with_header(
        filename=IRIS_TEST, target_dtype=np.int, features_dtype=np.float32)

    # Specify that all features have real-value data
    feature_columns = [tf.contrib.layers.real_valued_column(&quot;&quot;, dimension=4)]

    # Build 3 layer DNN with 10, 20, 10 units respectively.
    classifier = tf.contrib.learn.DNNClassifier(feature_columns=feature_columns,
                                                hidden_units=[10, 20, 10],
                                                n_classes=3,
                                                model_dir=&quot;/tmp/iris_model&quot;)

    # Fit model.
    classifier.fit(x=training_set.data,
                   y=training_set.target,
                   steps=2000)

    # Evaluate accuracy.
    accuracy_score = classifier.evaluate(x=test_set.data,
                                         y=test_set.target)[&quot;accuracy&quot;]
    print('Accuracy: {0:f}'.format(accuracy_score))

    # Classify two new flower samples.
    new_samples = np.array(
        [[6.4, 3.2, 4.5, 1.5], [5.8, 3.1, 5.0, 1.7]], dtype=float)
    y = list(classifier.predict(new_samples, as_iterable=True))
    print('Predictions: {}'.format(str(y)))

if __name__ == &quot;__main__&quot;:
  tf.app.run()"><pre class="notranslate"><span class="pl-k">from</span> __future__ <span class="pl-k">import</span> <span class="pl-s1">absolute_import</span>
<span class="pl-k">from</span> __future__ <span class="pl-k">import</span> <span class="pl-s1">division</span>
<span class="pl-k">from</span> __future__ <span class="pl-k">import</span> <span class="pl-s1">print_function</span>

<span class="pl-k">import</span> <span class="pl-s1">os</span>

<span class="pl-k">import</span> <span class="pl-s1">numpy</span> <span class="pl-k">as</span> <span class="pl-s1">np</span>
<span class="pl-k">import</span> <span class="pl-s1">tensorflow</span> <span class="pl-k">as</span> <span class="pl-s1">tf</span>

<span class="pl-c"># Data sets</span>
<span class="pl-v">IRIS_TRAINING</span> <span class="pl-c1">=</span> <span class="pl-s1">os</span>.<span class="pl-s1">path</span>.<span class="pl-en">join</span>(<span class="pl-s1">os</span>.<span class="pl-s1">path</span>.<span class="pl-en">dirname</span>(<span class="pl-s1">__file__</span>), <span class="pl-s">"iris_training.csv"</span>)
<span class="pl-v">IRIS_TEST</span> <span class="pl-c1">=</span> <span class="pl-s1">os</span>.<span class="pl-s1">path</span>.<span class="pl-en">join</span>(<span class="pl-s1">os</span>.<span class="pl-s1">path</span>.<span class="pl-en">dirname</span>(<span class="pl-s1">__file__</span>), <span class="pl-s">"iris_test.csv"</span>)

<span class="pl-k">def</span> <span class="pl-en">main</span>(<span class="pl-s1">unused_argv</span>):
    <span class="pl-c"># Load datasets.</span>
    <span class="pl-s1">training_set</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">contrib</span>.<span class="pl-s1">learn</span>.<span class="pl-s1">datasets</span>.<span class="pl-s1">base</span>.<span class="pl-en">load_csv_with_header</span>(
        <span class="pl-s1">filename</span><span class="pl-c1">=</span><span class="pl-v">IRIS_TRAINING</span>, <span class="pl-s1">target_dtype</span><span class="pl-c1">=</span><span class="pl-s1">np</span>.<span class="pl-s1">int</span>, <span class="pl-s1">features_dtype</span><span class="pl-c1">=</span><span class="pl-s1">np</span>.<span class="pl-s1">float32</span>)
    <span class="pl-s1">test_set</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">contrib</span>.<span class="pl-s1">learn</span>.<span class="pl-s1">datasets</span>.<span class="pl-s1">base</span>.<span class="pl-en">load_csv_with_header</span>(
        <span class="pl-s1">filename</span><span class="pl-c1">=</span><span class="pl-v">IRIS_TEST</span>, <span class="pl-s1">target_dtype</span><span class="pl-c1">=</span><span class="pl-s1">np</span>.<span class="pl-s1">int</span>, <span class="pl-s1">features_dtype</span><span class="pl-c1">=</span><span class="pl-s1">np</span>.<span class="pl-s1">float32</span>)

    <span class="pl-c"># Specify that all features have real-value data</span>
    <span class="pl-s1">feature_columns</span> <span class="pl-c1">=</span> [<span class="pl-s1">tf</span>.<span class="pl-s1">contrib</span>.<span class="pl-s1">layers</span>.<span class="pl-en">real_valued_column</span>(<span class="pl-s">""</span>, <span class="pl-s1">dimension</span><span class="pl-c1">=</span><span class="pl-c1">4</span>)]

    <span class="pl-c"># Build 3 layer DNN with 10, 20, 10 units respectively.</span>
    <span class="pl-s1">classifier</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">contrib</span>.<span class="pl-s1">learn</span>.<span class="pl-v">DNNClassifier</span>(<span class="pl-s1">feature_columns</span><span class="pl-c1">=</span><span class="pl-s1">feature_columns</span>,
                                                <span class="pl-s1">hidden_units</span><span class="pl-c1">=</span>[<span class="pl-c1">10</span>, <span class="pl-c1">20</span>, <span class="pl-c1">10</span>],
                                                <span class="pl-s1">n_classes</span><span class="pl-c1">=</span><span class="pl-c1">3</span>,
                                                <span class="pl-s1">model_dir</span><span class="pl-c1">=</span><span class="pl-s">"/tmp/iris_model"</span>)

    <span class="pl-c"># Fit model.</span>
    <span class="pl-s1">classifier</span>.<span class="pl-en">fit</span>(<span class="pl-s1">x</span><span class="pl-c1">=</span><span class="pl-s1">training_set</span>.<span class="pl-s1">data</span>,
                   <span class="pl-s1">y</span><span class="pl-c1">=</span><span class="pl-s1">training_set</span>.<span class="pl-s1">target</span>,
                   <span class="pl-s1">steps</span><span class="pl-c1">=</span><span class="pl-c1">2000</span>)

    <span class="pl-c"># Evaluate accuracy.</span>
    <span class="pl-s1">accuracy_score</span> <span class="pl-c1">=</span> <span class="pl-s1">classifier</span>.<span class="pl-en">evaluate</span>(<span class="pl-s1">x</span><span class="pl-c1">=</span><span class="pl-s1">test_set</span>.<span class="pl-s1">data</span>,
                                         <span class="pl-s1">y</span><span class="pl-c1">=</span><span class="pl-s1">test_set</span>.<span class="pl-s1">target</span>)[<span class="pl-s">"accuracy"</span>]
    <span class="pl-en">print</span>(<span class="pl-s">'Accuracy: {0:f}'</span>.<span class="pl-en">format</span>(<span class="pl-s1">accuracy_score</span>))

    <span class="pl-c"># Classify two new flower samples.</span>
    <span class="pl-s1">new_samples</span> <span class="pl-c1">=</span> <span class="pl-s1">np</span>.<span class="pl-en">array</span>(
        [[<span class="pl-c1">6.4</span>, <span class="pl-c1">3.2</span>, <span class="pl-c1">4.5</span>, <span class="pl-c1">1.5</span>], [<span class="pl-c1">5.8</span>, <span class="pl-c1">3.1</span>, <span class="pl-c1">5.0</span>, <span class="pl-c1">1.7</span>]], <span class="pl-s1">dtype</span><span class="pl-c1">=</span><span class="pl-s1">float</span>)
    <span class="pl-s1">y</span> <span class="pl-c1">=</span> <span class="pl-en">list</span>(<span class="pl-s1">classifier</span>.<span class="pl-en">predict</span>(<span class="pl-s1">new_samples</span>, <span class="pl-s1">as_iterable</span><span class="pl-c1">=</span><span class="pl-c1">True</span>))
    <span class="pl-en">print</span>(<span class="pl-s">'Predictions: {}'</span>.<span class="pl-en">format</span>(<span class="pl-en">str</span>(<span class="pl-s1">y</span>)))

<span class="pl-k">if</span> <span class="pl-s1">__name__</span> <span class="pl-c1">==</span> <span class="pl-s">"__main__"</span>:
  <span class="pl-s1">tf</span>.<span class="pl-s1">app</span>.<span class="pl-en">run</span>()</pre></div>
<p dir="auto">Here is what I saw:<br>
WARNING:tensorflow:From .\logging_monitoring.py:33: calling BaseEstimator.fit (from tensorflow.contrib.learn.python.learn.estimators.estimator) with x is deprecated and will be removed after 2016-12-01.<br>
Instructions for updating:<br>
Estimator is decoupled from Scikit Learn interface by moving into<br>
separate class SKCompat. Arguments x, y and batch_size are only<br>
available in the SKCompat class, Estimator will only accept input_fn.<br>
Example conversion:<br>
est = Estimator(...) -&gt; est = SKCompat(Estimator(...))<br>
WARNING:tensorflow:From .\logging_monitoring.py:33: calling BaseEstimator.fit (from tensorflow.contrib.learn.python.learn.estimators.estimator) with y is deprecated and will be removed after 2016-12-01.<br>
Instructions for updating:<br>
Estimator is decoupled from Scikit Learn interface by moving into<br>
separate class SKCompat. Arguments x, y and batch_size are only<br>
available in the SKCompat class, Estimator will only accept input_fn.<br>
Example conversion:<br>
est = Estimator(...) -&gt; est = SKCompat(Estimator(...))<br>
WARNING:tensorflow:From C:\Program Files\Python36\lib\site-packages\tensorflow\contrib\learn\python\learn\estimators\head.py:642: scalar_summary (from tensorflow.python.ops.logging_ops) is deprecated and will be removed after 2016-11-30.<br>
Instructions for updating:<br>
Please switch to tf.summary.scalar. Note that tf.summary.scalar uses the node name instead of the tag. This means that TensorFlow will automatically de-duplicate summary names based on the scope they are created in. Also, passing a tensor or list of tags to a scalar summary op is no longer supported.<br>
2017-09-07 20:00:50.306221: W C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\platform\cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use AVX instructions, but these are available on your machine and could speed up CPU computations.<br>
2017-09-07 20:00:50.306424: W C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\platform\cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use AVX2 instructions, but these are available on your machine and could speed up CPU computations.<br>
2017-09-07 20:00:50.447012: W C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\framework\op_kernel.cc:1192] Not found: Key dnn/hiddenlayer_0/biases not found in checkpoint<br>
2017-09-07 20:00:50.447738: W C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\framework\op_kernel.cc:1192] Not found: Key dnn/hiddenlayer_0/weights not found in checkpoint<br>
2017-09-07 20:00:50.448265: W C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\framework\op_kernel.cc:1192] Not found: Key dnn/hiddenlayer_0/biases/denlayer_0/biases/part_0/Adagrad not found in checkpoint<br>
2017-09-07 20:00:50.451033: W C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\framework\op_kernel.cc:1192] Not found: Key dnn/multi_class_head/dnn/learning_rate not found in checkpoint<br>
2017-09-07 20:00:50.451078: W C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\framework\op_kernel.cc:1192] Not found: Key dnn/hiddenlayer_1/biases not found in checkpoint<br>
2017-09-07 20:00:50.451715: W C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\framework\op_kernel.cc:1192] Not found: Key dnn/hiddenlayer_0/weights/enlayer_0/weights/part_0/Adagrad not found in checkpoint<br>
2017-09-07 20:00:50.452925: W C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\framework\op_kernel.cc:1192] Not found: Key dnn/hiddenlayer_1/biases/denlayer_1/biases/part_0/Adagrad not found in checkpoint<br>
2017-09-07 20:00:50.454670: W C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\framework\op_kernel.cc:1192] Not found: Key dnn/logits/weights/nn/logits/weights/part_0/Adagrad not found in checkpoint<br>
2017-09-07 20:00:50.455734: W C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\framework\op_kernel.cc:1192] Not found: Key dnn/hiddenlayer_1/weights/enlayer_1/weights/part_0/Adagrad not found in checkpoint<br>
2017-09-07 20:00:50.455777: W C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\framework\op_kernel.cc:1192] Not found: Key dnn/hiddenlayer_1/weights not found in checkpoint<br>
2017-09-07 20:00:50.460821: W C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\framework\op_kernel.cc:1192] Not found: Key dnn/hiddenlayer_2/biases not found in checkpoint<br>
2017-09-07 20:00:50.463001: W C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\framework\op_kernel.cc:1192] Not found: Key dnn/logits/weights not found in checkpoint<br>
2017-09-07 20:00:50.464352: W C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\framework\op_kernel.cc:1192] Not found: Key dnn/hiddenlayer_2/biases/denlayer_2/biases/part_0/Adagrad not found in checkpoint<br>
2017-09-07 20:00:50.464794: W C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\framework\op_kernel.cc:1192] Not found: Key dnn/hiddenlayer_2/weights not found in checkpoint<br>
2017-09-07 20:00:50.467010: W C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\framework\op_kernel.cc:1192] Not found: Key dnn/hiddenlayer_2/weights/enlayer_2/weights/part_0/Adagrad not found in checkpoint<br>
2017-09-07 20:00:50.467803: W C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\framework\op_kernel.cc:1192] Not found: Key dnn/logits/biases/dnn/logits/biases/part_0/Adagrad not found in checkpoint<br>
2017-09-07 20:00:50.472935: W C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\framework\op_kernel.cc:1192] Not found: Key dnn/logits/biases not found in checkpoint<br>
Traceback (most recent call last):<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\client\session.py", line 1327, in _do_call<br>
return fn(*args)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\client\session.py", line 1306, in _run_fn<br>
status, run_metadata)<br>
File "C:\Program Files\Python36\lib\contextlib.py", line 88, in <strong>exit</strong><br>
next(self.gen)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\framework\errors_impl.py", line 466, in raise_exception_on_not_ok_status<br>
pywrap_tensorflow.TF_GetCode(status))<br>
tensorflow.python.framework.errors_impl.NotFoundError: Key dnn/hiddenlayer_0/biases not found in checkpoint<br>
[[Node: save/RestoreV2 = RestoreV2[dtypes=[DT_FLOAT], _device="/job:localhost/replica:0/task:0/cpu:0"](_arg_save/Const_0_0, save/RestoreV2/tensor_names, save/RestoreV2/shape_and_slices)]]</p>
<p dir="auto">During handling of the above exception, another exception occurred:</p>
<p dir="auto">Traceback (most recent call last):<br>
File ".\logging_monitoring.py", line 47, in <br>
tf.app.run()<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\platform\app.py", line 48, in run<br>
_sys.exit(main(_sys.argv[:1] + flags_passthrough))<br>
File ".\logging_monitoring.py", line 33, in main<br>
steps=2000)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\util\deprecation.py", line 296, in new_func<br>
return func(*args, **kwargs)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\contrib\learn\python\learn\estimators\estimator.py", line 442, in fit<br>
SKCompat(self).fit(x, y, batch_size, steps, max_steps, monitors)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\contrib\learn\python\learn\estimators\estimator.py", line 1353, in fit<br>
monitors=all_monitors)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\util\deprecation.py", line 296, in new_func<br>
return func(*args, **kwargs)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\contrib\learn\python\learn\estimators\estimator.py", line 458, in fit<br>
loss = self._train_model(input_fn=input_fn, hooks=hooks)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\contrib\learn\python\learn\estimators\estimator.py", line 1006, in _train_model<br>
config=self._session_config<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 365, in MonitoredTrainingSession<br>
stop_grace_period_secs=stop_grace_period_secs)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 668, in <strong>init</strong><br>
stop_grace_period_secs=stop_grace_period_secs)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 490, in <strong>init</strong><br>
self._sess = _RecoverableSession(self._coordinated_creator)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 842, in <strong>init</strong><br>
_WrappedSession.<strong>init</strong>(self, self._create_session())<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 847, in _create_session<br>
return self._sess_creator.create_session()<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 551, in create_session<br>
self.tf_sess = self._session_creator.create_session()<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 425, in create_session<br>
init_fn=self._scaffold.init_fn)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\session_manager.py", line 273, in prepare_session<br>
config=config)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\session_manager.py", line 205, in _restore_checkpoint<br>
saver.restore(sess, ckpt.model_checkpoint_path)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\saver.py", line 1560, in restore<br>
{self.saver_def.filename_tensor_name: save_path})<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\client\session.py", line 895, in run<br>
run_metadata_ptr)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\client\session.py", line 1124, in _run<br>
feed_dict_tensor, options, run_metadata)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\client\session.py", line 1321, in _do_run<br>
options, run_metadata)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\client\session.py", line 1340, in _do_call<br>
raise type(e)(node_def, op, message)<br>
tensorflow.python.framework.errors_impl.NotFoundError: Key dnn/hiddenlayer_0/biases not found in checkpoint<br>
[[Node: save/RestoreV2 = RestoreV2[dtypes=[DT_FLOAT], _device="/job:localhost/replica:0/task:0/cpu:0"](_arg_save/Const_0_0, save/RestoreV2/tensor_names, save/RestoreV2/shape_and_slices)]]</p>
<p dir="auto">Caused by op 'save/RestoreV2', defined at:<br>
File ".\logging_monitoring.py", line 47, in <br>
tf.app.run()<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\platform\app.py", line 48, in run<br>
_sys.exit(main(_sys.argv[:1] + flags_passthrough))<br>
File ".\logging_monitoring.py", line 33, in main<br>
steps=2000)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\util\deprecation.py", line 296, in new_func<br>
return func(*args, **kwargs)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\contrib\learn\python\learn\estimators\estimator.py", line 442, in fit<br>
SKCompat(self).fit(x, y, batch_size, steps, max_steps, monitors)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\contrib\learn\python\learn\estimators\estimator.py", line 1353, in fit<br>
monitors=all_monitors)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\util\deprecation.py", line 296, in new_func<br>
return func(*args, **kwargs)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\contrib\learn\python\learn\estimators\estimator.py", line 458, in fit<br>
loss = self._train_model(input_fn=input_fn, hooks=hooks)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\contrib\learn\python\learn\estimators\estimator.py", line 1006, in _train_model<br>
config=self._session_config<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 365, in MonitoredTrainingSession<br>
stop_grace_period_secs=stop_grace_period_secs)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 668, in <strong>init</strong><br>
stop_grace_period_secs=stop_grace_period_secs)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 490, in <strong>init</strong><br>
self._sess = _RecoverableSession(self._coordinated_creator)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 842, in <strong>init</strong><br>
_WrappedSession.<strong>init</strong>(self, self._create_session())<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 847, in _create_session<br>
return self._sess_creator.create_session()<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 551, in create_session<br>
self.tf_sess = self._session_creator.create_session()<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 416, in create_session<br>
self._scaffold.finalize()<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 209, in finalize<br>
self._saver.build()<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\saver.py", line 1172, in build<br>
filename=self._filename)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\saver.py", line 684, in build<br>
restore_sequentially, reshape)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\saver.py", line 450, in _AddShardedRestoreOps<br>
name="restore_shard"))<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\saver.py", line 407, in _AddRestoreOps<br>
tensors = self.restore_op(filename_tensor, saveable, preferred_shard)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\saver.py", line 247, in restore_op<br>
[spec.tensor.dtype])[0])<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\ops\gen_io_ops.py", line 663, in restore_v2<br>
dtypes=dtypes, name=name)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\framework\op_def_library.py", line 767, in apply_op<br>
op_def=op_def)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\framework\ops.py", line 2630, in create_op<br>
original_op=self._default_original_op, op_def=op_def)<br>
File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\framework\ops.py", line 1204, in <strong>init</strong><br>
self._traceback = self._graph._extract_stack()  # pylint: disable=protected-access</p>
<p dir="auto">NotFoundError (see above for traceback): Key dnn/hiddenlayer_0/biases not found in checkpoint<br>
[[Node: save/RestoreV2 = RestoreV2[dtypes=[DT_FLOAT], _device="/job:localhost/replica:0/task:0/cpu:0"](_arg_save/Const_0_0, save/RestoreV2/tensor_names, save/RestoreV2/shape_and_slices)]]</p>
<p dir="auto">ERROR:tensorflow:==================================<br>
Object was never used (type &lt;class 'tensorflow.python.framework.ops.Tensor'&gt;):<br>
&lt;tf.Tensor 'report_uninitialized_variables_1/boolean_mask/Gather:0' shape=(?,) dtype=string&gt;<br>
If you want to mark it as used call its "mark_used()" method.<br>
It was originally created here:<br>
['File ".\logging_monitoring.py", line 47, in \n    tf.app.run()', 'File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\platform\app.py", line 48, in run\n    _sys.exit(main(_sys.argv[:1] + flags_passthrough))', 'File ".\logging_monitoring.py", line 33, in main\n    steps=2000)', 'File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\util\deprecation.py", line 296, in new_func\n    return func(*args, **kwargs)', 'File "C:\Program Files\Python36\lib\site-packages\tensorflow\contrib\learn\python\learn\estimators\estimator.py", line 442, in fit\n    SKCompat(self).fit(x, y, batch_size, steps, max_steps, monitors)', 'File "C:\Program Files\Python36\lib\site-packages\tensorflow\contrib\learn\python\learn\estimators\estimator.py", line 1353, in fit\n    monitors=all_monitors)', 'File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\util\deprecation.py", line 296, in new_func\n    return func(*args, **kwargs)', 'File "C:\Program Files\Python36\lib\site-packages\tensorflow\contrib\learn\python\learn\estimators\estimator.py", line 458, in fit\n    loss = self._train_model(input_fn=input_fn, hooks=hooks)', 'File "C:\Program Files\Python36\lib\site-packages\tensorflow\contrib\learn\python\learn\estimators\estimator.py", line 1006, in _train_model\n    config=self._session_config', 'File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 365, in MonitoredTrainingSession\n    stop_grace_period_secs=stop_grace_period_secs)', 'File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 668, in <strong>init</strong>\n    stop_grace_period_secs=stop_grace_period_secs)', 'File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 490, in <strong>init</strong>\n    self._sess = _RecoverableSession(self._coordinated_creator)', 'File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 842, in <strong>init</strong>\n    _WrappedSession.<strong>init</strong>(self, self._create_session())', 'File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 847, in _create_session\n    return self._sess_creator.create_session()', 'File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 551, in create_session\n    self.tf_sess = self._session_creator.create_session()', 'File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 416, in create_session\n    self._scaffold.finalize()', 'File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 196, in finalize\n    default_ready_for_local_init_op)', 'File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 258, in get_or_default\n    op = default_constructor()', 'File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\training\monitored_session.py", line 193, in default_ready_for_local_init_op\n    variables.global_variables())', 'File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\util\tf_should_use.py", line 175, in wrapped\n    return _add_should_use_warning(fn(*args, **kwargs))', 'File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\util\tf_should_use.py", line 144, in _add_should_use_warning\n    wrapped = TFShouldUseWarningWrapper(x)', 'File "C:\Program Files\Python36\lib\site-packages\tensorflow\python\util\tf_should_use.py", line 101, in <strong>init</strong>\n    stack = [s.strip() for s in traceback.format_stack()]']</p>
<p dir="auto">This is a duplicate request from pytorch issue, which I even reuse their issue title<br>
<a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="275285052" data-permission-text="Title is private" data-url="https://github.com/pytorch/pytorch/issues/3790" data-hovercard-type="issue" data-hovercard-url="/pytorch/pytorch/issues/3790/hovercard" href="https://github.com/pytorch/pytorch/issues/3790">pytorch/pytorch#3790</a></p>
<p dir="auto">And the fix from the paper seems to be trivial but I'm not sure how TF should approach this, perhaps just adding another parameter?</p>