精慕门3471333
2018-11-09 02:16
Traceback (most recent call last):
File "D:/user/pycharm/mnist_test/mnist/convolutional.py", line 27, in <module>
train_accuracy = accuracy.eval(feed_dict={x: batch[0], y: batch[1], keep_prob: 1.0})
File "D:\program files\Anaconda\envs\tensorflow\lib\site-packages\tensorflow\python\framework\ops.py", line 680, in eval
return _eval_using_default_session(self, feed_dict, self.graph, session)
File "D:\program files\Anaconda\envs\tensorflow\lib\site-packages\tensorflow\python\framework\ops.py", line 4937, in _eval_using_default_session
raise ValueError("Cannot evaluate tensor using `eval()`: No default "
ValueError: Cannot evaluate tensor using `eval()`: No default session is registered. Use `with sess.as_default()` or pass an explicit session to `eval(session=sess)`
Process finished with exit code 1
train_accuracy = accuracy.eval(feed_dict={x: batch[0], y_: batch[1], keep_prob: 1.0})
TensorFlow与Flask结合打造手写体数字识别
20428 学习 · 102 问题
相似问题