title: Confirm of using GPU in tensorflow
body: <p>I am to confirm that I am using GPU with tensorflow but I am kinda confused. So, I am using the following code to check if GPU is used:</p>
  
  <pre><code>sess = tf.Session(config=tf.ConfigProto(log_device_placement=True))
  </code></pre>
  
  <p>which outputs the following:</p>
  
  <p><a href="https://i.stack.imgur.com/HG1qd.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/HG1qd.png" alt="enter image description here"></a></p>
  
  <p>From my understanding it seems from the output that GPU is used for calculations. But when I monitor it with:</p>
  
  <pre><code>~$sudo nvidia-smi --loop=1
  </code></pre>
  
  <p>I have the following output, which constantly gives the following result:</p>
  
  <p><a href="https://i.stack.imgur.com/GdDtn.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/GdDtn.png" alt="enter image description here"></a></p>
  
  <p>From my undestanding in the last pic it doesnt use GPU. Is it something that I missunderstound? Any tip?</p>
  
  <p><strong>Edit</strong> (after Yaroslav Bulatov comment, which helped a lot)</p>
  
  <p>I can confirm now that I am using GPU. For a <code>matmul(A,B)</code> I got the following results from the ctf file:</p>
  
  <p><a href="https://i.stack.imgur.com/tZtLW.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/tZtLW.png" alt="enter image description here"></a></p>
  
  <p>However there are some functions from tensorflow that seems they are using CPU. For example <code>tf.nn.top_k</code>:
  <a href="https://i.stack.imgur.com/Gb5OS.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Gb5OS.png" alt="enter image description here"></a></p>
  
  <p>Interesting..</p>