From be7b7ec2a3caee3e0e86f4829f779813f77e9e08 Mon Sep 17 00:00:00 2001 From: Ananthakrishnan P Date: Fri, 24 Nov 2017 15:23:23 -0800 Subject: [PATCH] Fixed summary throwing error --- tensor_flow_tutorial.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tensor_flow_tutorial.py b/tensor_flow_tutorial.py index 449ede5..dc280af 100644 --- a/tensor_flow_tutorial.py +++ b/tensor_flow_tutorial.py @@ -124,9 +124,9 @@ def nn_example(): accuracy = tf.reduce_mean(tf.cast(correct_prediction, tf.float32)) # add a summary to store the accuracy - tf.summary.scalar('accuracy', accuracy) + accuracy_summary = tf.summary.scalar('accuracy', accuracy) - merged = tf.summary.merge_all() + merged = tf.summary.merge(accuracy_summary) writer = tf.summary.FileWriter('C:\\Users\\Andy\\PycharmProjects') # start the session with tf.Session() as sess: @@ -151,4 +151,4 @@ def nn_example(): # run_simple_graph() # run_simple_graph_multiple() # simple_with_tensor_board() - nn_example() \ No newline at end of file + nn_example()