output = StringIO.StringIO()
im = Image.open('/home/cwgem/Pictures/portrait.png')
im.save(output, format=im.format)
r = redis.StrictRedis(host='localhost')
r.set('imagedata', output.getvalue())
output.close()
how to store an image into redis using python / PIL