+ All Categories
Home > Documents > seminar ppt1

seminar ppt1

Date post: 08-Apr-2018
Category:
Upload: jenish2
View: 233 times
Download: 0 times
Share this document with a friend

of 19

Transcript
  • 8/7/2019 seminar ppt1

    1/19

    IMAGE ENHANCEMENT TECHNIQUESWhat is Digital image?

    An image may be defined as a two dimensional function f(x,y) ,x & y = spatial coordinates .The amplitude of f at any paircoordinates (x,y) is called the intensity orGray level of the image at that point .When x,y & the amplitude value of f are all finite, discrete quantities ,wecall the image a DIGITAL IMAGE.

    Digital Image is composed of a finite no of elements. They are referred toas picture elements, image elements ,peels or pixels. Pixel is the termmost widely we use.

    Two techniques for image enhancement:1) Spatial Domain, which refers to the image plane itself & direct

    manipulation of pixels in image.2) Frequency Domain ,which are based on modifying the Fourier transform

    of an image .

  • 8/7/2019 seminar ppt1

    2/19

    1) Spatial Domain Tequenics:

    It is the aggregate of pixels composing an image.These methods are

    proc

    edures that operate direc

    tly on

    these pixels.

    It is denoted by the formula g(x,y)=T[f(x,y)],where f(x,y) is the input image , g(x,y) is the processed image

    & T is an operator on f , defined over some neighborhood of (x,y).

    Enhancement at any point in an image depends only on the gray levelat that point, known as point processing.

  • 8/7/2019 seminar ppt1

    3/19

    Some basic gray level Transformation:` Image negatives: The negative of an image with gray levels in the range [0,L-1] is obtained by

    using negative transformation s=L-1-r.

    ` Log Transformation:

    The expression for this is s=clog(1+r)where c is a constant,

    It is used to expand the values of dark pixels in the image whilecompressing the higher level values.

    ` Power law transformation:

    It has the basic form s=cr(gamma),where c & are positive constants.

    Power law curves with fractional values of map a narrow range of darkinput values into a wider range of output levels , with the opposite being truefor higher values of input levels.

    The process used to correct this power law response phenomena is called

    gamma correction.

  • 8/7/2019 seminar ppt1

    4/19

    ` Contrast Streching:` Simple piecewise linear function is Contrast stretching transformation. Low

    contrast images can result from poor illumination,

    ` The idea behind contrast stretching is to increase the dynamic range of the

    gray levels in

    the image bein

    g proc

    essed.

    ` Gray level slicing:` One approach of its is to display a high value for all gray levels in the range

    of interest & a low value for all other gray levels.

    ` Histogram processing:

    `

    The histogram of of a digital image with gray levels in

    the ran

    ge [0,L-

    1] is adiscrete function h(rk)=nk, rk is the kth gray level & nk is the no of pixels inthe image having gray levels rk.

    ` In the dark image that the components of the histogram are concentrated onthe low side of the gray scale. Similarly, the components of the histogram ofthe bright image are biased towards the high side of the gray scale.

  • 8/7/2019 seminar ppt1

    5/19

    ` Histogram Equalization: Let variable r represent gray level of the image to be enhanced. with r=0

    represent black & r=1 represent white.

    For the formula s=T(r) ,0

  • 8/7/2019 seminar ppt1

    6/19

    ` Enhancement using Arithmetic/Logic operation: A/L operations involving images are performed on a pixel by pixel basis

    between two or more images. Logic operations similarly operate on a pixelby pixel basis.

    Performing the NOT operation on a black,8-bit pixel produces a whitepixel. Intermediate values are processed the same way. changing all 1s to0s.The AND and OR operations are used for masking. In the AND & ORimage masks, light represents a binary 1 & dark represents a binary0.Masking sometimes referred to as region of interest processing. In termsof enhancement, masking is used primarily to isolate an area forprocessing.

    ` Image subtraction:

    The difference between two images f(x,y) & h(x,y) expressed as,g(x,y)=f(x,y)-h(x,y).

    It is obtained by computing the difference between all pairs ofcorresponding pixels from f & h. The key usefulness of subtraction isenhancement of difference between images. The higher order bit planesof an image carry a significant amount of visually relevant details .

  • 8/7/2019 seminar ppt1

    7/19

    ` Image Averaging: Consider g(x,y)= f(x,y)+ n(x,y),

    where f(x,y)=original imageg(x,y)=noisy image &

    n(x,y)=noiseThe objective of the following procedure is to reduce the noise content by

    adding a set of noisy images { gi (x,y) } if an image g^(x,y) is formed byaveraging K different noisy images,g^(x,y)=1/K 1kgi(x,y) then E{ g^ (x,y) }= f (x,y). It is possible In some

    implementations of image averaging to have negative values when noise is

    added to an image.` Basics of spatial filtering: The values in a filter sub image is are referred to as coefficients, rather than

    pixels. The concept of filtering has its roots in the use of Fourier Transform so called

    frequency domain. At each point (x,y) the response of the filter at that point is calculated using a

    predefined relationship. For linear spatial filtering , the response is given by asum of products of the filter coefficients. For 3*3 mask ,the result R of linearfiltering with the filter mask at a point (x , y) in the image is,R=w(-1,-1)f(x-1,y-1)+w(-1,0)f(x-

    1,y)+....+w(0,0)f(x,y)+w(1,0)f(x+1,y)+w(1,1)f(x+1,y+1)

  • 8/7/2019 seminar ppt1

    8/19

    The response R of an m*n mask at any point (x,y), using the followingexpression: R = w1z1+w2z2 + w3z3+ w4z4 + + wmnzmn

    = 1 mn wiziwhere ,ws are mask coefficients,

    zs are values of image gray levelscorresponding to those coefficients.

    & mn is the total no ofcoefficients.

    ` Smoothing Spatial filters: These filters are used for blurring & fornoise reduction. Blurring is used inpreprocessing steps such as removal of some details from an image prior to

    object extraction , bridling of small gaps in lines orcurves.

    ` Smoothing linear filters: The output of smoothing linear filter is simply average of the pixels

    contained in the neighborhood of the filter mask. These filters are also calledaveraging filters.

    The most obvious application of smoothing is noise reduction.

  • 8/7/2019 seminar ppt1

    9/19

    ` Sharpening Spatial filters: The principal objective of sharpening is to highlight fine detail in an image

    or to enhance details that has been blurred. Uses of image sharpening :vary & include application ranging from

    1)electronic printing2) medical imaging &3) to industrial inspection &4) autonomous guidance in military systems.

    Sharpen

    in

    g filters are based on

    first & sec

    on

    d order derivatives. Thederivatives of a digital function are defined in terms of differences. We use for a first derivative

    1) must be zero in flat segments2)must be nonzero at the onset of a gray level step or gray level.

    3) must be nonzero along ramps.` while a second derivative 1) must be zero in flat areas 2) must be nonzero at onset & at a gray level step or ramp

    3) must be zero along ramps ofconstant slope.

  • 8/7/2019 seminar ppt1

    10/19

    Comparing the response between first & second order derivative , we arrivethe following conditions.

    1)First order derivatives generally produce thicker images in an image.2)Second order derivative have a stronger response to fine detail such as thin

    lines & isolated points.3)First order derivatives have a stronger response to gray level step.4)Second order derivatives produce a double response at step changes in

    gray level.

    Isotroic filters are rotation invariant in the sense that rotating the image &then applying the filter gives the same result as applying the filter to image

    first & then rotating the result.

    Use of development of the method: d^2f/dx^2=f(x+1,y) + f(x-1,y) 2f(x,y) d^2f/dx^2=f(x,y+1) + f(x,y-1) 2f(x,y) ^2f= [f(x+1,y) + f(x,y+1) + f(x,y-1)] 4 f(x,y)Because the Laplacian is a derivative operator ,its use highlights gray leveldiscontinuities in an image .

    This will tend to produce images that have grayish edge lines & otherdiscontinuitty , featureless background.. Thus the basic way in which waywe use Laplacian for image enhancement is as follows:

  • 8/7/2019 seminar ppt1

    11/19

    g(x,y)= f(x,y) - ^2f(x,y) if the centercoefficient is negative.= f(x,y) +^2f(x,y) if the centercoefficient is positive.

    2) Image enhancement in the frequency domain:

    The on

    e dimen

    sion

    al Fourier , F(u) of a sin

    gle variable ,c

    on

    tin

    ous func

    tion

    ,f(x) , is defined by the equation

    F(u) = f(x) e^(-j2ux)dx ,where j^2=(-1) .

    f(x) by means of the inverse Fourier transform

    f(x)= F(u) e^(j2ux)du. These two equations comprise the Fouriertransform pair. These equations are easy

    F(u,v)=f(x,y) e^-j2(ux+vy)dxdy , Similarly for the inverse transform,

    f(x,y)= F(u,v)e j2(ux+vy)dudv F(u)=| F(u) | e^(-j(u))

    where , |F(u)|=[ R^2(u) + I^2(u) ] ^1/2 is called themagnitude or spectrum of the Fourier transform &,(u)=tan^-1[ I[u] / R[u] ] & Power spectrum

    P(u)= | F(u) |^2 = R^2(u)+ I^2(u) . The spectral density also is used to refer tothe power spctrum.

  • 8/7/2019 seminar ppt1

    12/19

    ` Basics of filtering in frquency domain:1) Multiply the input image by (-1)^x+y to center the transform.2) Compute F(u,v) , the DFT of an image from (1).3) Multiply F(u,v) by a filter function H(u,v).

    4) Compute the inverse DFT of the result in (3).5) Obtain the real part of result in (4).6) Multiply the result in (5) by (-1)^x+y .

    H(u,v) is called a filter because it suppresses certain frequencies in the

    transform while leaving others unchanged.G(u,v)=H(u,v)F(u,v) .The multiplication of H & F involves two dimensionalfunction & it s defined on an element by element.

    ` Some basic filters & their properties :

    Suppose that we wish to force the average value of an image to zero.The average of an image is given by F(0,0).. If we set this term to zero inthe frequency domain & take the inverse transform , then average valueof the resulting image will be zero.. We can do this operation bymultiplying all values of F(u,v) by the filter function: H(u,v)=0 if(u,v)=(M/2,N/2) , 1 otherwise.

  • 8/7/2019 seminar ppt1

    13/19

    This filters are called notch filter because it is constant function with a holeat the origin.

    Low frequencies in an image are responsible for the general gray levelappearance of an image over smooth areas, while high frequencies are

    respon

    sible for edges &n

    oise.

    ` Smoothing frequency domain filters: Edges & other sharp transitions in the gray levels of an image contribute

    significantly to the high frequency content of its Fourier transform. Hence

    smoothing i s achieved in the frequency domain by attenuating highfrequency components in the transform of a given image. There are basically 3) types of filters:1) ideal ,2)Butterworth &

    3) Gaussian

    .These three filtersc

    over the ran

    ge from very sharp to verysmooth filter functions. The Butterworth filter has a parametercalled the filter order. For high value of this parameter ,the Butterworth filter approaches the form

    of the ideal filter. For lower order values the Butterworth filter has a smoothwaveform similar to Gaussian filter.

  • 8/7/2019 seminar ppt1

    14/19

    ` Ideal low pass filers: It has the transfer function H(u,v) = 1 if D(u,v)Do,where Do is the specified nonnegative quantity &

    D(u,v) is the distanc

    e from poin

    t (u,v) to the origin

    of thefrequency rectangle.

    The distance from any point (u,v) to the center of the Fourier transform isgiven by

    D(u,v)=[ (u-M/2)^2 + (v- N/2)^2 ] ^1/2. For an ideal low pass filter , the point of transition between H(u,v)=1 &

    H(u,v)=0 is called the cutoff frequency.

    The FT of original image f(x,y) & blurred image g(x,y) are related in thefrequency domain G(u,v) = H(u,v) F(u,v).

    H(u,v)is the filter function &

    G & F are FT of the two images. In spatial domain g(x,y)= h(x,y)* f(x,y)

    where h(x,y) is the inverse Fourier transform of filterfunction.

  • 8/7/2019 seminar ppt1

    15/19

    ` Butterworth lowpass filters:

    The transfer function of a Butterworth low pass filter of order n , & withcutoff frequency at a distance Do at the origin, is defined as

    H(u,v)= 1/ 1+ [D(u,v)/Do]^2nwhere D(u,v)= ([u-M/2]^2 + [v-N/2]^2)^1/2.

    Unlike the ILPF , The BLPF transfer function does not have a sharpdiscontinuity that establishes a clear cutoff between passed & filteredfrequencies .

    A Butterworth filter of order 1 has no ringing , but can become a significantfactor in filters of higher order. The BLPF of order 1 has neither ringing nornegative values.

    The filter of order 2 does show mid ringing & small negative values, butthey certainly are less pronounced than in the ILPF.

    In general , BLPFs of order 2 are a good compromise between low passfilter & acceptable ringing characteristics.

  • 8/7/2019 seminar ppt1

    16/19

    ` Gaussian lowpass filters: The form of these filters is

    H(u,v)=e^(-D(u,v)/2 ,

    where D(u,v) is the distance from the origin of the Fourier transform,

    is a measure of the spread of the Gaussiancurve . By letting =Do, H(u,v) = e^(-D(u,v)/2Do) ,where Do is the cutoff frequency. WhenD(u,v)=Do the filter is down to 0.607 of its maximum value.

    ` Additional examples of low pass filtering :

    1) From the field of machine perception , with application to characterrecognition ,

    2) From the printing & publishing industry & the third is related to processingsatellite & aerial images.

    3) Low pass filtering is a staple in the printing & publishing industry, where itis used fornumerous preprocessing functions, including unsnap masking .Cosmetic processing is another use of low pass filter.

  • 8/7/2019 seminar ppt1

    17/19

    ` Sharpening frequency domain filters: Image can be blurred by attenuating the high frequency

    components of its FT because edges & other abrupt changes in gray

    levels are associated with high frequency components ,

    Image sharpening can be achieved in the frequency domain by a high passfiltering process , which attenuates the low frequency components withoutdisturbing high frequency information .

    The transfer function of the high pass filter is Hhp(u,v)=1 Hlp(u,v) . WhereHlp(u,v) is the T.F. of the corresponding low pass filter.

    ` Ideal highpass filters: A 2-D ideal high pass filter is defined as H(u,v)= 1 if D(u,v) Do , whereDo is the cutoff distance measured from the origin of frequency rectangle .

  • 8/7/2019 seminar ppt1

    18/19

    ` Butterworth High pass filters:

    The T.F of the Butterworth high pass filter of order n & with cutofffrequencies of ordern & locus at a distance Do from the origin is given by

    H(u,v)= 1 / 1+ [Do/D(u,v)]^2n . As in the case of low pass filters , we can expect Butterworth high pass

    filters to behave smoother than IHPS .

    The performance of a BHPF of order 2 & with Do set to the same values.The transition into higher values of a cutoff frequencies is much smootherwith the BHPF.

  • 8/7/2019 seminar ppt1

    19/19

    ` Gaussian high pass filters: The transfer function of the Gaussian high pass filter with cutoff frequency locus

    at a distance Do from the origin is given byH(u,v)= 1 e^(-D(u,v)/2Do).

    In this way the results obtained are smoother than previous two examples.Even filtering of the smaller objects & thin bars is cleaner with the Gaussianfilter.

    ` Homographic filtering:` It is used to develop a frequency domain for improving the appearance of an

    image by simultaneous gray level range compression & contrast enhancement.

    f(x,y)c

    an

    be expressed as the produc

    t of illumin

    ation

    & reflec

    tion c

    ompon

    en

    ts.f(x,y)= i(x,y) r(x,y)The F.T. of the product of two functions is not separable,F[ f(x,y) ] =/ F( i(x,y) ). F( r(x,y) ).

    Suppose , z(x,y)= ln f(x,y) = ln i(x,y) + ln r(x,y).Then F{ z(x,y) }=F{ ln f(x,y) }

    =F { ln i(x,y) } + F{ ln r(x,y) } or z(u,v)= Fi(u,v) + Fr (u,v) . WhereFi(u,v) & Fr (u,v) are fourier transform of the result. In the spatial domain , s(u,v)= H(u,v) Z(u,v)

    = H(u,v)Fi(u,v) + H(u,v)Fr(u,v) . S(u,v) is the fourier transform ofthe result. S(x,y)= F^(-1) [ S(u,v) ]


Recommended