# Digital Image Enhancement Methods for Multimedia Technology

**Disclaimer:** This work has been submitted by a student. This is not an example of the work written by our professional academic writers. You can view samples of our professional work here.

Any opinions, findings, conclusions or recommendations expressed in this material are those of the authors and do not necessarily reflect the views of UK Essays.

Published: *Wed, 21 Feb 2018*

### Chapter 1

### 1.1 Introduction

In today’s communications networks, multimedia is a growing field. There are increasing demands on incorporating visual aspect to other modes of communications. It is therefore unable to be avoided to have situations in which the video and transmitted images being corrupted or degraded in their perceptual quality by variety of ways.

### 1.2Digital Image Processing

An image is defined as two- dimensional function, f(x,y), where x,y are plane coordinates and the amplitude of ‘f’ at any pair of coordinates (x,y) is called the intensity or gray level of the image. When x, y and the intensity values of f are all finite and discrete quantities, we call the image a digital image. To processing the image by means of computer algorithms is called as digital image processing. As compared to analog image processing, digital image processing has many advantages. It can avoid problems such as signal distortion, image degradation and build-up of noise during processing.

### 1.2 Image Restoration and Enhancement Methods:

Now day’s digital images have covered the complete world. Images are acquired by photo electronic or photochemical methods. The sensing devices tend to reduce a quality of the digital images by introducing the noise and blur due to motion or misfocus of camera.

One of the first applications of digital images was in the news paper industry, when pictures were sent by submarine cable between New York and London. Introduction of cable picture transmission system in the early 1920’s reduced the time required to transport a picture across Atlantic from more than a week to less than three hours.

Some of the initial problems in improving the visual quality of these early digital pictures were related to the selection of printing procedures and distribution of intensity levels.

Digital image processing techniques began in the late 1960s and early 1970s to be used in medical imaging, remote Earth resources observations and astronomy.

Tomography was invented independently by Sir Godfrey N. Hounsfield and Professor Allan M.Cormack who shared the 1979 Nobel Prize in medicine for their invention. But, X-rays were discovered in 1985 by Wilhelm Conrad Roentgen. Geographers use the similar technique to study the pollution patterns from aerial and satellite imagery. Image enhancement and restoration procedures are used to process the degraded images of unrecoverable objects or experimental results too expensive to duplicate. The use of a gray level transformation which transforms a given empirical distribution function of gray level values in an image into a uniform distribution has been used as an image enhancement as well as for a normalization procedure.( I. Pitas)

Image enhancement refers to increase the image quality by sharpening certain image features (edges, boundaries and contrast) and reducing the noise. Digital image enhancement and restoration are two dimensional filters. They are broadly classified into linear digital filters and non linear filters. Linear digital filter can be designed or implemented either spatial domain or Frequency domain. (K.S. Thyagarajan)

In Spatial Domain methods refers to the image plane itself .Image processing methods, spatial domain methods are based on direct manipulation of pixels in an image. The intensity transformations and spatial filtering are two principal categories of spatial domain methods.

In Frequency domain methods, first image is transformed to frequency domain. It means that, the Fourier transform of the image is computed and performed all processing on the Fourier transform of the image. Finally Inverse Fourier transform is performed to get the resultant image. (Rafael C.Gonzalez and Richard E.Woods)

Image Enhancement Techniques are

Median filtering

Neighborhood averaging

Edge Detection

Histogram techniques

