title graphicAIF graphic

 

Instructions for dealing with 12 bit cooled CCD images in Adobe Photoshop 3.0 8 bit grayscale space.

When you open your images in Photoshop, they appear black. Why?

Your images are 12 bits. This means that each pixel may have a value between 0 and 4095. But Photoshop considers these images 16 bits where each pixel may have a value from 0 to 65535. Photoshop automatically scales the image to show 0 as black and 65535 as white. Your images look black because even if your images have pixels that saturate at 4095, this is still displayed as only 6% of white. Your images looked ok in I.P. Lab Spectrum because I.P. Lab automatically scales the brightest pixel in your image to white and the darkest to black. [This does, however, pose the problem of not showing you relative intensities from one image to the next; you may fix this in I.P. Lab Spectrum with the Enhance-->Normalize command.]

So how do we solve the problem?

  1. Open your image. Get initial settings with your brightest image. To preserve relative intensities, the exact same operations with the exact same numbers must be applied to each image.
    1. On a Macintosh, this may involve opening the File-->Open window and clicking on "Show all files" and choosing the format "Tiff" or "Raw".
    2. On a PC, this may involve using the File-->OpenAs command and choosing the format "Tiff" or "Raw". [A good trick if you're using a PC is to go into the MS Dos command window and rename all your files by typing "ren * *.tif" or "ren * *.raw" depending on the file type. Subsequent to this batch renaming, Photoshop will recognize the file type with the plain vanilla Open command.]
  2. A simple method for adjusting grayscale linearly:
    1. Image-->Adjust-->Levels.
    2. The Input Levels box should show 0 1.00 255. Change the 255 to 16 to make 4095 white. Change the 255 to TRUNC((max_pixel_value + 1) / 256) to make the maximum pixel value in your image white without saturating any pixels. This is useful for adjusting all your images exactly the same based on a brightest image. [You may use the Save and Load buttons instead of typing in the number each time; in Photoshop 4 or 5 this entire sequence may be saved as an action.]
    3. Fine tune with a second application of Image-->Adjust-->Levels. This time, you will drop out the background or pedestal values inherent in the electronics of the camera. When you drag the cursor over the background of your image (for instance, a blank part of coverslip in fluorescence in a cell culture) you will see pixel values of, for example, 13 to 15 in the Info window. Set the numbers in the Input Levels to 15 1.00 255.
    4. Change the mode from Grayscale 16 bit to Grayscale 8 bit.
    5. File-->SaveAs to save the image with a new file name. DO NOT WRITE OVER THE RAW DATA. Deconvolution or intensity quantitation will work only on the raw data, not the adjusted images.

If you need to preserve relative intensity values, use the same numbers for each image.   In general, find numbers that are good for the brightest image and use the numbers for all images.

After you make a complete figure, you may make minor adjustments to the contrast of the entire figure, so that all adjustments in all pictures are the same.


USING NIH-IMAGE
(effective January 2003 the AIF switched to ImageJ software and no longer supports NIH-Image)

The following macro from the "Input Output Macros" provided with NIH-Image will open I.P. Lab format files. Each file is scaled to 8 bits. Because each image is scaled automatically, this macro does not work if you need relative intensities from image to image to be preserved. If you need to retain relative intensities, manually use the File --> Import command and set the scale or change the Autoscale command in the macro.

macro 'Import IPLab File';
var
   width,height,offset:integer;
begin
   width:=100; 
   height:=1;
   offset:=0;
   SetImport('8-bit'); 
   SetCustom(width,height,offset);
   Import(''); {Read in header as an image, prompting for file name.}
   width := (GetPixel(8,0)*256) + GetPixel(9,0);
   height := (GetPixel(12,0)*256) + GetPixel(13,0);
   Dispose;  
   offset:=2120;  {The IPLab offset}
   SetImport('16-bit Signed; Calibrate; Autoscale');
   SetCustom(width,height,offset);
   Import('');  {No prompt this time; Import remembers the name.}
end;

Please send us suggestions for changes to this page.