Hubble Image Processing Tutorial
Warped Spiral Galaxy ESO 510-G13

Galaxy ESO 510-G13

Create this image from Hubble Legacy Archive data

Overview:

Image data from the Hubble Space Telescope is available through the Hubble Legacy Archive. Hubble images are taken in grayscale for maximum resolution. For scientific purposes, multiple images of an astronomical object are taken through different color filters. Each filter produces a subtle difference in brightness. These differences can be used to create color images. This example uses Photoshop layers to colorize and combine 3 grayscale images taken with 3 different color filters to produce a full color image. The colors in this image are enhanced but represent real physical processes. The white halo is a mix of the colors from many stars. The red band is interstellar dust passing red light and scattering blue light.

Technical Background:

Files in the Hubble Legacy Archive are in FITS format, a standard format used to store astronomical data. FITS files can be converted to a more common TIFF format using the FIT Liberator application. Once in TIFF format, a file can be opened in Photoshop. Both the FITS and TIFF image formats avoid the detail loss common with jpg and gif image formats. The basic steps are:

  1. Download FITS image files from the Hubble Legacy Archive

  2. Use FITS Liberator to convert the FITS image files to TIFF

  3. Use Photoshop to combine the TIFF files, colorize, adjust and repair any instrument artifacts

Required Software:

  1. FITS Liberator

  2. Photoshop


Step 1 - Download Hubble Legacy Archive FITS files

The Hubble Legacy Archive can be searched by Astronomical object name. Grayscale images can be viewed as thumbnails.

  1. Go to the Hubble Legacy Archive

  2. Enter ESO 510-G13 in the text box and Search

  3. On the Show Dropdown select 50 results per page

  4. Click on the Images tab near the top of the table

  5. Select 3 images each taken with a filter near a wavelength of one the primary colors. The number in the filename (f450, f555, f675) is the wavelength in nanometers (nm) of the filter used for the image. Although not available for all objects, 3 images for this object are:

    1. hst_08888_01_wfpc2_f450w_wf (blue filter)
    2. hst_08888_03_wfpc2_f555w_wf (yellow-green filter)
    3. hst_08888_05_wfpc2_f675w_wf (red filter)

  6. Visible Spectrum Wavelengths
    Image from: chemistry.tutorcircle.com
  7. For each of the 3 images, select the FITS-Science version

  8. At the top of the page select the Cart tab

  9. Download the zip file which contains the 3 FITS files

  10. Open the zip file and extract the 3 FITS files

There are now 3 files each with the .fits extension.


Step 2 - FITS Liberator

In deep sky images there is generally a large range of brightness levels. The key to producing astronomical images is to scale the image from the the wide range of pixel values in the data into the smaller range of values available on a computer screen. This is called stretching. Stretching brings out faint details by compressing the brightness range. The mathematical function ArcSinh in FITS Liberator generally works well for stretching most astronomical images. Additionally, FITS Liberator can scales the values to reduce areas that are underexposed or overexposed.

  1. Open the file hst_08888_01_wfpc2_f450w_wf_sci.fits with FITS Liberator. Press Reset. Press Auto scaling. Set the white level to about 6.4 and the black level to about 1.8. Set the Stretch function to ArcSinh(x). Save the TIFF file.

  2. Open the file hst_08888_03_wfpc2_f555w_wf_sci.fits with FITS Liberator. Press Reset. Press Auto scaling. Set the white level to about 6.6 and the black level to about 1.35. Set the Stretch function to ArcSinh(x). Save the TIFF file.

  3. Open the file hst_08888_05_wfpc2_f675w_wf_sci.fits with FITS Liberator. Press reset. Press Auto scaling. Set the white level to about 6.6 and the black level to about 1.35. Set the Stretch function to ArcSinh(x). Save the TIFF file.

There are now 3 files each with the .tif extension. Each TIFF image will look similar to the image below:


Step 3 - Photoshop

Creating the final image requires colorizing, leveling, cropping, rotating and removing instrument artifacts. Each of the 3 images will be copied to a Photoshop layer. Each layer will be colorized and adjusted separately. Adjustments can be applied to the image as a whole but it is easiest if the adjustments are applied to a specific layer. This allows finer control and subsequent modifications.

Process the Blue file:

  1. Load file: Open hst_08888_01_wfpc2_f450w_wf_sci.tif in Photoshop

  2. Maximize Window View: View | Fit on Screen

  3. Set Mode: Image | Mode | RGB Color

  4. Rename Tab: File | Save As | filename=ESO 510-G13.tif | Save | None (in the TIFF options dialog box) | OK

  5. Open Layers Dialog: Windows | Layers

  6. Rename Layer: In the Layers dialog, Double click on Background layer | Name: 450 | OK

  7. Add Levels: Layer | New Adjustment Layer | Levels | Use Previous Layer to Create Clipping Mask | OK. Set Black slider to 31

  8. Add Color: Layer | New Adjustment Layer | Hue/Saturation | Use Previous Layer to Create Clipping Mask | OK. Click colorize | Hue=213, Saturation=100, Lightness=-50

The Photoshop screen will look something like this:


