Dip Unit3 Reg13
Dip Unit3 Reg13
2. Draw the model of image degradation / restoration process? (Nov 2008 & Nov 2011 &
May 2013 &May 2015)
For x=0………… M – 1
Y=0………… N-1
7. Define Wiener filter? (OR )What are the functions of wiener filter? (June 2011)
Wiener filtering is a method of restoring images in the presence of blur and noise.
13. Define pseudo inverse filter? (Nov 2008 & Nov 2011)
Stabilized or generalized version of inverse filter.
For linear shift invariant system with frequency response H (u,v) is
15. State the concept of inverse filtering? (or) What is the principle of inverse filtering?
(May-2014)
The inverse filtering divides the transform of the degraded image G(u, v) by the degradation
function H(u, v) and determines an approximation of the transform of the original image.
20. What are the limitations of inverse filtering? (or) Mention the drawbacks of inverse
filtering. (June 2011, Nov-2013)
25. Define rubber sheet transformation. (or) Geometric transformation:(May 2013 &
2015)
Geometric transformation:
It is generally modify spatial relationship between pixels in an image. It is also called as
“Rubber sheet transformation” because they may be viewed as the process of printing the image
on a sheet of rubber.
27. What are the basic transformations that can be applied on the images?
– Applying some basic transformation to a uniformly distorted image can correct for a range
of perspective distortions by transforming the measurements from the ideal coordinates to those
actually used. (For example, this is useful in satellite imaging where geometrically correct
ground maps are desired.)
– Translation
– Scaling
– Rotation
– Concatenation
PART-B
1. Explain in detail about noise distributions or noise models? (Apr2010)
Noise distribution:
The noise in the digital image arises due to image acquisition or transmission while
image acquisition, the image sensor is affected by environmental factors.
While transmission of images are corrupted due to interference in the channel.
Spatial property of noise:
The noise is independent of spatial co-ordinates. However in some application, it is invalid and
so we deal with spatial dependent.
PDF of noise:
(i). Gaussian noise:
The mathematical expression for Gaussian noise is in both spatial of frequency domains. This
models are convenient because they are marginally applicable at best.
Where,
Μ – means of z σ – SD
σ² - variance z – gray level
P(z)
1/√2πσ
μ – σ μ μ+σ
When Z is described 70% of its value will be in the range of µ – σ, µ+σ.
P(2)
0.607
√2/b
a a+ √b/2 b
P(2)
z
(b-1)/a
P(z)
a
z
(v) Uniform Noise: The PDF of uniform noise is given by,
1/ -a
b
Z
(vi). Impulse noise distribution or Salt & Pepper noise:
If b>a, there will be dark dot in the image and will appear like a black dots.
If a>b, these will be white dots appearing in the image. If either Pa or Pb is zero then the
impulse noise is called as “Unipolar noise”.
If neither Pa nor Pb is zero, then the noise is called as bipolar noise. It means salt &
pepper granules distributed over the images so the bipolar noise is known as “salt & pepper
noise”.
It is also called as short spike noise. Negative impulse appears in black and positive
impulse appears in white dots.
The arithmetic mean filter computes the average value of the corrupted image g(x, y) in
the area defined by Sxr The value of the restored image f at point (x, y ) is simply the arithmetic
mean computed using the pixels in the region defined by Sxy.
The geometric mean filter is performed by restored pixel is by the product of pixel is the
sub image window. It rises to the power of 1/mn.
The image analysis includes measurement of shape, size, texture and color of the objects
present in the image. Here the input is image and produces numerical and graphical information
based on the characteristics of the image data.
Based upon the filter results, the analysis of an image is performed and identify which
pixel need to be improved. These are done based upon the statistical measurements.
It can be used to reduce noise such as salt noise and Gaussian noise, The restored image
using harmonic mean filter is given by,
It is used to reduce salt and pepper noise. The restored image is given by,
For positive values of Q, it eliminates pepper noise and for negative values of q it eliminates salt
noise.
It can’t do both simultaneously.
If Q=0, then the contra harmonic mean filter reduces to arithmetic mean filter.
If Q=-1, it reduces to harmonic mean filter. Thus it is helpful restore the images.
The best-known order-statistic filter is the median filter, which, as its name implies, replaces
the value of a pixel by the median of the intensity levels in the neighborhood of that pixel:
This filter is useful for finding the brightest points in an image. Also, because pepper
noise has very low values, it is reduced by this filter as a result of the
The midpoint filter simply computes the midpoint between the maximum and minimum values
in the area encompassed by the filter:
This filter combines order statistics and averaging. It works best for randomly distributed noise,
like Gaussian or uniform noise.
where the value of d can range from 0 to mn - 1. When d = 0, the alpha-trimmed filter
reduces to the arithmetic mean filter discussed in the previous section. If we choose d = mn - 1,
the filter becomes a median filter.
For other values of d , the alpha-trimmed filter is useful in situations involving multiple
types of noise, such as a combination of salt-and-pepper and Gaussian noise.
The simplest statistical measures of a random variable are its mean and variance.
These are reasonable parameters on which to base an adaptive filter because they are
quantities closely related to the appearance of an image.
The mean gives a measure of average intensity in the region over which the mean is
computed, and the variance gives a measure of contrast in that region.
Our filter is to operate on a local region, Sxv .
The response of the filter at any point ( x , y ) on which the region is centered is to be based on
four quantities:
1. g ( x , y), the value of the noisy image at ( x , y);
2. (b)σ ŋ2, the variance of the noise corrupting f(x, y) to form g ( x , y);
3. m L , the local mean of the pixels in Sxv ; and
4. σ L2, the local variance of the pixels in S x v .
1. If σŋ2 is zero, the filter should return simply the value of g ( x , y).This is the
trivial, zero-noise case in which g ( x , y ) is equal to f ( x , y ) .
2. If the local variance is high relative to σŋ2, the filter should return a value
close to g ( x , y ) . A high local variance typically is associated with edges, and
these should be preserved.
3. If the two variances are equal, we want the filter to return the arithmetic
mean value of the pixels in S x v .
This condition occurs when the local area
has the same properties as the overall image, and local noise is to be re-
duced simply by averaging.
An adaptive expression for obtaining based on these assumptions may be written as
The only quantity that needs to be known or estimated is the variance of the overall noise,
σŋ .
2
The other parameters are computed from the pixels in S xy at each location ( x , y ) on
which the filter window is centered.
ratio is set to 1 if the condition occurs. This makes this filter nonlinear.
However, it prevents nonsensical results (i.e., negative intensity levels, depending on the
value of m L ) due to a potential lack of knowledge about the variance of the image noise.
Another approach is to allow the negative values to occur, and then rescale the intensity values
at the end. The result then would be a loss of dynamic range in the image.
The median filter performs well if the spatial density of the impulse noise is not large
(as a rule of thumb, Pa and Pb less than 0.2).
An additional benefit of the adaptive median filter is that it seeks to preserve detail
while smoothing non impulse noise, something that the "traditional" median filter does not
do.
As in all the filters discussed in the preceding sections, the adaptive median filter
also works in a rectangular window area S xy .
Unlike those filters, however, the adaptive median filter changes (increases) the
size of Sxv during filter operation, depending on certain conditions listed in this section.
Keep in mind that the output of the filter is a single value used to replace the value
of the pixel at ( x , y ) , the point on which the window Sxv is centered at a given tune.
The adaptive median-filtering algorithm works in two stages, denoted stage A and stage B , as
follows:
The key to understanding the mechanics of this algorithm is to keep in mind that it has
three main purposes: to remove salt-and-pepper (impulse) noise, to provide smoothing of other
noise that may not be impulsive, and to reduce distortion, such as excessive thinning or
thickening of object boundaries.
The values zmin and zmax are considered statistically by the algorithm to be "impulse-like"
noise components, even if these are not the lowest and highest possible pixel values in the
image.
With these observations in mind, we see that the purpose of stage A is to determine if the
median filter output, zmed, is an impulse (black or white) or not.
If the condition zmin < zmed < zmax holds, then zmed cannot be an impulse for the reason
mentioned in the previous paragraph.
In this case, we go to stage B and test to see if the point in the center of the window, Zxy,
is itself an impulse (recall that z xy is the point being processed).
If the condition B1 > 0 AND B2 < 0 is true, then z min < z xy < z max , and z xv cannot be an impulse
for the same reason that z med was not.
In this case, the algorithm outputs the unchanged pixel value, z xy . By not changing these
"intermediate-level" points, distortion is reduced in the image.
If the condition B1 > 0 AND B2 < 0 is false, then either Zxy-Zmin or Zxy = Zmax. In
either case, the value of the pixel is an extreme value and the algorithm outputs the median
value zmed, which we know from stage A is not a noise impulse.
The last step is what the standard median filter does. The problem is that the standard
median filter replaces every point in the image by the median of the corresponding
neighborhood. This causes unnecessary loss of detail.
Continuing with the explanation, suppose that stage A does find an impulse (i.e., it fails
the test that would cause it to branch to stage B).
The algorithm then increases the size of the window and repeats stage A. This looping
continues until the algorithm either finds a median value that is not an impulse (and branches to
stage B), or the maximum window size is reached.
If the maximum window size is reached, the algorithm returns the value of z m e d . Note
that there is no guarantee that this value is not an impulse.
The smaller the noise probabilities Pa and/or Pb are, or the larger Smax is allowed to be, the
less likely it is that a premature exit condition will occur.
This is plausible. As the density of the impulses increases, it stands to reason that we
would need a larger window to "clean up" the noise spikes.
Every time the algorithm outputs a value, the window S x v is moved to the next location
in the image. The algorithm then is reinitialized and applied to the pixels in the new location.
As indicated in Problem 3.18, the median value can be updated iteratively using only the
new pixels, thus reducing computational load.
5. Explain Periodic Noise Reduction by Frequency Domain Filtering (or) various types of
filter for periodic noise reduction.
The basic idea is that periodic noise appears as concentrated bursts of energy in the
Fourier transform, at locations corresponding to the frequencies of the periodic interference.
The approach is to use a selective filter to isolate the noise.
The three types of selective filters bandreject, bandpass, and notch are used for basic
periodic noise reduction.
It is not difficult to show that the Fourier transform of a sine consists of two impulses that
are mirror images of each other about the origin of the transform.
The impulses are both imaginary (the real part of the Fourier transform of a sine is zero)
and are complex conjugates of each other.
Figure 5.16(a), which is the same as Fig. 5.5(a), shows an image heavily corrupted
by sinusoidal noise of various frequencies.
The noise components are easily seen as symmetric pairs of bright dots in the Fourier
spectrum shown in Fig. 5.16(b).
In this example, the components lie on an approximate circle about the origin of the
transform, so a circularly symmetric bandreject filter is a good choice.
Figure 5.16(c) shows a Butterworth bandreject filter of order 4, with the appropriate
radius and width to enclose completely the noise impulses.
Since it is desirable in general to remove as little as possible from the transform, sharp,
narrow filters are common in bandreject filtering.
The result of filtering Fig. 5.16(a) with this filter is shown in Fig. 5.16(d). The
improvement is quite evident.
Even small details and textures were restored effectively by this simple filtering ap-
proach.
It is worth noting also that it would not be possible to get equivalent results by a direct
spatial domain filtering approach using small convolution masks.
A notch filter rejects (or passes) frequencies in predefined neighborhoods about a center
frequency.
Equations for notch filtering are detailed in Section 4.10.2. Figure 5.18 shows 3-D plots
of ideal, Butterworth, and Gaussian notch (reject) filters.
Due to the symmetry of the Fourier transform, notch filters must appear in symmetric
pairs about the origin in order to obtain meaningful results.
The one exception to this rule is if the notch filter is located at the origin, in which
case it appears by itself.
Although we show only one pair for illustrative purposes, the number of pairs of
notch filters that can be implemented is arbitrary.
The shape of the notch areas also can be arbitrary (e.g., rectangular). We can obtain
notch filters that pass, rather than suppress, the frequencies contained in the notch areas.
Since these filters perform exactly the opposite function as the notch reject filters,
their transfer functions are given by
where HNP(u,v) is the transfer function of the notch pass filter corresponding to the
notch reject filter with transfer function H NR(u, v ) .
Alternative filtering methods that reduce the effect of these degradations are quite
useful in many applications.
The method discussed here is optimum, in the sense that it minimizes local variances of
the restored estimate f ( x , y ) .
The procedure consists of first isolating the principal contributions of the interference
pattern and then subtracting a variable, weighted portion of the pattern from the corrupted
image.
Although we develop the procedure in the context of a specific application, the basic
approach is quite general and can be applied to other restoration tasks in which multiple
periodic interference is a problem.
The first step is to extract the principal frequency components of the interference pattern.
As before, this can be done by placing a notch pass filter. H N P ( u , v ) , at the location
of each spike.
If the filter is constructed to pass only-components associated with the interference
pattern, then the Fourier transform of the interference noise pattern is given by the expression
where, as usual, G(u, v), denotes the Fourier transform of the corrupted image.
Formation of H N P (u,v ) requires considerable judgment about what is or is not an
interference spike.
For this reason, the notch pass filter generally is constructed interactively by
observing the spectrum of G (u,v ) on a display.
After a particular filter has been selected, the corresponding pattern in the spatial
domain is obtained from the expression
6. Explain the image restoration using inverse filtering. What are its limitations?
(or)Describe inverse filtering for removal of blur caused by any motion and describe how
it restore the image. (Nov 2010, April 2010, May-2014& May 2015)
Inverse filtering:-
It is the process of recovering the input of a system from its output. They are useful for
recorrecting an input signal in anticipation of the degradation caused by the system such as
correcting a non – linearity of the display.
The inverse filtering divides the transform of the degraded image by the degradation
function.
w.k.t unconstrained restoration,
We know that, g = Hf + ŋ
G(u, v) = H(u, v) F(u, v) + N(u, v)
Restored image is given by,
Drawbacks:
Inverse filtering is highly sensitive to noise.
The above drawbacks can be overcome by limiting the filter frequencies to only the values
around the origin. This will decrease the probability of zero occurrence value degradation
function.
7. Explain the function of Wiener filter for image restoration in presence of additive noise?
(or) Explain the principle of least square filter and state its limitation. (Nov 2012, June
2011, May 2013, May-2014) (or) minimum mean square error filtering?(Nov 2014 & May
2015)
Objective:
It is to approximate the original image in such a way the mean square error between
original and approximated image will be minimized.
LMS Value:
Where,
f – Original image.
𝑓̂- Restored image.
Assumptions:
(i). The image of noise are uncorrelated (no relation).
(ii). Either image or the noise has zero mean.
(iii). Approximated gray level for a linear function of degraded gray level.
Approximated image,
Where,
H* (u,v) – conjugate of H (u,v)
PREPARED BY P.SRIVIDDHYA-AP/ECE, S.MAHESWARI-AP/ECE 21
IT6005- DIP UNIT III -IMAGE RESTORATION AND SEGMENTATION
Case 1:
If noise = 0
The mean square error can be approximated also in terms a-summation involving the original
and restored images:
considers the restored image to be "signal" and the difference between this image and the
original to be noise, signal-to-noise ratio in the spatial domain as
Case 2:
8. What is edge detection? Describe in detail about the types of edge detection
operation?(or) Explain how edges of different orientations can be detected in an
image?[NOV 2011& NOV 2012] &[Nov 2014]
Edge:
An edge is a boundary between two regions with relatively gray level properties different. It is
a set of connected pixels that lie on the boundary between two regions.
An ideal image edge is a set of connected pixels in the vertical direction where edge of the
pixel is located at an orthogonal step transition in gray level.
Edges are blurred, due to optics, sampling and other image acquisition imperfections.
Thick edges of ramp are inversely proportional to the degree of blurring in the edge.
The thickness is determined by length of ramp. Length is determined by slope, in turn
determined by degree of blurring. Blurred image edges tends to be thick of sharp edge tend to be
thin.
Use of Operator:
1. First derivative operator-Gradient.
2. Second derivative operator-Laplacian
Gradient operators:
The gradient of an image f(x, y) at location (x, y) is defined as,
|∇𝑓| =
∇𝑓 is commonly known as gradient
𝐺𝑥
𝛼(𝑥, 𝑦) = tan−1 ( )
𝐺𝑦
P4 P5 P6
P7 P8 P9
-1 -1 -1
0 0 0
1 1 1
-1 0 1
-1 0 1
-1 0 1
Gx edge detection in Horizontal detection
Gx = (P7 + P8 + P9) – (P1 + P2 + P3)
Gy = (P3 + P6 + P9) – (P1 + P4 + P7 )
(Edge detection in vertical detection)
Where P1 ……. P9 Pixel values in subimage
P1 P2 P3
P4 P5 P6
P7 P8 P9
3x3 Images
-1 -2 -1
0 0 0
1 2 1
-1 0 1
-2 0 2
-1 0 1
For horizontal detection
Gx = (P7 + 2P8 + P9) – (P1 + 2P2 + P3)
To find Gy:-
Gy = (P3 + 2P6 + P9) – (P1 + 2P4 + P7)
-1 0
0 1
Gx
0 -1
1 0
Gy
Gx = P9 – P5
Gy= P8 – P6
Uses:
1.It is used to differentiate the dark and bright level.
The Laplacian of a 2D function f(x, y) is a second order derivative is given by,
P4 P5 P6
P7 P8 P9
3x3 Images
Laplacian Mask
0 -1 0
-1 4 -1
0 -1 0
For 3x3 images, the Laplacian operator is given below
The coefficients associated with center pixels are positive & negative.
Sum of coefficients is zero.
Drawbacks:
1.It is highly sensitive to noise.
2.Its magnitude produces double edges, which makes the segmentation difficult.
3.It is unable to detect edge detection.
9. Explain in detail about the process of edge linking and boundary detection? (Or) How
do you link edge pixels through global processing? (May/June-2013)(Or) how do you link
edge pixels through hough transform. {May 2015]
Linking the edges of an image is done by edge linking and boundary detection.
The following techniques are used for edge linking and boundary detection.
1). Local processing.
2). Global processing using Hough transform.
3). Global processing using graph theoretic approach.
1) Local processing:-
One method for linking edges is to analyze the characteristic pixel in small neighborhood
about every point in an image.
In this method, global relationship between pixel are considered and the points are linked by
first determined whether they lie on a curve (or) a specified shape
Finding straight line point:
Let there are n-points in an image if the subset of points that lie on the straight line are to be
found.
Method 1:
First find all lines determined by every pair of points then find all subset of points that are close
to particular line.
Method 2:
This is an alternative approach to method 1 which is referred as hough transform
Consider a point xi, yi the general equation of straight line.yi = axi + b
now the number of lines passed through the xi and yi for different values of a and b
consider a second point xi, yi also has a line. Let this line intercept the line (xi, yi )
There are ‘n’ points in an image. We have to find the subsets of points that lie on standard
lines.
One possible solution is to first find all lines. They are determined by every pair of points &
then find all subsets of points that are close to particular lines.
For varying a & b. However writing this equation as b= -axi + yi and considering ab plane
yields the equation of a single line for fixed pair (x i, y i). Further a second point (x i , y i ) also
has a lines in parameter space associated with it and this line intersects the line associated with
(x i , y i ) at (a’, b’)
[where a’ – slope & b’ – intercept of line]
y b’
The computational bmin attractiveness bmax of the Hough transform arises from subdividing the
parameter space into Accumulator cells.
Accumulator cells:
An important property of Huff transform is that the parameter space can be subdivided into cells
which is referred as accumulator cells.
Procedure:
1) Compute the gradient of an image and threshold
2) Specify subdivision in the plane
3) Examine the count of accumulator cell for high pixel concentration
4) Examine the relationship between the pixels
Applications:
1) In addition to straight line, Huff transform has applied to any function
2) Huff transform can be used to detect curves without any simple analytical representation.
10. Explain in detail about region growing process in detail? [APRIL 2010, May-2013] (o)
Explain region based segmentation and region growing with an example.[May 2015]
The process of dividing an image into smaller regions is based on some predefined rules.
(1).
(2). Ri is a connected region for i=1, 2 … n, all the pixels in the region should be connected.
(3). Ri ∩ Rk = Ф for all i & k, where i ≠ k. this shows that region must be disjoint. No pixel
should be presenting two different regions.
(4). P(R i) = true, for i=1, 2, ………n, all pixels in region R i have same intensity levels.
(5). P(R i U Rk) = false, for i ≠ k, this shows that R i& Rk are different. The pixels in two
adjacent regions should not have same intensity.
Steps:
1. Find seed points.
2. Find the similarity pixels.
3. Find the stopping point.
Region growing is a process of rating pixels or sub regions into larger regions based on pre-
defined similarity criteria.
This approach starts with a set of start point known as “seed points”. Then the neighbouring
pixel having property that is similar to the seed are added to each seed. Thus new regions are
grown.
Similarity criteria:
It is based on intensity value, texture, color, size, and shape of the region being grown.
For eg:
Let us consider 5x5 image pixels for the threshold value of 3 (Th = 3)
1 0 5 6 7
1 0 5 5 5
0 12 6 77 6
1 2 5 6 7
1 1 7 6 5
Values inside the boxes are gray level .Two seeds are 2 & 7.
The location of 2 is (4, 2) & the location of 7 is (3, 4).
These are the starting points. Then the regions are grown.
Here Th = 3
The absolute difference between gray level of that pixel and the gray level of seed must be less
than the threshold values
R1 R1 R2 R2 R2
R1 R1 R2 R2 R2
R1 R1 R2 R2 R2
R1 R1 R2 R2 R2
R1 R1 R2 R2 R2
Region 1 Region 2
11. Explain the principle of Region splitting and merging in details. [APRIL 2010, NOV
2011, May-2013, NOV 2012)
Region splitting and merging is a segmentation process in which an image is initially
subdivided into a quadrant and then the regions are merged (or) splitted to satisfy the basic
conditions.
In this technique, the image is divided into various sub images of disjoint regions and then
merges the connected region together.
R – be the entire region of the image.
The predicate P(Ri) is used to check the condition. In any region, if P(Ri)= true, then image is
subdivided into various subimages.
If P(Ri) = false, then divide the image into quadrants. If P(R i) = false, then further divide the
quadrants into sub quadrants.
R1
R11 R12
R2
R13 R14
R3 R4
Region R11 is divided into quadrants.
Quad tree:
A Quad tree is a tree in which the nodes have exactly four descendants (Followers).
This is shown in quadrants representation as shown below
Quadtree representation
Example for split & merge algorithm is shown below:-
xxx xxxxxx
R1 R2 R3 R4
xxxxxx xxxxxx
R233 R234
xxxxxx xxxxxx
Advantages:
It uses the same quad tree for splitting and merging.
Basic concept:-
Image is visualized in 3 dimensions
1) Two spatial dimensions.
2). Gray level
Any gray tone image may be considered as topological surface.
The main aim of the segmentation algorithm based on this concept is to find watershed lines.
Catchment basins:-
Points at which water drop, if placed at locations of any of those points would fall to single
minimum is called as watershed lines.
Watershed lines:-
Points at which water drop would fall more than one such minimum is called as watershed
lines.
A line is build to prevent the rising water from, distinct catchment basins form merging.
Only the taps of down are visible above the water line.
These dam boundaries correspond to the divide lines of water sheds.
They are the connected boundaries by watershed segmentation algorithm.
In order to prevent structure, higher height dams are calculated.
The value of height is determined by highest possible gray level value in the input image.
(i) Erosion:
In words, this equation indicates that the erosion of A by B is the set of all points z such
that B, translated by z , is contained in A. In the following discussion, set B is assumed to be a
structuring element.
The statement that B has to be contained in A is equivalent to B not sharing any common
elements with the background; we can express erosion in the following equivalent form:
The elements of A and B are shown shaded and the background is white.
The solid boundary in Fig. 9.4(c) is the limit beyond which further displacements of the
origin of B would cause the structuring element to cease being completely contained in A.
Thus, the locus of points (locations of the origin of B ) within (and including) this
boundary, constitutes the erosion of A by B.
We show the erosion shaded in Fig. 9.4(c).
Keep in mind that that erosion is simply the set of values of z that satisfy Eq. (9.2-1) or
(9.2-2).
The boundary of set A is shown dashed in Figs. 9.4(c) and (e) only as a reference; it is not
part of the erosion operation.
Figure 9.4(d) shows an elongated structuring element, and Fig. 9.4(e) shows the erosion
of A by this element. Note that the original set was eroded to a line.
Equations (9.2-1) and (9.2-2) are not the only definitions of erosion (see Problems 9.9
and 9.10 for two additional, equivalent definitions.)
However, these equations have the distinct advantage over other formulations in that they
are more intuitive when the structuring element B is viewed as a spatial mask (see Section
3.4.1).
Thus erosion shrinks or thins objects in a binary image. In fact, we can view erosion as a
morphological filtering operation in which image details smaller than the structuring element
are filtered (re-moved) from the image. In Fig. 9.5, erosion performed the function of a "line
filter."
(ii) Dilation
This equation is based on reflecting B about its origin, and shifting this reflection by z
(see Fig. 9.1).
The dilation of A by B then is the set of all displacements, z , such that B and A overlap
by at least one element. Based on this interpretation, Eq. (9.2-3) can be written equivalently as
Equations (9.2-3) and (9.2-4) are not the only definitions of dilation currently in use (see
Problems 9.11 and 9.12 for two different, yet equivalent, definitions).
However, the preceding definitions have a distinct advantage over other formulations in
that they are more intuitive when the structuring element B is viewed as a convolution mask.
The basic process of flipping (rotating) B about its origin and then successively
displacing it so that it slides over set (image) A is analogous to spatial convolution, as
introduced in Section 3.4.2.
Keep in mind, however, that dilation is based on set opera- tions and therefore is a
nonlinear operation, whereas convolution is a linear operation.
Unlike erosion, which is a shrinking or thinning operation, dilation "grows" or "thickens"
objects in a binary image.
The specific manner and extent of this thickening is controlled by the shape of the
structuring element used.
Figure 9.6(a) shows the same set used in Fig. 9.4, and Fig. 9.6(b) shows a structuring
element (in this case B = B because the SE is symmetric about its origin).
The dashed line in Fig. 9.6(c) shows the original set for reference, and the solid line
shows the limit beyond which any further displacements of the origin of B by z would cause the
intersection of B and A to be empty.
Therefore, all points on and inside this boundary constitute the dilation of A by B.
Figure 9.6(d) shows a structuring element designed to achieve more dilation vertically
than horizontally, and Fig. 9.6(e) shows the dilation achieved with this element.
H(k,l)=
𝟏 𝟏 𝟏 𝟏 𝟎. 𝟏 𝟎. 𝟏 𝟎. 𝟏 𝟎 𝟏 𝟏 𝟏 𝟏
𝟏 −𝒋 −𝟏 𝒋 𝟎. 𝟏 𝟎. 𝟏 𝟎. 𝟏 𝟎. 𝟏 𝟏 −𝒋 −𝟏 𝒋
| || | | |
𝟏 −𝟏 𝟏 −𝟏 𝟎. 𝟎𝟓 𝟎. 𝟏 𝟎. 𝟏 𝟎. 𝟎𝟓 𝟏 −𝟏 𝟏 −𝟏
𝟏 𝒋 −𝟏 −𝒋 𝟎 𝟎. 𝟎𝟓 𝟎. 𝟎𝟓 𝟎 𝟏 𝒋 −𝟏 −𝒋
1
G(k,l) = is given by inverse filtering
𝐻(𝑘,𝑙)
1 −2.5 + 2.5𝑗 ∞ −2.5 − 2.5𝑗
−1 + 3𝑗 10𝑗 ∞ −10
= | |
∞ −5 + 5𝑗 ∞ −5 − 5𝑗
−1 − 3𝑗 −10 ∞ −10𝑗