title: Python numpy fill 3d array
body: <p>I have raw data and that has been converted to RGB values. Those values are in a list like [R, G, B]. So essentially I have [[R,G,B],...,[R,G,B]]. Now I want to make a matrix by width*height*3.</p>
  
  <pre><code>rgb_list = []
  
  for i in range(0, channel_bytes):
      r = channel_1.__getitem__(i)
      g = channel_2.__getitem__(i)
      b = channel_3.__getitem__(i)
      rgb_list.append([r, g, b])
  
  image_matrix = np.array(rgb_list)
  image_matrix.reshape(image_height, image_width, 3)
  print(image_matrix)
  </code></pre>
  
  <p>Still gives me the following output:</p>
  
  <pre><code>[[22 21 13]
   [30 23 23]
   [19 23 16]
   ..., 
   [17 17 18]
   [18 17 10]
   [16 17 18]]
  </code></pre>
  
  <p>But it should be </p>
  
  <pre><code>[[[22, 21, 13]],
   [[30, 23, 23]],
   ...,
  [[16, 17, 18]]]
  </code></pre>