Process the Green file:

  1. Load file: Open hst_08888_01_wfpc2_f555w_wf_sci.tif in Photoshop

  2. Combine Layers: Select | All, Edit | Copy, Click the ESO 510-G13.tif tab, Edit | Paste.
    There is now a second layer called Layer 1.

  3. Rename Layer: Double click on Layer 1, Edit layer name 555

  4. Add Levels: With Layer 555 selected, Layer | New Adjustment Layer | Levels | Use Previous Layer to Create Clipping Mask | OK. Set Black slider to 38

  5. Add Color: Layer | New Adjustment Layer | Hue/Saturation | Use Previous Layer to Create Clipping Mask | OK. Double click colorize | Hue=138, Saturation=100, Lightness=-50

  6. Blend Mode: Select the 555 layer. Set the Blend Mode dropdown from Normal to Screen

  7. Align Layers: View | Zoom In (a few times), Select the 555 layer, Select the Move Tool. Look at an area of the image where there are just stars. If the two layers are not aligned, use the arrow keys to move the green layer so it exactly overlays the blue layer.

  8. Close the 555 tab: Click the x on the hst_08888_01_wfpc2_f555w_wf.tif tab, this tab will not be needed

The Photoshop screen will now look something like this:

Process the Red file:

  1. Load file: Open hst_08888_01_wfpc2_f675w_wf_sci.tif in Photoshop

  2. Combine Layers: Select | All, Edit | Copy, Click ESO 510-G13.tif tab, Edit | Paste. There is now a third layer called Layer 1.

  3. Rename Layer: Double click on layer 1, Edit layer name 675

  4. Add Levels: With Layer 675 selected, New Adjustment Layer | Levels | Use Previous Layer to Create Clipping Mask | OK. Set Black slider to 38

  5. Add Color: Layer | New Adjustment Layer | Hue/Saturation | Use Previous Layer to Create Clipping Mask | OK. Double click colorize | Hue=0, Saturation=100, Lightness=-50

  6. Blend Mode: Select the 675 layer. Set the Blend Mode dropdown from Normal to Screen

  7. Align Layer: View | Zoom In (a few times), Select the 675 layer, Select Move Tool. Look at an area of the image where there are just stars. If the two layers are not aligned, use the arrow keys to move the red layer so it exactly overlays the blue layer.

  8. Close the 675 tab: Click the x on the hst_08888_01_wfpc2_f675w_wf.tif tab, this tab will not be needed

The Photoshop screen will now look something like this:



Rotate the image to prepare for cropping and to increase visual appeal:

  1. Transform: Select | All, Image | Image Rotation | Arbitrary, Click Clockwise, Angle=35 | OK

  2. Wider View: View | Zoom Out

The Photoshop screen will now look something like this:



Crop the image to remove edge artifacts:

  1. Transform: Select Crop Tool, Size to about 30%. With W X H Resolution, crop to about width 1489 and to about height 742

  2. Accept: Click on Select Tool and accept the cropping

The Photoshop screen will now look something like this:



Create a merged Copy. This step is to retain the ability to change parameters to the individual layers later.

  1. Copy: Select All | Copy Merged

  2. Create New Merged Image: File | New | Name = Merged, Edit | Paste

  3. Delete Background: In the layers dialog, delete the Background Layer

There is now a second tab called Merged.

High Pass Filter:

  1. Duplicate Layer: Layer | Duplicate Layer | Name: High Pass | OK

  2. Blend Mode: Select the High Pass layer. Set the Blend Mode dropdown from Normal to Overlay

  3. Set high pass filter: Filter | Other | High Pass | Set radius to 5

  4. Add Mask Layer: Layer | Layer Mask | Hide All

  5. Brush Tool: Window | Color| Set to White, select Brush tool, single click the Layer Mask rectangle

  6. Paint Highlights: Use the bush tool to "paint" over the dust band, white traces will be start to show in the Layer Mask rectangle, continue until most of the dust lane is covered. You will see the dust band details sharpen as you draw over them. The high pass filter is applied selectively. If applied to the entire image it would cause the image to become pixelated.

The Photoshop screen will now look something like this:



Brighten:

The image still looks a bit dull. Add a brightness layer

  1. Add Brightness Layer: Layer | New Adjustment Layer | Brightness/Contrast | Use Previous Layer to Create Clipping Mask | OK

  2. Adjust Brightness : Set Brightness to +22

Contrast can also be added or removed in this step with the same layer.

Adjust color composite as a whole:

Much of the galaxy appears nearly white since it contains stars of many different colors, which combine to create a white appearance in the final image. As can be seen from the 3 original gray images the galaxy halo is about the same brightness in all 3, thus the halo should be white. The band across the middle can be seen dark on the grayscale blue filter image and brighter in the ed filter image which means the band should be red. To achieve these two goals, set color balance on the image as a whole.

  1. Add Color Balance: Layer | New Adjustment Layer | Color Balance | Use Previous Layer to Create Clipping Mask | OK

  2. Adjust Color: Set Cyan/Red slider to +7, Magenta/Green slide to -6, Yellow/Blue slider to +22

The Windows | Info dialog can be used to see the pixel RGB values.

Remove Artifacts:

The healing tool will be used to remove the vertical seam and the excess flare on the brightest stars.

  1. Heal seam: Select the Healing Tool, 47, Hardness=50%, Normal, Proximity Match. Click multiple times along the seam until it begins to disappear. This step may take some practice.

  2. Remove image blemish: Use the healing tool to remove the blemish above the star near pixel location (529,160)

  3. Remove most of star rays: Use the healing tool to remove the excess star rays

  4. Save as a tif file


There are many other Photoshop options not covered here to experiment with: Curves, Masks, Sharpen/Unsharpen which can be used to enhance the image. If you followed this example it would be interesting to see your results.



Please email me if you see anything that needs correcting.