title: Matrix norm in TensorFlow
body: <p>I need to compute the Frobenius norm in order to achieve this formula using the TensorFlow framework:</p>
  
  <p><a href="https://i.stack.imgur.com/fgJ7o.gif" rel="noreferrer"><img src="https://i.stack.imgur.com/fgJ7o.gif" alt="Formula"></a></p>
  
  <p>where <code>w</code> is a matrix with 50 rows and 100 columns.</p>
  
  <p>I tried to write something, but I don't understand how to fill out the <code>axis</code> argument.</p>
  
  <pre><code>tf.pow(
      tf.norm(x, ord='fro', axis=?), 2
  )
  </code></pre>
  
  <p>According to the <a href="https://www.tensorflow.org/api_docs/python/tf/norm" rel="noreferrer">TensorFlow docs</a> I have to use a 2-tuple (or a 2-list) because it <em>determines the axies in tensor over which to compute a matrix norm</em>, but I simply need a plain Frobenius norm. In <code>SciPy</code>, for example, I can do it without specify any axis.</p>
  
  <p>So, what should I use as <code>axis</code> to emulate the <code>SciPy</code> function?</p>