What form is your "image" in to begin with? Is it a color (3-D) image? A hyperpspectral image stack? A 3-D volumetric image? If it's not already a 2-D array, meaning a gray scale image, then what is it?
For saving images on disk, I prefer PNG format. It seems like it has become the defactor standard, except in the medical community where dicom seems like the most common. Definitely don't use JPG if you're going to do image analysis on the images.
