Unable to visualize graph in tensorboard
<p>While writing the summary, </p>

<pre><code>summary_writer1 = tf.train.SummaryWriter(logs_path, graph=tf.get_default_graph())
</code></pre>

<p>works fine and produces graph on tensorboard but doing </p>

<pre><code>summary_writer2 = tf.train.SummaryWriter(logs_path, sess.graph())
</code></pre>

<p>produces the following error while running the code to train the model, </p>

<pre><code>Traceback (most recent call last):
  File "MultiLayerPerceptron.py", line 121, in &lt;module&gt;
    summary_writer2 = tf.train.SummaryWriter(logs_path, graph=sess.graph())
TypeError: 'Graph' object is not callable
</code></pre>

<p>also what's the difference between the default graph as in <code>summary_writer1</code> and graph in <code>summar_writer2</code></p>