title: what does np.eye(n)[nparray] mean?
body: <p>I am going thru some code </p>
  
  <pre><code>y_enc = np.eye(21)[label]
  </code></pre>
  
  <p>where label is ndarray of shape (224, 224)
  y_enc is ndarray of shape (224, 224, 21)</p>
  
  <p>Even with the shapes printed, I am having trouble understanding this statement. np.eye is supposed to generate a diagonal matrix of dimension 21 x 21. what does it mean to have [label] following it?</p>