Вы находитесь на странице: 1из 33

June-2014

Master of Computer Application (MCA) Semester 6


MC0086 Diital !mae "rocessin 4 Cre#its
($oo% !D& $100')
Assinment Set 1 (60 Mar%s)
1. ()plain t*e follo+in&
A) ,un#amental Steps in Diital !mae "rocessin
Processing of digital image involves the following steps to be carried out in a sequence: Image
acquisition, Image enhancement, Image restoration, Color image processing, Wavelets and
Multiresolution processing, Compression, Morphological processing, egmentation, !epresentation
with description and finall" #b$ect recognition. Image acquisition is the first process. %o do so requires
an imaging sensor and the capabilit" to digiti&e the signal produced b" the sensor. %he sensor could be
a monochrome or a color %' camera that produces an entire image of the problem domain ever" 1()*
seconds. %he imaging sensor could also be a line+scan camera that produces a single image line at a
time. If the output of the camera or other imaging sensor is not alread" in digital form, an analog+to+
digital converter digiti&es it. ,ote that acquisition could be as being given an image that is alread" in
digital form. -enerall", the image acquisition stage involves preprocessing, such as scaling.
Image enhancement is one of the simplest and most appealing areas of digital image processing.
.asicall", the idea behind enhancement techniques is to bring out detail that is obscured, or simpl" to
highlight certain features of interest in an image. / familiar e0ample of enhancement is when we
increase the contrast of an image because 1it loo2s better3. It is important to 2eep in mind that
enhancement is a ver" sub$ective area of image processing. Image restoration is an area that also
deals with improving the appearance of an image. 4owever, unli2e enhancement, which is sub$ective,
image restoration is ob$ective, in the sense that restoration techniques tend to be based on
mathematical or probabilistic models of image degradation. Color image processing is an area that has
been gaining in importance because of the significant increase in the use of digital images on the
Internet. Color is used as the basis for e0tracting features of interest in an image. Wavelets are the
foundation for representing images in various degrees of resolution. In particular, this is used for image
data compression and for p"ramidal representation, in which images are subdivided successivel" into
smaller regions.
Compression deals with techniques for reducing the storage required to save an image, or the
bandwidth required to transmit it. /lthough storage technolog" has improved significantl" over the past
decade, the same cannot be said for transmission capacit". %his is true particularl" in uses of the
Internet, which are characteri&ed b" significant pictorial content. Image compression is familiar
5perhaps inadvertentl"6 to most users of computers in the form of image file e0tensions. Morphological
processing deals with tools for e0tracting image components that are useful in the representation and
description of shape. egmentation procedures partition an image into its constituent parts or ob$ects.
In general autonomous segmentation is one of the most difficult tas2s in digital image processing. /
rugged segmentation procedure brings the process a long wa" toward successful solution of imaging
problems that require ob$ects to be identified individuall". #n the other hand, wea2 or erratic
segmentation algorithms almost alwa"s guarantee eventual failure. In terms of character recognition
the 2e" role of segmentation is to e0tract individual characters and words from the bac2ground. %he
ne0t stage is !epresentation and description. 4ere, the first decision that must be made is whether the
data should be represented as a boundar" or as a complete region. .oundar" representation is
appropriate when the focus is on e0ternal shape characteristics, such as corners and inflections.
!egional representation is appropriate when the focus is on internal properties, such as te0ture or
s2eletal shape. Choosing a representation is onl" part of the solution for transforming raw data into a
form suitable for subsequent computer processing. 7escription, also called feature selection, deals with
e0tracting attributes that result in some quantitative information of interest or are basic for differentiating
one class of ob$ects from another. !ecognition is the process that assigns a label 5e.g., 1vehicle36 to an
ob$ect based on its descriptors.
8nowledge about a problem domain is coded into an image processing s"stem in the form of a
2nowledge database. %his 2nowledge ma" be as simple as detailing regions of an image where the
information of interest is 2nown to be located, thus limiting the search that has to be conducted in
see2ing that information. %he 2nowledge base can also be quite comple0, such as an interrelated list of
all ma$or possible defects in a materials inspection problem or an image database containing high+
resolution satellite images of a region in connection with change+detection applications. In addition to
guiding the operation of each processing module, the 2nowledge base also controls the interaction
between the modules.
.6 Components of an Image Processing "stem
/ns:
With reference to sensing, two elements are required to acquire digital images. %he first is a ph"sical
device that is sensitive to the energ" radiated b" the ob$ect we wish to image. %he second, called a
digiti&er, is a device for converting the output of the ph"sical sensing device into digital form. 9or
instance, in a digital video camera, the sensors produce an electrical output proportional to light
intensit". %he digiti&er converts these outputs to digital data. peciali&ed image processing hardware
usuall" consists of the digiti&er $ust mentioned plus hardware that performs other primitive operations
such as an arithmetic logic unit 5/:;6, which performs arithmetic and logical operations in parallel on
entire images. %his t"pe of hardware sometimes is called a from+end subs"stem, and its most
distinguishing characteristic is speed. In other words, this unit performs functions that require fast data
throughputs 5e.g., digiti&ing and averaging video images at )* frames ( s6 that the t"pical main
computer cannot handle.6
%he computer in an image processing s"stem is general+purpose computer and can range from a PC to
a supercomputer. oftware for image processing consists of speciali&ed modules that perform specific
tas2s. / well+designed pac2age also includes the capabilit" for the user to write code that, as a
minimum, utili&es the speciali&ed modules. More sophisticated software pac2ages allow the integration
of those modules and general+purpose software commands from at least one computer language.
Mass storage capabilit" is a must in image processing applications. /n image of si&e 1*<=>1*<=
pi0els, in which the intensit" of each pi0el is an ?+bit quantit", requires one megab"te of storage space
if the image is not compressed. When dealing with thousands, or even millions, of images, providing
adequate storage in an image processing s"stem can be a challenge. 7igital storage for image
processing applications falls into three principal categories: 516 short+term storage for use during
processing. 5<6 #n+line storage for relativel" fast re+call, and 5)6 archival storage, characteri&ed b"
infrequent access. torage is measured in b"tes 5eight bits6, 8b"tes 5one thousand b"tes6, Mb"tes 5one
million b"tes6, -b"tes 5meaning giga, or one billion, b"tes6, and %b"tes 5meaning tera, or one trillion,
b"tes6. Image displa"s in use toda" are mainl" color 5preferabl" flat screen6 %' monitors. Monitors are
driven b" the outputs of image and graphics displa" cards that are an integral part of the computer
s"stem. eldom are there requirements for image displa" applications that cannot be met b" displa"
cards available commerciall" as part of the computer s"stem. In some cases, it is necessar" to have
stereo displa"s, and these are implemented in the form of headgear containing two small displa"s
embedded in goggles worn b" the user. 4ardcop" devices for recording images include laser printers,
film camera, heat+sensitive devices, in2$et units, and digital units, such as optical and C7+!#M dis2s.
9ilm provides the highest possible resolution, but paper is the obvious medium of choice for written
material. 9or presentations, images are displa"ed on film transparencies or in a digital medium if image
pro$ection equipment is used. %he latter approach is gaining acceptance as the standard for image
presentations.
,etwor2ing is almost a default function in an" computer s"stem in use toda". .ecause of the large
amount of data inherent in image processing applications, the 2e" consideration in image transmission
is bandwidth. In dedicated networ2s, this t"picall" is not a problem, but communications with remote
sites via the Internet are not alwa"s as efficient. 9ortunatel", this situation is improving quic2l" as a
result of optical fiber and other broadband technologies.
<. @0plain the following:
/6 :ight and the @lectromagnetic pectrum
/ns:
In 1AAA, ir Isaac ,ewton discovered that when a beam of sunlight is passed through a glass prism,
the emerging beam of light is not white but consists instead of a continuous spectrum of colors ranging
from violet at one end to red at the other. %he range of colors we perceive in visible light represents a
ver" small portion of the electromagnetic spectrum. #n one end of the spectrum are radio waves with
wavelengths billions of times longer than those of visible light. /t the other end of the spectrum are
gamma ra"s with wavelengths millions of times smaller than those of visible light.
%he electromagnetic spectrum can be e0pressed in terms of wavelength, frequenc", or energ".
Wavelength 5B6 and frequenc" 5C6 are related b" the e0pression
B D c ( C 5<.)+16
where c is the speed of light 5<.EE?F1*? m(s6.%he energ" of the various components of the
electromagnetic spectrum is given b" the e0pression
@ Dh C 5<.)+<6
where h is Planc2Gs constant. %he units of wavelength are meters, with the terms microns 5denoted Hm
and equal to 1*IA m6 and nanometers 51*IE m6 being used frequentl". 9requenc" is measured in 4ert&
54&6, with one 4ert& being equal to one c"cle of a sinusoidal wave per second.
:ight is a particular t"pe of electromagnetic radiation that can be seen and sensed b" the human e"e.
%he visible band of the electromagnetic spectrum spans the range from appro0imatel" *.=) Hm 5violet6
to about *.JE Hm 5red6.9or convenience, the color spectrum is divided into si0 broad regions: violet,
blue, green, "ellow, orange, and red. ,o color 5or other component of the electromagnetic spectrum6
ends abruptl", but rather each range blends smoothl" into the ne0t. %he colors that humans perceive in
an ob$ect are determined b" the nature of the light reflected from the ob$ect. / bod" that reflects light
and is relativel" balanced in all visible wavelengths appears white to the observer. 4owever, a bod"
that favors reflectance in a limited range of the visible spectrum e0hibits some shades of color. 9or
e0ample, green ob$ects reflect light with wavelengths primaril" in the K** to KJ* nm range while
absorbing most of the energ" at other wavelengths. :ight that is void of color is called achromatic or
monochromatic light. %he onl" attribute of such light is its intensit", or amount. %he term gra" level is
generall" used to describe monochromatic intensit" because it ranges from blac2, to gra"s, and finall"
to white. Chromatic light spans the electromagnetic energ" spectrum from appro0imatel" *.=) to *.JE
Hm, as noted previousl". %hree basic quantities areused to describe the qualit" of a chromatic light
source: radianceL luminanceL and brightness. !adiance is the total amount of energ" that flows from the
light source, and it is usuall" measured in watts 5W6. :uminance, measured in lumens 5lm6, gives a
measure of the amount of energ" an observer perceives from a light source. 9or e0ample, light emitted
from a source operating in the far infrared region of the spectrum could have significant energ"
5radiance6, but an observer would hardl" perceive itL its luminance would be almost &ero.
/t the short+wavelength end of the electromagnetic spectrum, we have gamma ra"s and hard >+ra"s.
-amma radiation is important for medical and astronomical imaging, and for imaging radiation in
nuclear environments. 4ard 5high+energ"6 >+ra"s are used in industrial applications. Moving still higher
in wavelength, we encounter the infrared band, which radiates heat, a fact that ma2es it useful in
imaging applications that rel" on 1heat signatures.3 %he part of the infrared band close to the visible
spectrum is called the near+infrared region. %he opposite end of this band is called the far+infrared
region. %his latter region blends with the microwave band. %his band is well 2nown as the source of
energ" in microwave ovens, but it has man" other uses, including communication and radar. 9inall",
the radio wave band encompasses television as well as /M and 9M radio. In the higher energies, radio
signals emanating from certain stellar bodies are useful in astronomical observations.
.6 Image ensing and /cquisition
/ns:
%he t"pes of images are generated b" the combination of an 1illumination3 source and the reflection or
absorption of energ" from that source b" the elements of the 1scene3 being imaged. 9or e0ample, the
illumination ma" originate from a source of electromagnetic energ" such as radar, infrared, or >+ra"
energ". .ut, as noted earlier, it could originate from less traditional sources, such as ultrasound or even
a computer+generated illumination pattern. imilarl", the scene elements could be familiar ob$ects, but
the" can $ust as easil" be molecules, buried roc2 formations, or a human brain. We could even image a
source, such as acquiring images of the sun. 7epending on the nature of the source, illumination
energ" is reflected from, or transmitted through, ob$ects. /n e0ample in the first categor" is light
reflected from a planar surface. /n e0ample in the second categor" is when >+ra"s pass through a
patientGs bod" for the purpose of generating a diagnostic >+ra" film. In some applications, the reflected
or transmitted energ" is focused onto a photo converter 5e.g., a phosphor screen6, which converts the
energ" into visible light.
a principal sensor arrangement used to transform illumination energ" into digital images. Incoming
energ" is transformed into a voltage b" the combination of input electrical power and sensor material
that is responsive to the particular t"pe of energ" being detected. %he output voltage waveform is the
response of the sensor5s6, and a digital quantit" is obtained from each sensor b" digiti&ing its response.
In this section, we loo2 at the principal modalities for image sensing and generation.
2-4-1 !mae Ac.uisition usin a Sinle Sensor
the components of a single sensor. %he most common sensor of this t"pe is the photodiode, which is
constructed of silicon materials and whose output voltage waveform is proportional to light. %he
use of a filter in front of a sensor improves selectivit". 9or e0ample, a green 5pass6 filter in front of a
light sensor favors light in the green band of the color spectrum. /s a consequence, the sensor output
will be stronger for green light than for other components in the visible spectrum.In order to generate a
<+7 image using a single sensor, there have to be relative displacements in both the 0+ and "+directions
between the sensor and the area to be imaged. an arrangement used in highprecision scanning, where
a film negative is mounted onto a drum whose mechanical rotation provides displacement in one
dimension. %he single sensor is mounted on a lead screw that provides motion in the perpendicular
direction. ince mechanical motion can be controlled with high precision, this method is an ine0pensive
5but slow6 wa" to obtain high+resolution images. #ther similar mechanical arrangements use a flat bed,
with the sensor moving in two linear directions. %hese t"pes of mechanical digiti&ers sometimes are
referred to as microdensitometers. /nother e0ample of imaging with a single sensor places a laser
source coincident with the sensor. Moving mirrors are used to control the outgoing beam in a scanning
pattern and to direct the reflected laser signal onto the sensor.
2-4-2 !mae Ac.uisition usin Sensor Strips
/ geometr" that is used much more frequentl" than single sensors consists of an in+line arrangement of
sensors in the form of a sensor strip. %he strip provides imaging elements in one direction. Motion
perpendicular to the strip provides imaging in the other direction %his is the t"pe of arrangement used in
most flat bed scanners. ensing devices with =*** or more in+line sensors are possible. In+line sensors
are used routinel" in airborne imaging applications, in which the imaging s"stem is mounted on an
aircraft that flies at a constant altitude and speed over the geographical area to be imaged. #ne+
dimensional imaging sensor strips that respond to various bands of the electromagnetic spectrum are
mounted perpendicular to the direction of flight. %he imaging strip gives one line of an image at a time,
and the motion of the strip completes the other dimension of a two+dimensional image. :enses or other
focusing schemes are used to pro$ect the area to be scanned onto the sensors. ensor strips mounted
in a ring configuration are used in medical and industrial imaging to obtain cross+sectional 51slice36
images of )+7 ob$ects. / rotating >+ra" source provides illumination and the portion of the sensors
opposite the source collect the >+ra" energ" that pass through the ob$ect 5the sensors obviousl" have
to be sensitive to >+ra" energ"6.%his is the basis for medical and industrial computeri&ed a0ial
tomograph" 5C/%6 imaging. It is important to note that the output of the sensors must be processed b"
reconstruction algorithms whose ob$ective is to transform the sensed data into meaningful cross+
sectional images.
2-4-/ !mae Ac.uisition usin Sensor Arra0s
Individual sensors can be arranged in the form of a <+7 arra". ,umerous electromagnetic and some
ultrasonic sensing devices are arranged frequentl" in an arra" format. %his is also the predominant
arrangement found in digital cameras. / t"pical sensor for these cameras is a CC7 arra", which can be
manufactured with a broad range of sensing properties and can be pac2aged in rugged arra"s of =***
F =*** elements or more. CC7 sensors are used widel" in digital cameras and other light sensing
instruments. %he response of each sensor is proportional to the integral of the light energ" pro$ected
onto the surface of the sensor, a propert" that is used in astronomical and other applications requiring
low noise images.
%he first function performed b" the imaging s"stem is to collect the incoming energ" and focus it onto
an image plane. If the illumination is light, the front end of the imaging s"stem is a lens, which pro$ects
the viewed scene onto the lens focal plane. %he sensor arra", which is coincident with the focal plane,
produces outputs proportional to the integral of the light received at each sensor. 7igital and analog
circuitr" sweeps these outputs and converts them to a video signal, which is then digiti&ed b" another
section of the imaging s"stem. %he output is a digital image.
). @0plain the following with respect to .asic concepts in ampling and Muanti&ation:
/6 !epresentation of 7igital Images
/ns:
%he result of sampling and quanti&ation is a matri0 of real numbers. We will use two principal wa"s in
this boo2 to represent digital images. /ssume that an image f50, "6 is sampled so that the resulting
digital image has M rows and , columns. %he values of the coordinates 50, "6 now become discrete
quantities. 9or notational clarit" and convenience, we shall use integer values for these discrete
coordinates. %hus, the values of the coordinates at the origin are 50, "6D5*, *6.%he ne0t coordinate
values along the first row of the image are represented as 50, "6D5*, 16. It is important to 2eep in mind
that the notation 5*, 16 is used to signif" the second sample along the first row.
%he notation used above allows us to write the complete MF, digital image in the following compact
matri0 form:
%he right side of this equation is b" definition a digital image. @ach element of this matri0 arra" is called
an image element, picture element, pixel, or pel. In some discussions, it is advantageous to use a more
traditional matri0 notation to denote a digital image and its elements:
Clearl", ai$ D f50Di, "D$6 D f5i, $6, so the above two matrices are identical matrices.
@0pressing sampling and quanti&ation in more formal mathematical terms can be useful at times. :et Z
and R denote the set of real integers and the set of real numbers, respectivel". %he sampling process
ma" be viewed as partitioning the 0" plane into a grid, with the coordinates of the center of each grid
being a pair of elements from the Cartesian product N<, which is the set of all ordered pairs of elements
/&i, &$ ., with &i and &$ being integers from Z. 4ence, f50, "6 is a digital image if 50, "6 are integers from
N< and f is a function that assigns a gra"+level value 5that is, a real number from the set of real
numbers, R6 to each distinct pair of coordinates 50, "6. %his functional assignment obviousl" is the
quanti&ation process described earlier. If the gra" levels also are integers 5as usuall" is the case in this
and subsequent chapters6, Z replaces R, and a digital image then becomes a <+7 function whose
coordinates and amplitude values are integers.
%his digiti&ation process requires decisions about values for M, ,, and for the number, :, of discrete
gra" levels allowed for each pi0el. %here are no requirements on M and N, other than that the" have to
be positive integers. 4owever, due to processing, storage, and sampling hardware considerations, the
number of gra" levels t"picall" is an integer power of <:
12 2% 5@quation 16
We assume that the discrete levels are equall" spaced and that the" are integers in the interval O*, :+1P.
ometimes the range of values spanned b" the gra" scale is called the dynamic range of an image,
and we refer to images whose gra" levels span a significant portion of the gra" scale as having a high
d"namic range. When an appreciable number of pi0els e0hibit this propert", the image will have high
contrast. Conversel", an image with low d"namic range tends to have a dull, washed out gra" loo2. %he
number, b, of bits required to store a digiti&ed image is
32M454%- 5@quation <6
When MD,, this equation becomes 3 2 52%- 5@quation )6
.6 patial and -ra"+:evel !esolution
/ns:
ampling is the principal factor determining the spatial resolution of an image. .asicall", spatial
resolution is the smallest discernible detail in an image. uppose that we construct a chart with vertical
lines of width W and with the space between the lines also having width W. / line pair consists of one
such line and its ad$acent space. %hus, the width of a line pair is <W, and there are 1(<W line pairs per
unit distance. / widel" used definition of resolution is simpl" the smallest number of discernible line
pairs per unit distanceL for e0ample, 1** line pairs per millimeter. Gray-level resolution similarl" refers
to the smallest discernible change in gra" level, but, measuring discernible changes in gra" level is a
highl" sub$ective process. We have considerable discretion regarding the number of samples used to
generate a digital image, but this is not true for the number of gra" levels. 7ue to hardware
considerations, the number of gra" levels is usuall" an integer power of <, as mentioned in the previous
section. %he most common number is ? bits, with 1A bits being used in some applications where
enhancement of specific gra"+level ranges is necessar". ometimes we find s"stems that can digiti&e
the gra" levels of an image with 1* or 1< bits of accurac", but these are e0ceptions rather than the rule.
When an actual measure of ph"sical resolution relating pi0els and the level of detail the" resolve in the
original scene are not necessar", it is not uncommon to refer to an :+level digital image of si&e MF, as
having a will use this terminolog" from time to time in subsequent discussions, ma2ing a reference to
actual resolvable detail onl" when necessar" for clarit". an image of si&e 1*<=F1*<= pi0els whose gra"
levels are represented b" ? bits. %he results of subsampling the 1*<=F1*<= image. %he subsampling
was accomplished b" deleting the appropriate number of rows and columns from the original image.
9or e0ample, the K1<FK1< image was obtained b" deleting ever" other row and column from the
1*<=F1*<= image. %he <KAF<KA image was generated b" deleting ever" other row and column in the
K1<FK1< image, and so on. %he number of allowed gra" levels was 2ept at <KA. %hese images show
the dimensional proportions between various sampling densities, but their si&e differences ma2e it
difficult to see the effects resulting from a reduction in the number of samples. %he simplest wa" to
compare these effects is to bring all the subsampled images up to si&e 1*<=F1*<= b" row and column
pi0el replication.
C6 /liasing and MoirQ Patterns
/ns:
9unctions whose area under the curve is finite can be represented in terms of sines and cosines of
various frequencies. %he sine(cosine component with the highest frequenc" determines the highest
1frequenc" content3 of the function. uppose that this highest frequenc" is finite and that the function is
of unlimited duration 5these functions are called band-limited functions6, then, the hannon sampling
theorem tells us that, if the function is sampled at a rate equal to or greater than twice its highest
frequenc", it is possible to recover completel" the original function from its samples. If the function is
undersampled, then a phenomenon called aliasing corrupts the sampled image. %he corruption is in the
form of additional frequenc" components being introduced into the sampled function. %hese are called
aliased frequencies. ,ote that the sampling rate in images is the number of samples ta2en 5in both
spatial directions6 per unit distance. /s it turns out, e0cept for a special case discussed in the following
paragraph, it is impossible to satisf" the sampling theorem in practice. We can onl" wor2 with sampled
data that are finite in duration. We can model the process of converting a function of unlimited duration
into a function of finite duration simpl" b" multipl"ing the unlimited function b" a 1gating function3 that is
valued 1 for some interval and * elsewhere. ;nfortunatel", this function itself has frequenc"
components that e0tend to infinit". %hus, the ver" act of limiting the duration of a band+limited function
causes it to cease being band limited, which causes it to violate the 2e" condition of the sampling
theorem. %he principal approach for reducing the aliasing effects on an image is to reduce its high+
frequenc" components b" blurring the image prior to sampling. 4owever, aliasing is alwa"s present in a
sampled image. %he effect of aliased frequencies can be seen under the right conditions in the form of
so called Moir patterns.
76 Nooming and hrin2ing 7igital Images.
/ns:
We conclude the treatment of sampling and quanti&ation with a brief discussion on how to &oom and
shrin2 a digital image. %his topic is related to image sampling and quanti&ation because &ooming ma"
be viewed as oversampling, while shrin2ing ma" be viewed as undersampling. %he 2e" difference
between these two operations and sampling and quanti&ing an original continuous image is that
&ooming and shrin2ing are applied to a digital image. Nooming requires two steps: the creation of new
pi0el locations, and the assignment of gra" levels to those new locations. :et us start with a simple
e0ample. uppose that we have an image of si&e K**FK** pi0els and we want to enlarge it 1.K times to
JK*FJK* pi0els. Conceptuall", one of the easiest wa"s to visuali&e &ooming is la"ing an imaginar"
JK*FJK* grid over the original image. #bviousl", the spacing in the grid would be less than one pi0el
because we are fitting it over a smaller image. In order to perform gra"+level assignment for an" point in
the overla", we loo2 for the closest pi0el in the original image and assign its gra" level to the new pi0el
in the grid. When we are done with all points in the overla" grid, we simpl" e0pand it to the original
specified si&e to obtain the &oomed image. %his method of gra"+level assignment is called nearest
neighbor interpolation.
Pi0el replication is applicable when we want to increase the si&e of an image an integer number of
times.
9or instance, to double the si&e of an image, we can duplicate each column. %his doubles the image
si&e in the hori&ontal direction. %hen, we duplicate each row of the enlarged image to double the si&e in
the vertical direction. %he same procedure is used to enlarge the image b" an" integer number of times
5triple, quadruple, and so on6. 7uplication is $ust done the required number of times to achieve the
desired si&e. %he gra"+level assignment of each pi0el is predetermined b" the fact that new locations
are e0act duplicates of old locations. / slightl" more sophisticated wa" of accomplishing gra"+level
assignments is bilinear interpolation using the four nearest neighbors of a point. :et 50G, "G6 denote the
coordinates of a point in the &oomed image, and let v50G, "G6 denote the gra" level assigned to it. 9or
bilinear interpolation, the assigned gra" level is given b"
where the four coefficients are determined from the four equations in four un2nowns that can be written
using the four nearest neighbors of point 50G, "G6. Image shrin2ing is done in a similar manner as $ust
described for &ooming. %he equivalent process of pi0el replication is row+column deletion. 9or e0ample,
to shrin2 an image b" one+half, we delete ever" other row and column. We can use the &ooming grid
analog" to visuali&e the concept of shrin2ing b" a noninteger factor, e0cept that we now expand the grid
to fit over the original image, do gra"+level nearest neighbor or bilinear interpolation, and then shrin2 the
grid bac2 to its original specified si&e. %o reduce possible aliasing effects, it is a good idea to blur an
image slightl" before shrin2ing it.
=. @0plain the following with respect to Image @nhancement:
/6 @dge Crispening
/ns:
Ps"choph"sical e0periments indicate that a photograph or visual signal with accentuated or crispened
edges is often more sub$ectivel" pleasing than an e0act photometric reproduction. We will discuss
:inear and tatistical differencing technique for edge crispening.
4-6-1 1inear (#e Crispenin
@dge crispening can be performed b" discrete convolution, as defined b" @q. =.? in which the impulse
response arra" is of high+pass form. everal common high+pass mas2s are given below
%hese mas2s possess the propert" that the sum of their elements is unit", to avoid amplitude bias in
the processed image.
4-6-2 Statistical Differencin tatistical differencing involves the generation of an image b" dividing
each pi0el value b" its estimated standard deviation !5 ", #6 according to the basic relation G5 ", #6 D $5 ",
#6 ( !5 ", #6 where the estimated standard deviation
is computed at each pi0el over some W F W neighborhood where W D <% R 1. %he function M5$,26 is the
estimated mean value of the original image at point 5", #6, which is computed as
%he enhanced image -5$,26 is increased in amplitude with respect to the original at pi0els that deviate
significantl" from their neighbors, and is decreased in relative amplitude elsewhere.
.6 Color Image @nhancement:
/ns:
%he image enhancement techniques discussed previousl" have all been applied to monochrome
images. We will now consider the enhancement of natural color images and introduce the pseudocolor
and false color image enhancement methods. Pseudocolor produces a color image from a
monochrome image, while false color produces an enhanced color image from an original natural color
image or from multispectral image bands.
4-6-1 5atural Color !mae (n*ancement %he monochrome image enhancement methods described
previousl" can be applied to natural color images b" processing each color component individuall". It is
accomplished b" intracomponent and inter+component processing algorithms. Intracomponent
Processing: %"picall", color images are processed in the !-. color space. %his approach wor2s quite
well for noise cleaning algorithms in which the noise is independent between the !, - and .
components. @dge crispening can also be performed on an intracomponent basis, but more efficient
results are often obtained b" processing in other color spaces. Contrast manipulation and histogram
modification intracomponent algorithms often result in severe shifts of the hue and saturation of color
images. 4ue preservation can be achieved b" using a single point transformation for each of the three
!-. components. 9or e0ample, form a sum image, and then compute a histogram equali&ation
function, which is used for each !-. component.
Intercomponent Processing: %he intracomponent processing algorithms previousl" discussed provide
no means of modif"ing the hue and saturation of a processed image in a controlled manner. #ne
means of doing so is to transform a source !-. image into a three component image, in which the
three components form separate measures of the brightness, hue and saturation 5.46 of a color
image. Ideall", the three components should be perceptuall" independent of one another.
4-6-2 "seu#ocolor
Pseudocolor is a color mapping of a monochrome image arra" which is intended to enhance the
detectabilit" of detail within the image. %he pseudocolor mapping of an arra" is defined as
!5$, 26 D #!S95$, 26T
-5$, 26 D #-S95$, 26T
.5$, 26 D #.S95$, 26T
where !5$, 26 , -5$, 26, .5$, 26 are displa" color components and #!S95$, 26T, #-S95$, 26T, #.S95$, 26T are
linear or nonlinear functional operators. %his mapping defines a path in three+dimensional color space
parametricall" in terms of the arra" 95$, 26. Mapping / represents the achromatic path through all
shades of gra"Lit is the normal representation of a monochrome image. Mapping . is a spiral path
through color space. /nother class of pseudocolor mappings includes those mappings that e0clude all
shades of gra". Mapping C, which follows the edges of the !-. color cube, is such an e0ample.
4-6-/ ,alse color
9alse color is a point+b"+point mapping of an original color image. It is described b" its three primar"
colors 5or of a set of multispectral image planes of a scene6 to a color space defined b" displa"
tristimulus values that are linear or nonlinear functions of the original image pi0el values. / common
intent is to provide a displa"ed image with ob$ects possessing different or false colors from what might
be e0pected. 9or e0ample, blue s2" in a normal scene might be converted to appear red, and green
grass transformed to blue. #ne possible reason for such a color mapping is to place normal ob$ects in a
strange color world so that a human observer will pa" more attention to the ob$ects than if the" were
colored normall".
/nother reason for false color mappings is the attempt to color a normal scene to match the color
sensitivit" of a human viewer. 9or e0ample, it is 2nown that the luminance response of cones in the
retina pea2s in the green region of the visible spectrum. %hus, if a normall" red ob$ect is false colored to
appear green, it ma" become more easil" detectable. /nother ps"choph"sical propert" of color vision
that can be e0ploited is the contrast sensitivit" of the e"e to changes in blue light. In some situations it
ma" be worthwhile to map the normal colors of ob$ects with fine detail into shades of blue.
In a false color mapping, the red, green and blue displa" color components are related to natural or
multispectral images 9i b"
!7 D #!S91, 9<,....T
-7 D #-S 91, 9<, ....T
.7 D #.S 91, 9<,...T
where #!S U T, #-S U T, #.S U T are general functional operators. /s a simple e0ample, the set of red,
green and blue sensor tristimulus values 5! D 91, - D 9<, . D 9) 6 ma" be interchanged according
to the relation.
C6 Multispectral Image @nhancement
/ns:
of a scene in order to accentuate salient features to assist in subsequent human interpretation or
machine anal"sis. %hese procedures include individual image band enhancement techniques, such as
contrast stretching, noise cleaning and edge crispening, as discussed earlier. #ther methods involve
the $oint processing of multispectral image bands. Multispectral image bands can be subtracted in pairs
according to the relation
!m, n5", #6 D $m5 ", #6 I $n5 ", #6
in order to accentuate reflectivit" variations between the multispectral bands. /n associated advantage
is the removal of an" un2nown but common bias components that ma" e0ist. /nother simple but highl"
effective means of multispectral image enhancement is the formation of ratios of the image bands. %he
ratio image between the mth and nth multispectral bands is defined as
Rm&n '"& #( ) $m'"&#( *$n'"&#(
It is assumed that the image bands are ad$usted to have non&ero pi0el values. In man" multispectral
imaging s"stems, the image band 9n5 $, 26 can be modeled b" the product of an ob$ect reflectivit"
function !n5 $, 26 and an illumination function I5$, 26 that is identical for all multispectral bands. !atioing
of such imager" provides an automatic compensation of the illumination factor. %he ratio 9m5$, 26 ( O9n5$,
26 V W5$, 26P for which W5$, 26 represents a quanti&ation level uncertaint", can var" considerabl" if 9n5$, 26
is small. %his variation can be reduced significantl" b" forming the logarithm of the ratios defined b"
+mn"#D logRmn"#D log$m"#I log$n"#
K. 7escribe the following with respect to Image restoration:
/6 -eneral Image !estoration Models
/ns:
In order to effectivel" design a digital image restoration s"stem, it is necessar" quantitativel" to
characteri&e the image degradation effects of the ph"sical imaging s"stem, the image digiti&er and the
image displa". .asicall", the procedure is to model the image degradation effects and then perform
operations to undo the model to obtain a restored image. It should be emphasi&ed that accurate image
modeling is often the 2e" to effective image restoration. %here are two basic approaches to the
modeling of image degradation effects: a priori modeling and a posteriori modeling.
In the former case, measurements are made on the ph"sical imaging s"stem, digiti&er and displa" to
determine their response to an arbitrar" image field. In some instances, it will be possible to model the
s"stem response deterministicall", while in other situations it will onl" be possible to determine the
s"stem response in a stochastic sense. %he posteriori modeling approach is to develop the model for
the image degradations based on measurements of a particular image to be restored.
.asicall", these two approaches differ onl" in the manner in which information is gathered to describe
the character of the image degradation is a general model of a digital imaging s"stem and restoration
process. In the model, a continuous image light distribution ,'x,y,t,6 dependent on spatial coordinates
5x, y6, time 5t6 and spectral wavelength 56 is assumed to e0ist as the driving force of a ph"sical imaging
s"stem sub$ect to point and spatial degradation effects and corrupted b" deterministic and stochastic
disturbances. Potential degradations include diffraction in the optical s"stem, sensor nonlinearities,
optical s"stem aberrations, film nonlinearities, atmospheric turbulence effects, image motion blur and
geometric distortion. ,oise disturbances ma" be caused b" electronic imaging sensors or film
granularit". In this model, the ph"sical imaging s"stem produces a set of output image fields 9# 5i6' x &y
&t " 6 at time instant t " described b" the general relation
where 7" 8 - 9 represents a general operator that is dependent on the space coordinates 5x, y6, the time
histor" 5t6, the wavelength 56 and the amplitude of the light distribution 5,6. 9or a monochrome imaging
s"stem, there will onl" be a single output field, while for a natural color imaging s"stem, 9# 5i6' x &y &t " 6
ma" denote the red, green and blue tristimulus bands for i D 1, <, ), respectivel". Multispectral imager"
will also involve several output bands of data.
.6 #ptical s"stem Models
/ns:
#ne of the ma$or advances in the field of optics during the past K* "ears has been the application of
s"stem concepts to optical imaging. Imaging devices consisting of lenses, mirrors, prisms and so on,
can be considered to provide a deterministic transformation of an input spatial light distribution to some
output spatial light distribution. /lso, the s"stem concept can be e0tended to encompass the spatial
propagation of light through free space or some dielectric medium.
In the stud" of geometric optics, it is assumed that light ra"s alwa"s travel in a straight+line path in a
homogeneous medium. ." this assumption, a bundle of ra"s passing through a clear aperture onto a
screen produces a geometric light pro$ection of the aperture. 4owever, if the light distribution at the
region between the light and dar2 areas on the screen is e0amined in detail, it is found that the
boundar" is not sharp. %his effect is more pronounced as the aperture si&e is decreased. 9or a pinhole
aperture, the entire screen appears diffusel" illuminated. 9rom a simplistic viewpoint, the aperture
causes a bending of ra"s called diffraction. 7iffraction of light can be quantitativel" characteri&ed b"
considering light as electromagnetic radiation that satisfies Ma0wellXs equations. %he formulation of a
complete theor" of optical imaging from the basic electromagnetic principles of diffraction theor" is a
comple0 and length" tas2.
C6 Photographic Process Models
/ns:
%here are man" different t"pes of materials and chemical processes that have been utili&ed for
photographic image recording. ,o attempt is made here either to surve" the field of photograph" or to
deepl" investigate the ph"sics of photograph". !ather, the attempt here is to develop mathematical
models of the photographic process in order to characteri&e quantitativel" the photographic
components of an imaging s"stem.
6-4-1 Monoc*romatic "*otorap*0
%he most common material for photographic image recording is silver halide emulsion, depicted .In this
material, silver halide grains are suspended in a transparent la"er of gelatin that is deposited on a
glass, acetate or paper bac2ing. If the bac2ing is transparent, a transparenc" can be produced, and if
the bac2ing is a white paper, a reflection print can be obtained. When light stri2es a grain, an
electrochemical conversion process occurs, and part of the grain is converted to metallic silver. /
development center is then said to e0ist in the grain. In the development process, a chemical
developing agent causes grains with partial silver content to be converted entirel" to metallic silver.
,e0t, the film is fi0ed b" chemicall" removing une0posed grains. %he photographic process described
above is called a nonreversal process. It produces a negative image in the sense that the silver densit"
is inversel" proportional to the e0posing light. / positive reflection print of an image can be obtained in
a two+stage process with nonreversal materials. 9irst, a negative transparenc" is produced, and then
the negative transparenc" is illuminated to e0pose negative reflection print paper. %he resulting silver
densit" on the developed paper is then proportional to the light intensit" that e0posed the negative
transparenc". / positive transparenc" of an image can be obtained with a reversal t"pe of film.
6-4-2 Color "*otorap*0
Modern color photograph" s"stems utili&e an integral tripac2 film, as to produce positive or negative
transparencies. In a cross section of this film, the first la"er is a silver halide emulsion sensitive to blue
light. / "ellow filter following the blue emulsion prevents blue light from passing through to the green
and red silver emulsions that follow in consecutive la"ers and are naturall" sensitive to blue light. /
transparent base supports the emulsion la"ers. ;pon development, the blue emulsion la"er is
converted into a "ellow d"e transparenc" whose d"e concentration is proportional to the blue e0posure
for a negative transparenc" and inversel" proportional for a positive transparenc". imilarl", the green
and red emulsion la"ers become magenta and c"an d"e la"ers, respectivel".
Color prints can be obtained b" a variet" of processes. %he most common technique is to produce a
positive print from a color negative transparenc" onto nonreversal color paper. In the establishment of a
mathematical model of the color photographic process, each emulsion la"er can be considered to react
to light as does an emulsion la"er of a monochrome photographic material. %o a first appro0imation,
this assumption is correct. 4owever, there are often significant interactions between the emulsion and
d"e la"ers. @ach emulsion la"er possesses a characteristic sensitivit",
A. 7escribe the following in the conte0t of Morphological Image processing:
/6 .asic operations
/ns:
%he foundation of morphological processing is in the mathematicall" rigorous field of set theory- We will
discuss some fundamental concepts of image set algebra which are the basis for defining the
generali&ed dilation and erosions operators. Consider a binar"+valued source image function 95$, 26. /
pi0el at coordinate 5$, 26 is a member of 95$, 26, as indicated b" the s"mbol , if and onl" if it is a logical 1.
/ binar"+valued image .5$, 26 is a subset of a binar"+valued image /5$,26, as indicated b" .5$,26 /5$,26, if
for ever" spatial occurrence of a logical 1 of /5$, 26, .5$, 26 is a logical 1.
/ reflected image 9Y5 $, 26 is an image that has been flipped from left to right
and from top to bottom. this provides an e0ample of image
complementation. %ranslation of an image, as indicated b" the function
G " # D .r c $ " #
consists of spatiall" offsetting 95 $, 26 with respect to itself b" r rows and c
columns, where IRZ r Z R and I, Z c Z ,-
6-2-1 Dilation
With dilation, an ob$ect grows uniforml" in spatial e0tent. -enerali&ed
dilation is e0pressed s"mbolicall" as
G " # D $ " # " #
where 95$, 26, for 1 Z $, 2Z , is a binar"+valued image and 45$, 26 for , 1 Z $,
2Z :, where : is an odd integer, is a binar"+valued arra" called a structuring
element. 9or notational simplicit", 95$,26 and 45$,26 are assumed to be
square arra"s. -enerali&ed dilation can be defined mathematicall" and
implemented in several wa"s. %he Min2ows2i addition definition is
6-2-2 (rosion With erosion an ob$ect shrin2s uniforml". Generali/ed erosion is e0pressed s"mbolicall"
as
G"#D $"#[ "#where 45$,26
is an odd si&e : F : structuring element. -enerali&ed erosion is defined to be
6-2-/ "roperties of Dilation an# (rosion
i. 7ilation is commutative:
0 1 2 1 0
but in general, erosion is not commutative.
0 [ 1 2 1 [ 0
ii. 7ilation and erosion are opposite in effectL dilation of the bac2ground of an ob$ect behaves li2e
erosion of the ob$ect. %his statement can be quantified b" the dualit" relationship.
6-2-4 Close an# 7pen 7ilation and erosion are often applied to an image in concatenation. 7ilation
followed b" erosion is called a close operation. It is e0pressed s"mbolicall" as
G"#D $"#"#where 45$,26 is a : F : structuring element. %he close operation is defined as G"#D $"#"#[
3 "#(
Closing of an image with a compact structuring element without holes 5&eros6, such as a square or
circle, smooths contours of ob$ects, eliminates small holes in ob$ects and fuses short gaps between
ob$ects.
.6 Morphological algorithm operations on gra" scale images
/ns:
Morphological concepts can be e0tended to gra" scale images, but the e0tension often leads to
theoretical issues and to implementation comple0ities. When applied to a binar" image, dilation and
erosion operations cause an image to increase or decrease in spatial e0tent, respectivel". %o
generali&e these concepts to a gra" scale image, it is assumed that the image contains visuall" distinct
gra" scale ob$ects set against a gra" bac2ground. /lso, it is assumed that the ob$ects and bac2ground
are both relativel" spatiall" smooth.
6-6-1 :ra0 Scale !mae Dilation an# (rosion
7ilation or erosion of an image could, in principle, be accomplished b" hit+or+miss transformations in
which the quanti&ed gra" scale patterns are e0amined in a ) F ) window and an output pi0el is
generated for each pattern. %his approach is, however, not computationall" feasible. 9or e0ample, if a
loo2+up table implementation were to be used, the table would require <J<entries for <KA+level
quanti&ation of each pi0el. %he common alternative is to use gra" scale e0tremum operations over a ) F
) pi0el neighborhoods.
Consider a gra" scale image 95$,26 quanti&ed to an arbitrar" number of gra" levels. /ccording to the
e0tremum method of gra" scale image dilation, the dilation operation is defined as
%here M/>S1, ..., ET generates the largest+amplitude pi0el of the nine pi0els in the neighborhood.
." the e0tremum method, gra" scale image erosion is defined as
where MI, S1, ..., ETgenerates the smallest+amplitude pi0el of the nine pi0els in the ) F ) pi0el
neighborhood.
Auust 2010
Master of Computer Application (MCA) Semester 6
MC0086 Diital !mae "rocessin 4 Cre#its
($oo% !D& $100')
Assinment Set 2 (60 Mar%s)
Ans+er all ;uestions (ac* ;uestion carries <(5
1. 7escribe the following te0ture features of Image @0traction:
/6 9ourier pectra Methods
/ns:
everal studies have considered te0tural anal"sis based on the 9ourier spectrum of an image region,
as discussed in ection J.). .ecause the degree of te0ture coarseness is proportional to its spatial
period, a region of coarse te0ture should have its 9ourier spectral energ" concentrated at low spatial
frequencies. Conversel", regions of fine te0ture should e0hibit a concentration of spectral energ" at
high spatial frequencies. /lthough this correspondence e0ists to some degree, difficulties often arise
because of spatial changes in the period and phase of te0ture pattern repetitions. @0periments have
shown that there is considerable spectral overlap of regions of distinctl" different natural te0ture, such
as urban, rural and woodland regions e0tracted from aerial photographs. #n the other hand, 9ourier
spectral anal"sis has proved successful in the detection and classification of coal miner s blac2 lung
disease, which appears as diffuse te0tural deviations from the norm.
.6 @dge 7etection Methods:
/ns:
!osenfeld and %ro" have proposed a measure of the number of edges in a neighborhood as a te0tural
measure. /s a first step in their process, an edge map arra" 45", #6 is produced b" some edge detector
such that 45", #6 D 1 for a detected edge and 45", #6 D * otherwise. ;suall", the detection threshold is set
lower than the normal setting for the isolation of boundar" points. %his te0ture measure is defined as
Where W D <% R 1 is the dimension of the observation window. / variation of this approach is to
substitute the edge gradient G5", #6 for the edge map arra" in @q.A.
C6 /utocorrelation Methods
/ns:
%he autocorrelation function has been suggested as the basis of a te0ture measure. /lthough it has
been demonstrated in the preceding section that it is possible to generate visuall" different stochastic
fields with the same autocorrelation function, this does not necessaril" rule out the utilit" of an
autocorrelation feature set for natural images. %he autocorrelation function is defined as
for computation over a W > W window with + % m, n % pi0el lags. Presumabl", a region of coarse te0ture
will e0hibit a higher correlation for a fi0ed shift than will a region of fine te0ture. %hus, te0ture
coarseness should be proportional to the spread of the autocorrelation function. 9augeras and Pratt
have proposed the following set of autocorrelation spread measures:
<. 7escribe the following features of @dge detection:
/6 @dge, :ine and pot models
/ns:
It is a s2etch of a continuous domain, one+dimensional ramp edge modeled as a ramp increase in
image amplitude from a low to a high level, or vice versa. %he edge is characteri&ed b" its height, slope
angle and hori&ontal coordinate of the slope midpoint. /n edge e0ists if the edge height is greater than
a specified value. /n ideal edge detector should produce an edge indication locali&ed to a single pi0el
located at the midpoint of the slope. If the slope angle of is E*\, the resultant edge is called a step
edge. In a digital imaging s"stem, step edges usuall" e0ist onl" for artificiall" generated images such as
test patterns and bilevel graphics data. 7igital images, resulting from digiti&ation of optical images of
real scenes, generall" do not possess step edges because the antialiasing low+pass filtering prior to
digiti&ation reduces the edge slope in the digital image caused b" an" sudden luminance change in the
scene. %he one+dimensional profile of a line . In the limit, as the line width % approaches &ero, the
resultant amplitude discontinuit" is called a roof edge. %he vertical ramp edge model in the contains a
single transition pi0el whose amplitude is at the midvalue of its neighbors. %his edge model can be
obtained b" performing a < F < pi0el moving window average on the vertical step edge model. %he
figure also contains two versions of a diagonal ramp edge. %he single pi0el transition model contains a
single midvalue transition pi0el between the regions of high and low amplitudeL the smoothed transition
model is generated b" a < F < pi0el moving window average of the diagonal step edge model. presents
models for a discrete step and ramp corner edge. %he edge location for discrete step edges is usuall"
mar2ed at the higher+amplitude side of an edge transition.
.6 9irst+#rder 7erivative @dge 7etection
/ns:
%here are two fundamental methods for generating first+order derivative edge gradients. #ne method
involves generation of gradients in two orthogonal directions in an imageL the second utili&es a set of
directional derivatives. We will be discussing the first method.
8-/-1 7rt*oonal :ra#ient :eneration
/n edge in a continuous domain edge segment 950,"6 can be detected b" forming the continuous one+
dimensional gradient -50,"6 along a line normal to the edge slope, which is at an angle [ with respect
to the hori&ontal a0is. If the gradient is sufficientl" large 5i.e., above some threshold value6, an
edge is deemed present. %he gradient along the line normal to the edge slope can be computed in
terms of the derivatives along orthogonal a0es according to the following
9or computational efficienc", the gradient amplitude is sometimes appro0imated b" the magnitude
combination
%he orientation of the spatial gradient with respect to the row a0is is
%he remaining issue for discrete domain orthogonal gradient generation is to choose a good discrete
appro0imation to the continuous differentials of @q. ?.)a.
%he simplest method of discrete gradient generation is to form the running difference of pi0els along
rows and columns of the image. %he row gradient is defined as
and the column gradient is
7iagonal edge gradients can be obtained b" forming running differences of diagonal pairs of pi0els.
%his is the basis of the !oberts cross+difference operator, which is defined in magnitude form as
and in square+root form as
Prewitt has introduced a pi0el edge gradient operator described b" the pi0el numbering %he Prewitt
operator square root edge gradient is defined as
With
where 5 D 1. In this formulation, the row and column gradients are normali&ed to provide unit+gain
positive and negative weighted averages about a separated edge position.
%he obel operator edge detector differs from the Prewitt edge detector in that the values of the north,
south, east and west pi0els are doubled 5i.e., 8 D <6. %he motivation for this weighting is to give equal
importance to each pi0el in terms of its contribution to the spatial gradient.

C6 econd+#rder 7erivative @dge 7etection
/ns:
econd+order derivative edge detection techniques emplo" some form of spatial second+ order
differentiation to accentuate edges. /n edge is mar2ed if a significant spatial change occurs in the
second derivative. We will consider :aplacian second+order derivative method.
%he edge :aplacian of an image function 950,"6 in the continuous domain is defined as
where, the :aplacian is
%he :aplacian -50,"6 is &ero if 950,"6 is constant or changing linearl" in amplitude. If the rate of change
of 950,"6 is greater than linear, -50,"6 e0hibits a sign change at the point of inflection of 950,"6. %he &ero
crossing of -50,"6 indicates the presence of an edge. %he negative sign in the definition of @q. ?.=a is
present so that the &ero crossing of -50,"6 has a positive slope for an edge whose amplitude increases
from left to right or bottom to top in an image.
%orre and Poggio have investigated the mathematical properties of the :aplacian of an image function.
%he" have found that if 950,"6 meets certain smoothness constraints, the &ero crossings of -50,"6 are
closed curves. In the discrete domain, the simplest appro0imation to the continuous :aplacian is to
compute the difference of slopes along each a0is:
%his four+neighbor :aplacian can be generated b" the convolution operation
Where
%he four+neighbor :aplacian is often normali&ed to provide unit+gain averages of the positive weighted
and negative weighted pi0els in the ) F ) pi0el neighborhood. %he gain+normali&ed four+neighbor
:aplacian impulse response is defined b"
Prewitt has suggested an eight+neighbor :aplacian defined b" the gain normali&ed impulse response
arra"
). 7escribe the following with respect to Image egmentation:
/6 7etection of 7iscontinuities
/ns:
%here are three basic t"pes of discontinuities in a digital image: Points, lines and edges. In practice, the
most common wa" to loo2 for discontinuities is to run a mas2 through the image. 9or the ) 0 ) mas2 .,
this procedure involves computing the sum of products of the coefficients with the gra" levels contained
in the region encompassed b" the mas2. %hat is, the response of the mas2 at an" point in the image
Where is the gra" level of the pi0el associated with mas2 coefficient /s Wi. usual, the response of the
mas2 is defined with respect to its center location. When the mas2 is centered on a boundar" pi0el, the
response is computed b" using the appropriated partial neighbor hood.
=-2-1 "oint Detection
%he detection of isolated points in an image is straightforward. we sa" that a point has been detected
at the location on which the mas2 is centered if
Where % is a nonnegative threshold and ! is the response of the mas2 at an" point in the image.
.asicall" all that this formulation does is measure the weighted differences between the center point
and its neighbors. %he idea is that the gra" level of an isolated point will be quite different from the gra"
level of its neighbors.
=-2-2 1ine Detection
:ine detection is an important step in image processing and anal"sis. :ines and edges are features in
an" scene, from simple indoor scenes to nois" terrain images ta2en b" satellite. Most of the earlier
methods for detecting lines were based on pattern matching. %he patterns directl" followed from the
definition of a line. %hese pattern templates are designed with suitable coefficients and are applied at
each point in an image. / set of such templates is shown in If the first mas2 were moved around an
image, it would respond more strongl" to lines oriented hori&ontall". With constant bac2ground, the
ma0imum response would result when the line passed through the middle row of the mas2. %his is
easil" verified b" s2etching a simple arra" of 1Gs with a line of a different gra" level running hori&ontall"
through the arra". / similar e0periment would reveal that the second mas2 in responds best to lines
oriented at R=KL the third mas2 to vertical linesL and the fourth mas2 to lines in the I =K direction. %hese
directions can also be established b" noting that the preferred direction of each mas2 is weighted with
larger coefficient i.e., < than other possible directions.
:et !1, !<, !) and != denote the responses of the mas2s in from left to right, where the !Gs are given
b" equation E.<. uppose that all mas2s are run through an image. If, at a certain point in the image, for
all $ ] I, that point is said to be more li2el" associated with a line in the direction of mas2 i. 9or e0ample,
if at a point in the image, for $ D <, ), =, that particular point is said to be more li2el" associated with a
hori&ontal line.
=-2-/ (#e Detection
%he most common approach for detecting meaningful discontinuities in gra" level. We discuss
approaches for implementing first+order derivative 5-radient operator6, second+order derivative
5:aplacian operator6.
$asic ,ormulation
/n edge is a set of connected pi0els that lie on the boundar" between two regions. /n edge is a 1local3
concept whereas a region boundar", owing to the wa" it is defined, is a more global idea.
We start b" modeling an edge intuitivel". %his will lead us to formalism in which 1meaningful3 transitions
in gra" levels can be measured.
In practice, optics, sampling, and other acquisition imperfections "ield edges that are blurred, with the
degree of blurring being determined b" factors such as the qualit" of the image acquisition s"stem, the
sampling rate, and illumination conditions under which the image is acquired.
%he slope of the ramp is inversel" proportional to the degree of blurring in the edge. In this model, we
no longer have a thin 5one pi0el thic26 path. Instead, an edge point now is an" point contained in the
ramp, and an edge would then be a set of such points that are connected. %he thic2ness is determined
b" the length of the ramp. %he length is determined b" the slope, which is in turn determined b" the
degree of blurring. .lurred edges tend to be thic2 and sharpL edges tend to be thin.
%he first derivative is positive at the points of transition into and out of the ramp as we move from left to
right along the profileL it is constant for points in the rampL and is &ero in areas of constant gra" level.
%he second derivative is positive at the transition associated with the light side of the edge, and &ero
along the ramp and in areas of constant gra" level. %he following are the two additional properties of
the second derivative around an edge: It produces two values for ever" edge in an image 5an
undesirable feature6 /n imaginar" straight line $oining the e0treme positive and negative values of the
second derivative would cross &ero near the midpoint of the edge 5&ero+crossing propert"6

.6 @dge :in2ing and .oundar" 7etection
/ns:
@dge lin2ing and boundar" detection operations are the fundamental steps in an" image understanding.
@dge lin2ing process ta2es an unordered set of edge pi0els produced b" an edge detector as an input
to form an ordered list of edges. :ocal edge information are utili&ed b" edge lin2ing operationL thus
edge detection algorithms t"picall" are followed b" lin2ing procedure to assemble edge pi0els into
meaningful edges.
=-/-1 1ocal "rocessin
#ne of the simplest approaches of lin2ing edge points is to anal"&e the characteristics of pi0els in a
small neighborhood 5sa", ) 0 ) or K 0 K6 about ever" point 50, "6 in an image that has undergone edge+
detection. /ll points that are similar are lin2ed, forming a boundar" of pi0els that share some common
properties.
%he two principal properties used for establishing similarit" of edge pi0els in this 2ind of anal"sis are 516
the strength of the response of the gradient operator used to produce the edge pi0elL and 5<6 the
direction of the gradient vector. %he first propert" is given b" the value of , the gradient. %hus an edge
pi0el with coordinates in a predefined neighborhood of 50, "6 is similar in magnitude to the pi0el at 50, "6
if
where @ is a non negative threshold
%he direction 5angle6 of the gradient vector is given b". /n edge pi0el at in the predefined neighborhood
of 50, "6 has an angle similar to the pi0el at 50, "6 if
where / is a nonnegative angle threshold. /s noted in E.<.), the direction of the edge at 50, "6 is
perpendicular to the direction of the gradient vector at that point.
/ point in the predefined neighborhood of 50, "6 is lin2ed to the pi0el at 50, "6 if both magnitude and
direction criteria are satisfied. %his process is repeated at ever" location in the image. / record must be
2ept of lin2ed points as the center of the neighborhood is moved from pi0el to pi0el. / simple boo2
2eeping procedure is to assign a different gra" level to each set of lin2ed edge pi0els.
=-/-2 :lo3al "rocessin >ia t*e ?ou* transform
In this section, points are lin2ed b" determining first if the" lie on a curve of specified shape. ;nli2e the
local anal"sis method, we now consider global relationships between pi0els.
uppose that, for n points in an image, we want to find subsets of these points that lie on straight lines.
#ne possible solution is to first find all lines determined b" ever" pair of points and then find all subsets
of points that are close to particular lines. %he problem with this procedure is that it involves finding n5n+
16(< lines and then performing 5n65n5n+166(< comparisons of ever" point to all lines. %his approach is
computationall" prohibitive in al but the most trivial applications.
=-/-/ :lo3al "rocessin >ia :rap*-<*eoretic <ec*ni.ues
In this section, a global approach based on representing edge segments in the form of a graph and
searching the graph for low+cost paths that correspond to significant edges is discussed. %his
representation provides a rugged approach that performs well in the presence of noise. /s might be
e0pected, the procedure is considerabl" more complicated and requires more processing time.
/ graph - D 5,, /6 is a finite, non empt" set of nodes ,, together with a set / of unordered pair of
distinct elements of ,. @ach pair of / is called an arc. / graph in which the arcs are directed is called a
directed graph. If an arc is directed from node to node, then is said to be a successor of its parent
node . %he process of identif"ing the successors of a node is called e0pansion of the node. In each
graph we define levels, such that level consists of a single node, called the start node, and the nodes in
the last level are called goal nodes. / cost can be associated with ever" arc . / sequence of nodes with
each being a successor of node is called a path from , and the cost of the path is
=. 7escribe the following with respect to !egion .ased segmentation:
/6 .asic 9ormulation
/ns:
:et ! represent the entire image region. We ma" view segmentation as a process that partitions ! into
n sub regions, !1,!<, ^. !n such that
4ere,P5!16 is a logical predicate over the points in set and is the null set.
Condition 5a6 indicates that the segmentation must be completeL that is, ever" pi0el must be in a region.
Condition 5b6 requires that points in a region must be connected. Condition 5c6 indicates that the regions
must be dis$oint. Condition 5d6 deals with the properties that must be satisfied b" the pi0els in a
segmented region I for e0ample D %!;@ if all pi0els in have the same gra" level. 9inall", condition 5e6
indicates that regions and are different in the sense of predicate P.
.6 !egion -rowing
/ns:
!egion growing is one of the conceptuall" simplest approaches to image segmentationL neighboring
pi0els of similar amplitude are grouped together to form a segmented region. !egion+growing
approaches e0ploit the fact that pi0els which are close together have similar gra" values. tart with a
single pi0el 5seed6 and add new pi0els slowl".
516 Choose the eed pi0el.
5<6 Chec2 the neighboring pi0els and add to the region if the" are similar to the seed.
5)6 !epeat step < for each of the newl" added pi0elsL stop if no more pi0els can be added.
?o+ #o +e c*oose t*e see#(s) in practice@
_`It depends on the nature of the problem.
_`If targets need to be detected using infrared images for e0ample, choose the brightest pi0el5s6.
_`Without a+priori 2nowledge, compute the histogram and choose the gra"+level values corresponding
to the strongest pea2s
?o+ #o +e c*oose t*e similarit0 criteria (pre#icate)@ %he homogeneit" predicate can be based on
an" characteristic of the regions in the image such as:
_`average intensit"
_`variance
color
texture
C6 !egion plitting and Merging
/ns:
ub+divide an image into a set of dis$oint regions and then merge and(or split the regions in an attempt
to satisf" the conditions stated in section 1*.).1.
:et ! represent the entire image and select predicate P. #ne approach for segmenting ! is to subdivide
it successivel" into smaller and smaller quadrant regions so that, for ant region, !1. P5!16 D %!;@. We
start with the entire region. If P5!
6 D 9/:@, then the image is divided into quadrants. If P is 9/:@ for an" quadrant, we subdivide that
quadrant into sub quadrants, and so on. %his particular splitting technique has a convenient
representation in the form of a so called quad tree 5that is, a tree in which nodes have e0actl" four
descendants6. %he root of the tree corresponds to the entire image and that each node corresponds to
a subdivision. In this case, onl" was sub divided further.
If onl" splitting were used, the final partition li2el" would contain ad$acent regions with identical
properties. %his draw bac2 ma" be remedied b" allowing merging, as well as splitting. atisf"ing the
constraints of section 1*.).1 requires merging onl" ad$acent regions whose combined pi0els satisf" the
predicate P. %hat is, two ad$acent regions and are merged onl" if D %!;@.
K. 7escribe the following with respect to hape /nal"sis:
/6 hape #rientation 7escriptors
/ns:
%he spatial orientation of an ob$ect with respect to a hori&ontal reference
a0is is the basis of a set of orientation descriptors developed at the tanford
!esearch Institute. %hese descriptors, defined below,
1. 6mage-oriented bounding box7 the smallest rectangle oriented along the rows of the image that
encompasses the ob$ect
<. 6mage-oriented box height7 dimension of bo0 height for image+oriented bo0
). 6mage-oriented box %idth7 dimension of bo0 width for image+oriented bo0
=. Image+oriented bo0 area: area of image+oriented bounding bo0
K. Image oriented bo0 ratio: ratio of bo0 area to enclosed area of an ob$ect for an image+oriented bo0
A. #b$ect+oriented bounding bo0: the smallest rectangle oriented along the
J. ma$or a0is of the ob$ect that encompasses the ob$ect
?. #b$ect+oriented bo0 height: dimension of bo0 height for ob$ect+oriented bo0
E. #b$ect+oriented bo0 width: dimension of bo0 width for ob$ect+oriented bo0
1*. #b$ect+oriented bo0 area: area of ob$ect+oriented bounding bo0
11. #b$ect+oriented bo0 ratio: ratio of bo0 area to enclosed area of an ob$ect for an ob$ect+oriented bo0
1<. Minimum radius: the minimum distance between the centroid and a perimeter pi0el
1). Ma0imum radius: the ma0imum distance between the centroid and a perimeter pi0el
1=. Minimum radius angle: the angle of the minimum radius vector with respect to the hori&ontal a0is
1K. Ma0imum radius angle: the angle of the ma0imum radius vector with respect to the hori&ontal a0is
1A. !adius ratio: ratio of minimum radius angle to ma0imum radius angle.
.6 9ourier 7escriptors:
/ns:
%he perimeter of an arbitrar" closed curve can be represented b" its instantaneous curvature at each
perimeter point. Consider the continuous closed curve drawn on the comple0 plane in which a point on
the perimeter is measured b" its polar position &5s6 as a function of arc length s. %he comple0 function
&5s6 ma" be e0pressed in terms of its real part 05s6 and imaginar" part "5s6 as
&5s6 D 05s6 R i"5s6
%he tangent angle defined is given b"
%he coordinate points O05s6, "5s6P can be obtained from the curvature function b" the reconstruction
formulas
where x5*6 and y5*6 are the starting point coordinates.
.ecause the curvature function is periodic over the perimeter length 8, it can be e0panded in a 9ourier
series as
where the coefficients cnare obtained from
%his result is the basis of an anal"sis technique developed b" Cosgriff and .rill in which the 9ourier
e0pansion of a shape is truncated to a few terms to produce a set of 9ourier descriptors. %hese 9ourier
descriptors are then utili&ed as a s"mbolic representation of shape for subsequent recognition.
If an ob$ect has sharp discontinuities 5e.g., a rectangle6, the curvature function is undefined at these
points. %his anal"tic difficult" can be overcome b" the utili&ation of a cumulative shape function
%his function is also periodic over P and can therefore be e0panded in a 9ourier series for a shape
description.
C6 %hinning and 2eletoni&ing
/ns:
We have previousl" discussed the usage of morphological conditional erosion as a means of thinning
or s2eletoni&ing, respectivel", a binar" ob$ect to obtain a stic2 figure representation of the ob$ect. %here
are other non+morphological methods of thinning and s2eletoni&ing. ome of these methods create
thinner, minimall" connected stic2 figures. #thers are more computationall" efficient.
%hinning and s2eletoni&ing algorithms can be classified as sequential or parallel. In a sequential
algorithm, pi0els are e0amined for deletion 5erasure6 in a fi0ed sequence over several iterations of an
algorithm. %he erasure of a pi0el in the nth iteration depends on all previous operations performed in
the 5n+16th iteration plus all pi0els alread" processed in the incomplete nth iteration. In a parallel
algorithm, erasure of a pi0el in the nth iteration onl" depends upon the result of the 5n+16th iteration.
equential operators are, of course, designed for sequential computers or pipeline processors, while
parallel algorithms ta2e advantage of parallel processing architectures. equential algorithms can be
classified as raster scan or contour following. %he morphological conditional erosion operators are
e0amples of raster scan operators. With these operators, pi0els are e0amined in a ) F ) window, and
are mar2ed for erasure or not for erasure. In a second pass, the conditionall" mar2ed pi0els are
sequentiall" e0amined in a ) F ) window. Conditionall" mar2ed pi0els are erased if erasure does not
result in the brea2age of a connected ob$ect into two or more ob$ects.
In the contour following algorithms, an image is first raster scanned to identif" each binar" ob$ect to be
processed. %hen each ob$ect is traversed about its peripher" b" a contour following algorithm, and the
outer ring of pi0els is conditionall" mar2ed for erasure. %his is followed b" a connectivit" test to
eliminate erasures that would brea2 connectivit" of an ob$ect. !osenfeld and /rcelli and di .i$a have
developed some of the first connectivit" tests for contour following thinning and s2eletoni&ing.
A. 7escribe the following:
/6 Image P"ramids
/ns:
/nal"&ing, manipulating and generating data at various scales should be a familiar concept to an"bod"
involved in Computer -raphics. We will start with 1image3 p"ramids. In p"ramids such as a M68 map
used for filtering, successive averages are built from the initial .
It is clear that it can be seen as the result of appl"ing bo0 filters scaled and translated over the signal.
9or initial values we have log < 5n6 terms in the result. Moreover because of the order we have chosen
for the operations we onl" had to compute n D 1 additions 5and shifts if means are stored instead of
sums6. %his is not a good scheme for reconstruction, since all we need is the last row of values to
reconstruct the signal 5of course the" are sufficient since the" are the initial values, but the" are also
necessar" since onl" a sum of ad$acent values is available from the levels above6. We can observe,
though, that there is some redundanc" in the data. Calling siL$ the $th element of level i 5* being the top
of the p"ramid, 2 D log<5n6 being the bottom level6 we have:
We can instead store s*L* as before, but at the level below we store:
It is clear that b" adding s*L* and s* 1L* we retrieve s1L* and b" subtracting s*L* and s* 1L* we retrieve
s1L1. We therefore have the same information with one less element. %he same modification applied
recursivel" through the p"ramid results in n D 1 values being stored in 2 D 1 levels. ince we need the
top value as well 5s*L*6, and the sums as intermediar" results, the computational scheme . %he price
we have to pa" is that now to effect a reconstruction we have to start at the top of the
p"ramid and stop at the level desired.
If we loo2 at the operations as appl"ing a filter to the signal, we can see easil" that the successive
filters in the difference p"ramid are 51(<, 1(<6 and 51(<, +1(<6, their scales and translates. We will see
that the" are characteristics of the 4aar transform. ,otice also that this scheme computes
the p"ramid in #5n6 operations.
.6 eries @0pansion
/ns:
%he standard 9ourier transform is especiall" useful for stationary signals, that is for signals whose
properties do not change much 5stationarit" can be defined more precisel" for stochastic processes, but
a vague concept is sufficient here6 with time 5or through space for images6. 9or signals such as
images with sharp edges and other discontinuities, however, one problem with 9ourier transform and
9ourier s"nthesis is that in order to accommodate a discontinuit" high frequenc" terms appear and the"
are not locali&ed, but are added ever"where. In the following e0amples we will use for simplicit" and
clarit" piece-%ise constant signals and piece+wise constant basis functions to show the characteristics
of several transforms and encoding schemes. %wo sample 1+7 signals will be used, one with a single
step, the other with a 5small6 range of scales in constant spans.
%he" have various ordering for their inde0 i, so alwa"s ma2e sure "ou 2now which ordering is used
when dealing with W i 5t6. %he most common, used here, is where i is equal to the number of &ero
crossings of the function 5the so+called sequency order6. %here are various definitions for
them. / simple recursive one is:
with W * 5t6 D 1.
where $ ranges from * to1and q D * or 1. %he Walsh transform is a series of coefficients given b":
and the function can be reconstructed as:
,ote that since the original signals have discontinuities onl" at integral values, the signals are e0actl"
represented b" the first )< Walsh bases at most. .ut we should also note that in this e0ample, as well
as would be the case for a 9ourier transform, the presence of a single discontinuit" at <1 for signal 1
introduces the highest 1frequenc"3 basis, and it has to be added globall" for all t. In general cases the
coefficients for each basis function decrease rapidl" as the order increases, and that usuall" allows for
a simplification 5or compression6 of the representation of the original signal b" dropping the basis
functions whose coefficients are small 5obviousl" with loss of information if the coefficients are not *6.
C6 caling functions + Continuous Wavelet %ransform
/ns:
We can choose an" set of windows to achieve the constant relative bandwidth, but a simple version is if
all the windows are scaled version of each other. %o simplif" notation, let us define h 5t6 as:
and scaled versions of h 5t6 :
where a is the scale factor 5that is f D f* ( a 6, and the constant 1 ( a a a is for energ" normali&ation. %he
W9% now becomes:
%his is 2nown as a %avelet transform, and h 5t6 is the basic %avelet. It is clear from the above formula
that the basic wavelet is scaled, translated and convolved with the signal to compute the transform. %he
translation corresponds to moving the window over the time signal, and the scaling, which is often
called dilation in the conte0t of wavelets, corresponds to the filter frequenc" bandwidth scaling.
We have used the particular form of h 5t6 related to the window w 5t6, but the transform W956 can be
defined with an" function h5t6 satisf"ing the requirements for a band pass function, that is it is
sufficientl" regular its square integral is finite and its integral b h5t6 dt D *. We can rewrite the basic
wavelet as:
%he transform is then written as:
We can reconstruct the signal as:
where c is a constant depending on h 5t6. %he reconstruction loo2s li2e a sum of coefficients of
orthogonal bases, but the h a, 5t6 are in fact highl" redundant, since the" are defined for ever" point in
the a, space.
ince there is a lot of redundanc" in the continuous application of the basic wavelet, a natural question
is whether we can discreti&e a and in such a wa" that we obtain a true orthonormal basis. 9ollowing
7aubechies one can notice that if we consider two scales a * c a 1, the coefficients at scale a 1 can
be sampled at a lower rate than for a * since the" correspond to a lower frequenc". In fact the sampling
rate can be proportional to a * ( a 1 -enerall",
if:
5i and $ integers, % a period 6 the wavelets are:
and the discreti&ed wavelets coefficients are:
We hope that with a suitable choice of h5t6, a* and % we can then reconstruct f5t6 as:
It is clear that for a* close to 1 and % small, we are close to the continuous case, and the conditions on
h5t6 will be mild, but as a* increases onl" ver" special h5t6 will wor2.

Вам также может понравиться