You could try to specify the desired image format in imsave, but would need to make sure that PIL is not transforming the array under the hood and could thus quantize the data (if I’m not mistaken you don’t want that).



 Istvan_Ferenc_Toth:

Is there any way to save as an image a float valued numpy array ?


You could store the numpy array directly, in case you want to save the exact values. I don’t know if this would fit your use case and what kind of image format your current data would represent.