In 1980, recent work on c.c.d. scanners is reviewed and solid-state scanners which include on-chip signal processing functions are described. Future trends are towards `smart’ scanners; these are scanners with on-chip real-time processing functions, such as analogue-to-digital conversion, thresholding, data compaction, edge enhancement and other real-time image processing functions.( Chamberlain,1980)

The image enhancement algorithm first separates an image into its lows (low-pass filtered form) and highs (high-pass filtered form) components. The lows component then controls the amplitude of the highs component to increase the local contrast. The lows component is then subjected to a non-linearity to modify the local luminance mean of the image and is combined with the processed highs component. The performance of this algorithm when applied to enhance typical undegraded images, images with large shaded areas, and also images degraded by cloud cover will be illustrated by way of examples. (Peli, T., 1981)

Enhancement algorithms based on local medians and interquartile distances are more effective than those using means and standard deviations for the removal of spike noise, preserve edge sharpness better and introduce fewer artifacts around high contrast edges. They are not as fast as the mean-standard deviation equivalents but are suitable for large data sets treated in small machines in production quantities.( Scollar,I.,1983)

Filtering CT images to remove noise, and thereby enhance the signal-to-noise ratio in the images, is a difficult process because CT noise is of a broad-band spatial-frequency character, overlapping frequencies of interest in the signal.A measurement of the noise power spectrum of a CT scanner and some form of spatially variant filtering of CT images can be beneficial if the filtering process is based upon the differences between the frequency characteristics of the noise and the signal. For evaluating the performance, used a percentage standard deviation, an index representing contrast, a frequency spectral pattern, and several CT images processed with the filter. (Okada., 1985)

A two-dimensional least-mean-square (TDLMS) adaptive algorithm based on the method of steepest decent is proposed and applied to noise reduction in images. The adaptive property of the TDLMS algorithm enables the filter to have an improved tracking performance in nonstationary images. The results presented show that the TDLMS algorithm can be used successfully to reduce noise in images. The algorithm complexity is 2(N×N) multiplications and the same number of additions per image sample, where N is the parameter-matrix dimension. The algorithm can be used in a number of two-dimensional applications such as image enhancement and image data processing.( Hadhoud,M.M.,1988)

Image processing techniques are used to determine the range and alignment of a land vehicle. The approach taken is to establish a state vector of quantities derived from an image sequence, and to refine this over the mission. The image processing techniques applied fall into the generic categories of enhancement, detection, segmentation, and classification. Approaches to estimating the alignment and range of a vehicle in computationally efficient ways are presented. The estimates of quantities extracted from single image frames are subject to errors. This approach facilitates the integration of results from multiple images, and from multiple sensor systems.( Atherton, T.J.,1990)

The JPEG coder has proven to be extremely useful in coding image data. For low bit-rate image coding (0.75 bit or less per pixel), however, the block effect becomes very annoying. The edges also display `wave-like’ appearance. An enhancement algorithm is proposed to enhance the subjective quality of the reconstructed images. First, the pixels of the coded image are classified into three broad categories: (a) pixels belonging to quasi-constant regions where the pixel intensity values vary slowly, (b) pixels belonging to dominant-edge (DE) regions which are characterized by few sharp and dominant edges and (c) pixels belonging to textured regions which are characterized by many small edges and thin-line signals. An adaptive mixture of some well-known spatial filters which uses the pixel labeling information for its adaptation is used as the adaptive optimal spatial filter for image enhancement. (Kundu, A.1995)

The videotexts are low-resolution and mixed with complex backgrounds; image enhancement is a key to successful recognition of the videotexts. Especially in Hangul characters, several consonants cannot be distinguished without sophisticated image enhancement techniques. In this experiment, after multiple videotext frames containing the same captions are detected and the caption area in each frame is extracted, five different image enhancement techniques are serially applied to the image: multi-frame integration, resolution enhancement, contrast enhancement, advanced binarization, and morphological smoothing operations and tested the proposed techniques with the video caption images containing both Hangul and English characters from various video sources such as cinema, news, sports, etc. The character recognition results are greatly improved by using enhanced images in the experiment. (Sangshin Kwak.,2000).

The use of an adaptive image enhancement system that implements the human visual system (HVS) has the properties for contrast enhancement of X-ray images. X-ray images are poor quality and are usually interpreted visually. The HVS properties considered are its adaptive nature, multichannel mechanism and high nonlinearity. This method is adaptive, nonlinear and multichannel, and combines adaptive filters and homomorphic processing.

The median filtering method is a simple and efficient way to remove impulse noise from digital images. This novel method has two stages. The first stage is to detect the impulse noise in the image. In this stage, first one identify the noise pixel and second one the pixels are roughly divided into two classes, which are “noise-free pixel” and “noise pixel”. Then, the second stage is to eliminate the impulse noise from the image. In this stage, only the “noise-pixels” are processed. The “noise -free pixels” are directly copied to the output image. Here, hybrid of adaptive median filter with switching median filter method is used. The adaptive median filter framework in order to enable the flexibility of the filter to change it size accordingly based on the approximation of local noise density. The switching median filter framework in order to speed up the process and also allows local details in the image to be preserved. (Kong, NSP., 2008)

One of the advantages of Level-2 Improved tolerance based selective arithmetic mean filtering technique is that this filtering technique is to detect and remove the noisy pixels and restore the noise free information. However the removal of impulse noise is often accomplished at the expense of blurred and distorted features of edges. Therefore it is necessary to preserve the edges and fine details during filtering. (Deivalakshmi,S., 2010)

