title: How to convert a picture into a MNIST like Dataarray
body: <p>I am writing a neural network, which is able to determine numbers from the MNIST databank. I made a GUI with tkinter where I can draw numbers. I managed to read those in with some Stackoverflow-code. But the problem is, that my neural network is just taking an array with 784 values(I am resizing the picture with pillow 28x28), like the pictures in the databank are saved, but I get 2352 values(I am guessing it is taking every r.g.b value and saves it. I just need to combine these 3 values in one value, so how do I do that?</p>
  <p>The array of one picture:</p>
  <pre><code>  [[[253 253 253]
    [254 254 254]
    [254 254 254]
    ...
    [254 254 254]
    [254 254 254]
    [253 253 253]]]
  </code></pre>
  <p>The array I need(I know i can arrange this with .tolist() but I need 784 values first):</p>
  <pre><code>0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.......121,254,207,18,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
  </code></pre>
  <p>Btw: I know that I have to invert the numbers later on, but I am currently struggling with the rgb values.</p>