image enhancement

38
IMAGE ENHANCEMENT

Upload: rajendra-prasad

Post on 15-Aug-2015

23 views

Category:

Design


0 download

TRANSCRIPT

IMAGE ENHANCEMENT

Image Enhancement - Objectives To process an image so that the result is more suitable than the

original image for a specific application.

Accentuation or sharpening of image features such as edges, boundaries, or contrast to make an image more useful for display and analysis.

When images are processed to improve their appearance to human viewers, the objective may be to improve perceptual aspects, such as image quality, intelligibility, or visual appearance. In other applications, such as object identification by a machine, an image may be preprocessed to aid machine performance.

Types Of Processing The processing techniques are very much problem

oriented. Means an image enhancement algorithm that performs well for one class of images may not perform well for other classes.

There are several enhancement techniques available, and we can classify them into two broad categories. Spatial domain methods – Direct manipulations of pixels

in an image. Frequency domain methods – Modifying the fourier

transform of an image.

Spatial domain Methods

The spatial domain refers to the image plane itself, that is the collection of pixels constituting an image.

The spatial domain process can be denoted as

f(x,y) - input image; g(x,y) - processed image; T – operator on f, defined over some neighbourhood of f(x,y)

The neighbourhood about point (x,y) is a square or rectangular sub image area centered at (x,y).

),(),( yxfTyxg

Spatial domain Methods

The simplest form of T is when the neighbourhood is of size 1x1, that is a single pixel.

Then g depends only on the value of f, at (x,y) or the gray level f(x,y), and T becomes a gray level transformation function of the form

s = T(r). s – gray level of g(x,y) r – gray level of f(x,y) at any point (x,y)

This type of processing is known as point processing, because the processing depends only on the gray level at that point.

When T operates on the neighbourhood of f(x,y), the processing is done by the use of masks (say a 3x3 2-D array) and is known as mask processing. The mask coefficients determine the nature of process.

Spatial domain Methods

Basic Gray level Transformations

Three basic types of functions used for gray level transformations in image enhancement are Linear. Logarithmic. Power low.

Linear Transformations

Identity Transformation:

Linear Transformations Cont..

Negative Transformation:

The negative of a digital image with gray levels in the range [0,L-1] is obtained by the transformation function s = T(r) = L-1-r = 255-r, for an 8-bit image

r

s

Digital Negative

Digital negatives are useful in the display of medical images and their

processing

Logarithmic Transformations The general form of a log transformation is given by

s = c log (1+r)

The transformation maps a narrow range of low gray level values in the input image to a wider range of output levels. The higher gray level values are compressed to a narrow range.

Useful for enhancing details in the darker regions of the image at the expense of detail in the brighter regions

If the dynamic range of an image data is very large (eg. Dynamic range of a transformed image), only a few pixels will be visible. The transformation compresses the dynamic range.

Exponential The effect is the reverse of that obtained with logarithmic

mapping.

Exponential Contrast Enhancement - Example

Power Law Transformations

The power law transformations have the basic form given by

Power law curves with fractional values of γ map a narrow range of dark input values into a wider range of output values, with the opposite being true for higher values of input levels.

A family of transformation curves are possible for different values of γ. The curves generated with values of γ>1 have the opposite effect as those generated with values of γ<1.

crs

Power Law Transformation - Application

A variety of devices used for image capture, printing and display respond according to power law.

The exponent in the power law equation is referred to as gamma and the process used to correct this power law response phenomenon is gamma correction.

CRT devices have a intensity to voltage response that is a power function with gamma varying from 1.8 to 2.5.

Gamma correction - Example

Contrast Stretching

Low contrast images can result from poor illumination, lack of dynamic range in the imaging sensor or wrong setting of a lens aperture during image acquisition.

Contrast Stretching Cont..

A typical contrast stretching transformation is given, which can be expressed as

The slope of the transformation is chosen greater than unity in the region of stretch.

The idea is to increase the dynamic range of the gray levels in the image being processed.

255))(()(

)(

0

)(

21112223

211112

11

laaaaal

alaaal

all

lg

αi > 1 - Range Stretchingα i< 1 - Range Compression

Contrast Stretching Cont..

Let T(a1) = s1 and T(a2) = s2

If a1 = s1 and a2 = s2 – linear transformation with no changes in the gray levels.

If a1=a2 and s1 = 0; s2 = L-1 – thresholding function which creates a binary image.

Any intermediate values of (a1,s1) and (a2,s2) produce various degrees of spreads in the gray levels of the output image, which affects its contrast.

Thresholding Function

Thresholding - Example

Gray Level Slicing

Highlighting a specific range of gray levels in an image.

Result of Curve 1

Result of Curve with linear variation from b to L

Result of Curve 2

Result of Curve 3

Result of Curve 4

Thresholding Example

a)Original image; b)Thresholded at 118

Bit Plane Slicing

Highlighting the contributions made to total image appearance by specific bits.

An 8-bit image contains 8 bit planes. We can analyze the relative importance of

each bit plane an image.

Bit Plane Slicing - Example