Upload
trinhduong
View
223
Download
3
Embed Size (px)
Citation preview
Digital Image Processing
IMAGE ENHANCEMENT
Hamid R. Rabiee
Fall 2015
In the Name of Allah
Image Enhancement
DEFINITION: accentuation, or sharpening, of image features such as edges, boundaries, or contrast to make a graphic display more useful for display and analysis
NOT INCREASE the inherent information content in the data
INCREASE the dynamic range of the chosen features so that they can be detected easily
AN IMPORTANT PROBLEM: in image enhancement is quantifying the criterion for enhancement
2
Techniques 3
Zero-memory Filters for Enhancement
POINT OPERATIONS: Zero memory operations where a given gray level 𝒖 ∈ [𝟎, 𝑳] is mapped into a gray level 𝒗 ∈ [𝟎, 𝑳] according to a transformation
Input and output gray levels are distributed between [0, L]. Typically, L = 255
1- CONTRAST STRETCHING
The slopes a, b ,g determine the relative contrast stretch
4
Contrast stretchingExamples
5
Contrast stretching Examples 6
Zero-memory Filters for Enhancement
2- NOISE CLIPPING AND THRESHOLDING
A special case of contrast stretching where a = g = 0 is called CLIPPING.
The slopes a, b ,g determine the relative contrast stretch
Useful for binary or other images that have bimodal distribution of gray levels. The a and b define the valley between the peaks of the histogram. For a = b = t, this is called THRESHOLDING (The output becomes binary).
7
Thresholding CLIPPING
Clipping and thresholding 8
Zero-memory Filters for Enhancement
3- GRAY SCALE REVERSAL
Creates digital negative of the image
4- GRAY-LEVEL WINDOW SLICING
9
Without background: With background:
Fully illuminates pixels lying in the interval [a, b] and removes the background.
Digital negatives 10
Zero-memory Filters for Enhancement
5- BIT EXTRACTION
B = number of bits used to represent u as an integer. This extracts the n-thmost-significant bit.
6- BIT REMOVAL
11
Most-significant-bit removal Least-significant-bit removal
Level slicing of intensitywindow
12
visual and infrared (IR) images
Segmented Images
13
Zero-memory Filters for Enhancement
7- RANGE COMPRESSION
Intensity to contrast transformation.
14
Range compression 15
Original log
Image Subtraction and Change Detection
A simple but powerful method is to align the two images and subtract them
16
Histogram Modeling
The HISTOGRAM of an image represents the relative frequency of occurrence of the various gray levels in the image
Histogram-modeling techniques modify an image so that its histogram has a desired shape
Useful in stretching the low-contrast levels of images with narrow histograms
Histogram Equalization
Histogram Specification
17
Histogram Equalization
Goal: Uniform distribution of the output image
18
Histogram equalization 19
input image,its histogram
Processed
image,its histogram
input image Equalized image
Example 20
Spatial Operations
Many image enhancement techniques are based on spatial operations performed on local neighborhoods of input pixels
Often, the image is convolved with a finite impulse response filter called SPATIAL MASK
Spatial Averaging and Spatial Low-pass Filtering
21
Input ImageOutput Image
All equal weights
Spatial Averaging Filter
22
Number of Pixels in window W
Spatial averagingfilters for smoothing images containing
Gaussiannoise
23
Median Filtering
Example
24
Properties of Median Filter
It is a nonlinear filter. Thus for two sequences x (m) and y (m)
It is useful for removing isolated lines or pixels while preserving spatial resolutions
Its performance is poor when the number of noise pixels in the window is greater than or half the number of pixels in the window
25
Example 26
27
Unsharp Masking and Crispening
The unsharp masking technique is used commonly in the printing industry for crispening the edges
In general the unsharp masking operation can be represented by
Discrete Laplacian
28
Gradient Function
Unsharp Masking Operations 29
30
Spatial Low-pass, High-pass, and Band-pass Filtering
31
Spatial Low-pass Filter
Spatial High-pass Filter
Spatial Band-pass Filter
Spatial Low-pass, High-pass, and Band-pass Filtering
Low-pass filters are useful for noise smoothing and interpolation
High-pass filters are useful in extracting edges and in sharpening images
Band-pass filters are useful in the enhancement of edges and other high-pass image characteristics in the presence of noise
32
33
Magnification and Interpolation (Zooming)
Replication
Linear Interpolation
34
35
36
Generalized Linear Filtering 37
Zonal Mask
Root Filtering
The effect of a-rooting is to enhance higher spatial frequencies (low amplitudes) relative to lower spatial frequencies (high amplitudes).
38
Generalized Cepstrum and Homomorphic Filtering
If the magnitude term in the previous slide is replaced by the logarithm of |𝒗(𝒌, 𝒍)| and we define
then the inverse transform of 𝒔(𝒌, 𝒍), denoted by 𝒄(𝒎, 𝒏), is called the generalized CEPSTRUM of the image
In practice a positive constant is added to |𝒗 𝒌, 𝒍 | to prevent the logarithm from going to negative infinity
The image c (m, n) is also
39
MULTISPECTRAL IMAGE ENHANCEMENT
In multispectral imaging there is a sequence of I images 𝑼𝒊 𝒎,𝒏 , 𝒊 =𝟏, 𝟐, … , 𝑰 where the number I is typically between 2 and 12
It is desired to combine these images to generate a single or a few display images that are representative of their features
There are three common methods of enhancing such images
Intensity Ratios
Log-Ratios
Principal Components
40
41
Intensity Ratios
where Ui (m, n) represents the intensity and is assumed to be positive
This method gives 12 - I combinations for the ratios, the few most suitable of which are chosen by visual inspection.
Sometimes the ratios are defined with respect to the average image to reduce the number of combinations.
42
Log-Ratios
The log-ratio Li,j gives a better display when the dynamic range of Ri,j is very large,
43
Principal Components
For each (m, n) define the I x 1 vector
The I x I KL transform of u(m, n), denoted by f, is determined from the autocorrelation matrix of the ensemble of vectors{ui (m, n), i = 1, . . . , I}.
The rows of f, which are eigenvectors of the autocorrelation matrix, are arranged in decreasing order of their associated eigenvalues.
Then for any 𝑰𝟎 ≤ 𝑰, the images vi (m, n), i = 1 , . . . , I0 obtained from the KL transformed vector v(m, n) = f u(m, n) are the first 𝑰𝟎principal components of the multispectral images.
44
False Color And Pseudocolor
FALSE COLOR implies mapping a color image into another color image to provide a more striking color contrast (which may not be natural) to attract the attention of the viewer
PSEUDOCOLOR refers to mapping a set of images ui(m, n), i=1,...,I into a color image. Usually the mapping is determined such that different features of the data set can be distinguished by different colors
45
Pseudocolor image enhancement
Color Image Enhancement
improvement of color balance or color contrast in a color image
46
Color image enhancement
End of Lecture
Thank You!
Tables, Pictures & equations are taken from Jain Book.