title: Convert PIL Image to byte array?
body: <p>I have an image in PIL Image format. I need to convert it to byte array.</p>
  
  <pre><code>img = Image.open(fh, mode='r')  
  roiImg = img.crop(box)
  </code></pre>
  
  <p>Now I need the <code>roiImg</code> as a byte array.</p>