MNIST handwritten character recognition with two layers of NN
Here's the code: gist
If you run summary_op in the 12th Cell if, the error will fail.
Is the shape of x(name=input_x) strange?That seems to be the case, but it can't be so, so I'm worried.
In addition, when you restart and run the kernel, the first run works without causing any errors, but the second run always fails there.
As for the environment, tensorflow 1.12.0, python 3.6.8, ipython 7.3.0, conda 4.5.12.
There was a question that seemed to be a similar error, but it didn't seem to be resolved, so I asked you a question.
python tensorflow
I don't know tf.summary at all, but if you run the cells that make the calculation graph more than once,
tf.summary.scalar("loss", loss)
Several similar graphs have been created, and all of them have been put together
summary_op=tf.summary.merge_all()
So I think you are confused.If you reset the graph before you start creating the calculation graph, you can run this cell more than once.
tf.reset_default_graph()
# Number of input layer neurons 28*28=784, variable number of lines
x = tf.placeholder (tf.float32, [None,784], name = "input_x")
914 When building Fast API+Uvicorn environment with PyInstaller, console=False results in an error
617 Uncaught (inpromise) Error on Electron: An object could not be cloned
610 GDB gets version error when attempting to debug with the Presense SDK (IDE)
© 2024 OneMinuteCode. All rights reserved.