An efficient non-linear cascade filter is used to removal of high density salt and pepper noise in image and video. This method consists of two stages to enhance the filtering. The first stage is the Decision based Median Filter (DMF) which is used to identify pixels likely to be contaminated by salt and pepper noise and replaces them by the median value. The second stage is the Unsymmetrical Trimmed Filter, either Mean Filter (UTMF) or Midpoint Filter (UTMP) which is used to trim the noisy pixels in an unsymmetrical manner and processes with the remaining pixels The basic idea is that, though the level of denoising in the first stage is lesser at high noise densities, the second stage helps to increase the noise suppression. Hence, this method is very suitable for low, medium as well as high noise densities even above 90%. This algorithm shows better image and video quality in terms of visual appearance and quantitative measures. ( Balasubramanian, S.,2009)

The enhancement algorithm enhances CR image detail and CR image enhanced has good visual effect, so the method id suit for edge detail enhancement of CR medicine radiation image. (Zhang., 2010).

Three dimensional TV is considered as next generation broadcasting service.TOF sensors are a relatively new technology allowing real time capture of both photometric and geometric scene information. In order to generate the natural 3D video, first we develop a practical pipeline including TOF data processing and MPEG-4 based data transmission and reception. Then we acquire colour and depth videos from TOF range sensor. Then Alpha matting and enhancement are performed to handle fuzzy and hairy objects (Ji-Ho Cho Sung-Yeol Kim Lee, 2010).

### Chapter 2

### 2.1 Median Filtering

Median Filtering is a non -linear signal enhancement technique for the smoothing of signals, the suppression of impulse noise, and preserving of edges. In the one dimensional case it consists of sliding a window of an odd number of elements along the signal, replacing the centre sample by the median of the samples in the window.

Noise is any undesirable signal. Noise is everywhere and thus we have to learn to live with it. Noise gets introduced into data via any electrical system used for storage, transmission, and/or processing. In addition, nature will always play a “noisy” trick or two with data under observation.

When encountering an image corrupted with noise you will want to improve its appearance for a specific application. The Techniques applied are application-oriented. Also, different procedures are related to the types of noise introduced to the image. Some important types of noise are: Gaussian or white, Rayleigh, Salt-pepper or impulse noise, periodic, sinusoidal or coherent, uncorrelated, and granular.

In statistics, a median is described as the numeric value separating the higher half of a sample, a population, or a probability distribution, from the lower half. The median of a finite list of numbers can be found by arranging all the numbers from lowest value to highest value and picking the middle one.

For example:

The observations are [7,5,6,8,1,3,8,5,4].

First, we are arranging in ascending order or lowest value to highest value.

[1, 3, 4, 5, 5, 6, 7, 8, 8]

Then the middle one is picked. Here, number of observations n=9, it is an odd number.

The middle value=5.

So, the median =5.

If there is an even number of observations, then there is no single middle value; the median is then usually defined to be the mean of the two middle values.

For example: observations are [7,5,6,8,1,3,8,5,4,6].

First, we are arranging in ascending order or lowest value to highest value.

[1, 3, 4, 5, 5, 6, 6, 7, 8, 8]

Then the middle one is picked. Here, number of observations n=10, it is an even number.

So, averaging the observation 5 and 6 and gets the median value.

The observation values are 5 and 6.

The averaging value of 5 and 6 gives 5.5.

So, the median =5.5.

Most scanned images contain noise caused by the scanning method (sensor and its calibration-electrical components, radio frequency spikes) this noise may look like dots of black and white.

Median filter helps us by erasing the black dots, called the Pepper, and it also fills in white holes in an image, called salt “Impulse Noise”. It’s like the mean filter but is better in pixels and will not affect the other pixels significantly. This means that mean does that.

Preserving sharp edges

Median value is much like neighbourhood

Median filtering is popular in removing salt and pepper noise and works by replacing the pixel value with the median value in the neighbourhood of that pixel. When applied on:

1. We do brightness -ranking by first placing the brightness values of the pixels from each neighbourhood in ascending order.

2. The median or middle value of this ordered sequence is then selected as the representative brightness value for that neighbourhood.

### 2.2Median Filter Action

The median filter is also sliding -window spatial filter, but it replaces the centre pixel value in the window by the median of all pixel values in the window. As for the mean filter, the kernel is usually square but can be any shape rectangular, circular, etc depends on an image. An example of median filtering of a single 3*3 window of values is shown in figure 2.1.

