3. Image Processing

The portal images suffer from poor contrast, primarily due to the much higher energies of the photons in comparison to standard X-rays. This makes the identification of suitable anatomical points in the images for use in registration a difficult and often impossible process. Therefore before the selection of fiducial points takes place, processing the portal image to improve the contrast is necessary.

3.1 Histogram Equalization

The commonest form of contrast enhancement is a 1-to-1 pixel transformation where the output image is formed by using a lookup table to convert the brightness of the pixel in the input image to a new brightness value in the output image.

The most frequently used technique of this type is known as histogram equalization, and is based on the assumption that a good grey-level assignment scheme should have equally distributed brightness levels over the whole brightness scale. Individual pixels retain their brightness order (i.e. they remain brighter or darker than other pixels). However, the values are shifted so that they are equally distributed over the brightness scale. The result of the brightness transformation should be that the cumulative histogram becomes a straight line.

As a digital image has only a finite number of grey scales, an ideal equalization is not possible. This causes some pixels with initially different brightness values to be assigned the same value, and other values to be missing altogether. The result of a histogram equalization on a typical portal radiograph can be seen in figure 3.

(a) detail from original image (b) detail after histogram equalization
(c) histogram of original image (d) histogram after equalization

Figure 3: The effect of a histogram equalization

Formalizing this, if we have a pixel of brightness pb in the original image from a range [p0,pk], then if tb is the number of pixels in the image at a brightness level b or less, defined as

  tb = b

i = 0
pi (14)

then if there are a total of n pixels in the image, the new brightness value q is defined to be

q = tb(k-1)

The histogram equalization enhances the contrast for brightness values close to maxima in the histogram and decreases contrast near the minima. That is, it improves the contrast in the image in areas of poor contrast at the expense of those areas where there is already good contrast.

A limitation of histogram equalization is that large peaks in the histogram can also be caused by large areas of similar brightness. Frequently these correspond to areas of background, and are essentially uninteresting. The effect of histogram equalization on these areas is to enhance the visibility of noise.

A simple method by which this can be overcome for either background or foreground areas is to display the histogram and allow the user to select a cutoff value. All pixels in the input image of the same or lower brightness are mapped to the minimum brightness level, and remaining brightness levels are equalized. Similarly a cutoff value can be defined for foreground areas, where all pixels equal or above a selected brightness are mapped to the maximum brightness level.

Another limitation of the technique is that it does not adapt to local contrast requirements; minor contrast differences can be missed entirely when the number of pixels falling in a particular brightness range is small. This weakness can be overcome by using an adaptive histogram equalization technique, which optimizes image contrast locally (Pizer, Amburn, Austin, Cromartie, Geselowitz, ter Haar Romeny, Zimmerman & Zuiderveld 1987). In particular a technique known as contrast limited adaptive histogram equalization (CLAHE), which seeks to reduce the noise produced in homogeneous areas by basic adaptive histogram equalization, and was originally developed for medical imaging, has been successful for the enhancement of portal images (Rosenman, Roe, Cromartie, Muller & Pizer 1993).

3.2 Colour Schemes

A further method to improve the contrast perceived by the operator is to optimize the representation of the brightness levels to maximize the contrast.

The representation of brightness by grey shades such that as the brightness increases it moves from black through grey to white are by far the most common. Unfortunately, all the shades used in this scheme are different saturations of the same hue (i.e. grey). This presents a problem as only a limited number of grey levels are perceivable as different to the human eye.

To maximize the ability to distinguish between adjacent levels of brightness, changing both the hue and the saturation is necessary. Two colour schemes that use the extended range offered by using colour coding while retaining the ability for the observer to see adjacent brightness levels as possibly relating to the same image feature, are the Blue/White and Hot Body.

In the blue/white scheme, the coding of the brightness levels moves from black through shades of blue ending in white. The hot body scheme varies from black through shades of red, orange, yellow, ending in white and is designed to follow the emission spectra of a black body as it is heated up. Both these schemes offer improvements in the perception of contrast changes and hence localization. It has to be born in mind however that there is often resistance among medical personnel to view images in anything other than grey scale.