title: Creating an image from single bits in Python 3
body: <p>I have created an array of bits by using this: </p>
  
  <pre><code>Data = []
  Bytes = numpy.fromfile(filename, dtype = "uint8")
  Bits = numpy.unpackbits(Bytes)
  for b in Bits:
      Data.append(b)
  </code></pre>
  
  <p>"filename" ends with ".png". </p>
  
  <p>Later on, I do some stuff with these bits. I want to save an image with another(or the same) set of bits. How do I do it? The best option would be using: <code>saveToPNG(Data)</code></p>