Unfiltered Values |
||

6 |
2 |
0 |

3 |
97 |
4 |

19 |
3 |
10 |

To arrange the pixel value in ascending order: 0,2,3,3,4,6,19,97

The median value=4(Here no of items=9)

The centre pixel value 97 is replaced by the median value 4 as shown below.

Median filtered Values |
||

* |
* |
* |

* |
4 |
* |

* |
* |
* |

Figure 2.2

This illustrates one of the celebrated features of the median filter: its ability to remove ‘impulse’ noise. The median filter is also widely claimed to be ‘edge-preserving’ since it theoretically preserves step edges without blurring. However, in the presence of noise it blurs edges in images slightly.

### 2.3 Synthetic Image

Let us consider 6*6 window size.

3 |
1 |
5 |
6 |
9 |
2 |

7 |
3 |
8 |
4 |
5 |
1 |

2 |
4 |
3 |
3 |
2 |
8 |

1 |
8 |
9 |
6 |
2 |
7 |

1 |
9 |
2 |
6 |
5 |
8 |

3 |
5 |
7 |
9 |
8 |
2 |

Here, we take 3*3 mask size, to find out the median value.

3 |
1 |
5 |
6 |
9 |
2 |

7 |
3 |
8 |
4 |
5 |
1 |

2 |
4 |
3 |
3 |
2 |
8 |

1 |
8 |
9 |
6 |
2 |
7 |

1 |
9 |
2 |
6 |
5 |
8 |

3 |
5 |
7 |
9 |
8 |
2 |

The order of the pixel value:1,2,3,3,3,4,5,7,8.The median value of this mask size=3.

Here, the centre pixel value 3 is replaced by the median value 3.

3 |
1 |
5 |
6 |
9 |
2 |

7 |
A |
B |
C |
D |
1 |

2 |
E |
F |
G |
H |
8 |

1 |
I |
J |
K |
L |
7 |

1 |
M |
N |
O |
P |
8 |

3 |
5 |
7 |
9 |
8 |
2 |

Here, we find out the A to P value as shown in figure 2.5. First, we find out the median value for 3*3 mask size and replacing the original centre pixel value by these values.

To find A:

Order: 1, 2, 3,3,3,4,5,7,8.

Median=3.

To find B:

Order: 1, 3, 3,3,4,4,5,6,8.

Median=4.

To find C:

Order: 2, 3, 3,4,4,5,6,8,9.

Median=4.

To find D:

Order: 1, 2, 2,3,4,5,6,8,9.

Median=4.

Similar way, we have to calculate F to P.

To find P:

Order: 2, 4,5,5,5,8,8,9

Median=5.

The final output of synthetic image of “6*6” window as shown in figure 2.6.

3 |
1 |
5 |
6 |
9 |
2 |

7 |
3 |
4 |
4 |
4 |
1 |

2 |
4 |
4 |
4 |
4 |
8 |

1 |
4 |
4 |
4 |
5 |
7 |

1 |
4 |
4 |
5 |
5 |
8 |

3 |
5 |
7 |
9 |
8 |
2 |

By checking the synthetic image output by using Matlab. To Refer the Matlab Coding in Appendix A.

### Output:

3 1 5 6 9 2

7 3 4 4 4 1

2 4 4 4 4 8

1 4 4 4 5 7

1 4 4 5 5 8

3 5 7 9 8 2

Both Hand calculation synthetic image output and Matlab synthetic image output are same.

### 2.4 Median Filter Implementation on Mat lab:

In past years, linear filters become the most popular filters in image processing. The reason of their popularity is caused by the existence of robust mathematical models which can be used for their analysis and design. However, there exist many areas in which the nonlinear filters provide significantly better results. The advantage of non linear filters lies in their ability to preserve edges and suppress the noise without loss of details. The success of nonlinear filters is caused by the fact that image signals as well as existing noise types are usually nonlinear.

Due to the imperfection of image sensors, images are often corrupted by noise. The impulse noise is the most frequently referred type of noise. The most cases, impulse noise is caused by malfunctioning pixels in camera sensors, faulty memory locations in hardware, or errors in data transmission. We distinguish two common types of impulse noise. They are Salt-and-Pepper noise and the random valued shot noise. For images corrupted by salt-and-pepper noise, the noisy pixels have only maximum or minimum values. In case of random valued shot noise, the noisy pixels have arbitrary value.

Traditionally, the impulse noise is removed by a median filter which is the most popular non linear filter .A standard median filter gives poor performance for images corrupted by impulse noise with higher intensity. A simple median filter utilizing 3*3 or 5*5 pixel window is sufficient only when the noise intensity is less than approximately 10-20%.

Here, we implement the median filter using Matlab. To refer the Matlab coding in Appendix B.

### Output:

### problem

The Noisy Image is corrupted by Salt-and-Pepper noise. By using median filter, 3*3 mask size most of noise has been eliminated.

If we smooth the noisy image with larger median filter 7*7 mask size, all the noisy pixels disappear as shown above figure.

### 3.0 Neighbourhood Averaging Filters

Neighborhood averaging filters are similar to mean filters. The Neighborhood averaging filter is the simplest low pass filter; here all coefficients are identical. These filters sometimes are called Averaging filters. The characteristics of neighborhood averaging are defined by kernel height, width and shape. When Kernel size increases, the smoothing effect also increases. The idea behind these filters is straight forward. By replacing the every pixel value in an image by the average of the intensity levels in the neighborhood defined by the filter mask, this process results in an image with reduced “sharp” transitions in intensity levels. The window is usually square, but can be any shape like rectangular, circular, etc. depending on the size of an image.

Each point in the smoothed image, is f(x,y)obtained from the average pixel value in a neighbourhood of (x,y) in the input image.

For example, if we use a 3×3 neighbourhood around each pixel we would use the mask

1/9 |
1/9 |
1/9 |

1/9 |
1/9 |
1/9 |

1/9 |
1/9 |
1/9 |

Each pixel value is multiplied by 1/9, summed, and then the result placed in the output image. This mask is successively moved across the image until every pixel has been covered. That is, the image is convolved with this smoothing mask (also known as a spatial filter or kernel).

However, one usually expects the value of a pixel to be more closely related to the values of pixels close to it than to those further away. This is because most points in an image are spatially coherent with their neighbours; indeed it is generally only at edge or feature points where this hypothesis is not valid. Accordingly it is usual to weight the pixels near the centre of the mask more strongly than those at the edge.

Some common weighting functions include the rectangular weighting function above (which just takes the average over the window), a triangular weighting function, or a Gaussian.

In practice one doesn’t notice much difference between different weighting functions, although Gaussian smoothing is the most commonly used. Gaussian smoothing has the attribute that the frequency components of the image are modified in a smooth manner.

Smoothing reduces or attenuates the higher frequencies in the image. Mask shapes other than the Gaussian can do odd things to the frequency spectrum, but as far as the appearance of the image is concerned we usually don’t notice much.

The arithmetic mean is the “standard” average, often simply called the “mean”.

The mean may be confused with the median, mode or range. The mean is the average of a set of values, or distribution; however, for probability distributions, the mean is not necessarily the same as the median, or the mode.

For example:

The observations are [7,5,6,8,1,3,8,5,4].

First, we find out the total value for these observations.

Total=7+5+6+8+1+3+8+5+4=47

Then, finding the average one. Here, number of observations n=9.

Average=total/9.

=47/9

Average=5.22(Equivalent to 5)

So, the average =5.

### 3.1 Synthetic image

Let us consider 6*6 window size.

3 |
1 |
5 |
6 |
9 |
2 |

7 |
3 |
8 |
4 |
5 |
1 |

2 |
4 |
3 |
3 |
2 |
8 |

1 |
8 |
9 |
6 |
2 |
7 |

1 |
9 |
2 |
6 |
5 |
8 |

3 |
5 |
7 |
9 |
8 |
2 |

Figure 3.1

Here, we take 3*3 mask size, to find out the Neighbourhood averaging value.

3 |
1 |
5 |
6 |
9 |
2 |

7 |
3 |
8 |
4 |
5 |
1 |

2 |
4 |
3 |
3 |
2 |
8 |

1 |
8 |
9 |
6 |
2 |
7 |

1 |
9 |
2 |
6 |
5 |
8 |

3 |
5 |
7 |
9 |
8 |
2 |

The order of the pixel value:1,2,3,3,3,4,5,7,8.The averaging value of this mask size=4.

Here , the centre pixel value 3 is replaced by the averaging value 4.

By using this method, we have to calculate the median value for whole window size 6*6.

### Cite This Work

To export a reference to this article please select a referencing stye below:

3 |
1 |
5 |
6 |
9 |
2 |

7 |
A |
B |