SlideShare a Scribd company logo
Image Enhancement
  & Edge Detection

          Tati R Mengko
Introduction
 Image Enhancement :
   accentuation and sharpening of image features
   (edges, boundaries, contrast) to improve image
   visual appearance and analysis.
   does not increase information content, but
   improves feature dynamic range to ease feature
   detection.
 Major challenge in image enhancement:
   quantification of the enhanced feature criterion.
Image Enhancement Techniques
                          Image Enhancement




  Point              Spatial           Transform            Pseudo
  Operation          operation         Operation            Coloring



•Contrast         •Noise              •Linear Filtering
                                                          •False Coloring
Stretching        Smoothing           •Root Filtering
                                                          •Psudocoloring
•Noise Clipping   •Median Filtering   •Homomorphic
•Window Slicing   •Unsharp            Filtering
•Histogram        Masking
Modeling          •Low-, High-,
                  Band-pass
                  Filtering
                  •Zooming
Point Operation
 Point Operation
   zero-memory operation
   Map graylevel u∈[0,L] to graylevel v∈[0,L], through
   transform relation v=f(u).
   Contrast stretching, clipping, thresholding

                                   α u,                0≤u<a
  vb   v           γ               
                               v =  β ( u − a ) + va , a ≤ u < b
           β
                                   
  va                               γ ( u − b ) + vb , b ≤ u < L
       α
                           u   α and β determination is based on
           a   b       L       image histogram.
Point Operation
 Contrast stretching
   Bad contrast: unadequate illumination, sensor non-linearity.
   In the contrast-stretched area, transforming gradient >1.
 Special contrast-stretching cases:
   Clipping: α=γ=0.
   Thresholding : α=γ=0 , a=b.

                                      v                v
    vb   v                γ
                β

   va                                            u                   u
         α
                                  u
                a     b       L
         stretching                   clipping         tresholding
Thresholding Example: Binarization




  Red Blood Cells Grayscale Image   Red Blood Cells Binary Image
Thresholding Example: Gamma Correction




        Original Image   Gamma-corrected Image
Digital Negative
 Reversed graylevel scaling:

                                                  50
     50



                                                  100
    100

                                        v = L-u
                                                  150
    150



                                                  200
    200



                                                  250
    250                                                 50   100   150   200   250
          50    100   150   200   250




               %MATLAB
               I=imread('cameraman.tif');
               figure(1);imagesc(I);colormap(gray);
               figure(2);imagesc(255-double(I));
               colormap(gray);
Intensity Level Slicing
 Segment a certain intensity level from the rest of the
 image.
 Without background:          L, a ≤ u ≤ b
                          v=
                            0, lainnya
 With background:            L, a ≤ u ≤ b
                          v=
                            u , lainnya
      v                             v

  L



                      u                                   u

          a    b                        a     b     L
Intensity Level Slicing




Original image



                 Without background


                                      With background
Range Compression and Digital Substraction
  Compress image intensity range:
     v = c log10(1+|u|)  , c = scaling constant
  Digital Substraction:
    Detect difference/gradual intensity change between
    images.
    Example: Digital Substraction Angiography (DSA).
Example of Range Compression
Histogram Modeling
 Image histogram represents distribution of graylevel occurrence in
 an image.
 Histogram modeling:
     modification of an image histogram into a desired shape.
 Histogram Equalization:
    uniformly-distribute graylevel occurrence frequency distribution.

  I = imread('tire.tif');imshow(I); imhist(I,64)
  J = histeq(I);figure, imshow(J); figure; imhist(J,64)

                                                                 2000
                 3000
                                                                 1800
                 2500                                            1600

                                                                 1400
                 2000
                                                                 1200
                 1500
                                                                 1000

                 1000                                             800

                                                                  600
                 500
                                                                  400

                   0                                              200

                                                                   0
                        0   50   100   150   200   250

                                                                        0   50   100   150   200   250




     Before hist.equalization                            After hist.equalization
Histogram Examples
Histogram Equalization
 Histogram equalization is not appropriate for narrow
 intensity distribution images.

                   Original                        Histeq
                   Image                           Result
Spatial Operation
 Spatial Averaging
  Pixel intensity is replaced with weighted average of its
  neighborhood pixels intensity.
           v ( m, n ) =     ∑ ∑ a (k,l ) y (m − k, n − l )
                          ( k ,l )∈W
 Spatial averaging: a(k,l) = constant
                        1
          v ( m, n ) =       ∑W ∑ y ( m − k , n − l )
                       NW ( k ,l )∈
  a(k,l)=1/NW, NW = number of pixels within filtering window
Spatial Operation
 Alternative method: every pixel is replaced by its 4-
 closest neioghbors average intensity value :

 v(m,n) = 0.5 [y(m,n) + 0.25{ y(m-1,n)
             + y(m+1,n) + y(m,n-1) + y(m,n+1)} ]

 Averaging ‘ mask’:

  ¼      ¼       1/9      1/9      1/9      0      1/8       0

  ¼      ¼       1/9      1/9      1/9     1/8      ¼      1/8
                 1/9      1/9      1/9      0      1/8       0

 2×2 window           3×3 window         5-points weighted averaging
Spatial Operation
  Spatial averaging:
    Smoothing
    Low-pass filtering
    Subsampling
  Noisy image:

               y(m,n) = u(m,n) + η(m,n)

  η(m,n) = white noise with variance= ση2
  Output image:
                     1
       v ( m, n ) =
                    NW
                           ∑ ∑ u ( m − k , n − l ) + η ( m, n )
                         ( k ,l )∈W
   η(m,n) = spatial average

• If mean(η(m,n)) = 0, noise power suppression level is proportional
  to the number of pixels in the filtering window: ση2 = ση2/NW.
Example of Spatial Operation




      Original Image   Original Image + Noise
Example of Spatial Operation
Blurring Effect due to Averaging
Blurring Effect due to Averaging
Effects of Various Noise Energy
Effects of Various Noise Energy
Median Filter
 The last examples shows the weakness of averaging method
 Median filter overcome this problem
Median Filter
Image Sharpening
 Enhance missing delicate structures due to blurring
 effect.
 Sharpen graylevel difference between neighbouring
 pixels in an image.
 High-pass filtering
    Shift-invariant operator
    Convolution mask contains positive number
    surrounded by negative numbers.

                    −1 −1 −1
                  1         
                     −1 8 −1
                  9
                    −1 −1 −1
                            
High Pass Filtering
 Relation between high-pass filtered image g, original
 image f, and its low-pass filtered version:

               g(m, n) = f(m, n) – lowpass(f(m, n))
High-boost Filtering (Unsharp Masking)
 Substraction of amplified original image and low-pass fitered
 original image:
      g(m, n) = Af(m, n) – lowpass(f(m, n))
              = (A-1)f(m, n) + [f(m, n)– lowpass(f(m, n))]
              = (A-1)f(m, n) + higpass(f(m, n))
 Produce an edge-enhanced version of original image.




    Original Image        High pass           High boost
Derivative Filter
 Sharpen image boundaries/edges, based on discrete
 spatial gradient operator:




 Implemented with 2-D convolution approach:



 hn = edge detector derivative filter convolution mask
Derivative Filter: Roberts Operator




  Original Image
Derivative Filter: Prewitt & Sobel Operator




                                     Sobel
          Prewitt
Frequency-domain Method
 Enhancement conducted in the transform domain, followed by
 an inverse transform to obtain the spatial domain enhanced
 image representation.
 For original image U = {u(m,n)} being transformed into V =
 {v(k,l)} : V = AUAT.
 Enhancement operation produces v’(k,l) = f(u(m,n)).
 Spatial domain enhanced image: U = A-1V’(AT)-1 .
 Generalized Filtering:
    zero-memory transformation
    Pixel-to-pixel multiplication: v’(k, l) = g(k, l) v(k, l).
    g(k, l) = zonal mask.
u(m,n)   Transformasi   v(k,l) Operasi      v’(k,l) Transformasi    u’(m,n)
                                                      Inverse
         Uniter AUAT           Titik f(.)
                                                     A-1 V’(AT)-1
Frequency-domain Method
 Frequency-domain processing is utilized to accelerate
 spatial image filtering.
 Time domain convolution is equivalent to fourier domain
 (FFT) pixel-to-pixel multiplication:

       g(m,n) = h(m,n)*f(m,n) ≈ G(u,v) = H(u,v) F(u,v)
Ideal Low-pass Filter
  Ideal low-pass filter:
              1, jika u 2 + v 2 ≤ r
                                                      r0=57
                                    0
 H ( u, v ) = 
              0, jika u 2 + v 2 > r0
              




   Original Image   LPF, r0 = 57        LPF, r0 = 36   LPF, r0 = 26
• Ringing effect: property of ideal filter.
Butterworth Low Pass Filter
 Butterworth low-pass filter:




   n: order filter, r0: cutoff freq.




  Original Image           r0 = 18     r0 = 13   r0 = 10
•Removes ringing effects.
Butterworth Low-pass Filter
 False contouring removal and noise suppression.

                     False                    False contour
                     contour due              removal with
                     to                       LPF
                     unadequate               Butterworth
                     quantization




    Original Image         Noisy Image   Filtered Image
Ideal High-pass Filter
  Ideal high-pass filter
             0, jika u 2 + v 2 ≤ r
                                                          r0 = 36
                                    0
H ( u, v ) = 
             1, jika u 2 + v 2 > r0
             




  Original Image   HPF, r0 = 18         HPF, r0 = 36   HPF, r0 = 26
•Ringing effect: property of ideal filter
Butterworth High-pass Filter
 Butterworth high-pass filter

                                                  r0=47, n=2



 n: filter order, r0: cutoff freq.




  Citra asli                r0 = 47   r0 = 36   r0 = 81
•Removes ringing effects.
Iterative based
Edge Enhancement
          T.L.R. Mengko
Pyramid Edge Detection
 There may be a number of strong edges in the image that are not significant,
 because they are short or unconnected.
 Pyramid edge detection is used to enhance substantial (strong & long) edges,
 but to ignore the weak or short edges.




                                    repetitive
                                    shrinkage                    EDGE TRACKING


                                      1.   Cut down to quarter size by averaging 4
                                           corresponding pixels
                                      2.   Repeat x times, keep each generated image
                                      3.   At the smallest image, perform edge detection
                                           (e.g Sobel)
                                      4.   Find edges ? (a threshold is needed)
                                      5.   If yes, perform edge detection on the group of 4
                                           corresponding pixel in the next larger image.
                        averaging     6.   Continue to the next larger image till the largest
                                           image.

More Related Content

PPT
Spatial filtering
PPT
Digital Image Processing_ ch2 enhancement spatial-domain
PPT
Image enhancement
PPTX
IMAGE SEGMENTATION.
DOCX
EDGE DETECTION
PPT
Spatial filtering using image processing
PPTX
Image enhancement techniques
PPT
Spatial filtering
Spatial filtering
Digital Image Processing_ ch2 enhancement spatial-domain
Image enhancement
IMAGE SEGMENTATION.
EDGE DETECTION
Spatial filtering using image processing
Image enhancement techniques
Spatial filtering

What's hot (20)

PPTX
Image enhancement lecture
PPT
Chapter 3 Image Processing: Basic Transformation
PPSX
Image Processing: Spatial filters
PPTX
Image enhancement
PPT
Image segmentation
PPTX
Intensity Transformation
PDF
digital image processing, image processing
PPTX
Chapter 9 morphological image processing
PPSX
Image Enhancement in Spatial Domain
PPT
Thresholding.ppt
PPTX
Image Filtering in the Frequency Domain
PPTX
Introduction to image contrast and enhancement method
PPTX
Chapter 1 and 2 gonzalez and woods
PPT
Enhancement in spatial domain
PPTX
Unit3 dip
PDF
Image processing, Noise, Noise Removal filters
PPTX
Lect 03 - first portion
PPTX
Hough Transform By Md.Nazmul Islam
PPTX
Watershed Segmentation Image Processing
Image enhancement lecture
Chapter 3 Image Processing: Basic Transformation
Image Processing: Spatial filters
Image enhancement
Image segmentation
Intensity Transformation
digital image processing, image processing
Chapter 9 morphological image processing
Image Enhancement in Spatial Domain
Thresholding.ppt
Image Filtering in the Frequency Domain
Introduction to image contrast and enhancement method
Chapter 1 and 2 gonzalez and woods
Enhancement in spatial domain
Unit3 dip
Image processing, Noise, Noise Removal filters
Lect 03 - first portion
Hough Transform By Md.Nazmul Islam
Watershed Segmentation Image Processing

Viewers also liked (20)

PPT
Image enhancement sharpening
PDF
03 image transform
PPT
Introduction to digital image processing
PPT
Image processing
PPT
Digital Image Processing
PDF
FIR filter designing using Matlab
PPT
Pantone Paper
PPSX
Exploring Methods to Improve Edge Detection with Canny Algorithm
PPTX
Fuzzy Logic Based Edge Detection
PDF
Lecture 8
PPT
Image mosaicing
PPTX
Mp3 player working by digital signal processing
PDF
06 object measurement
PDF
Mikrokontroler pertemuan 4
PDF
Mikrokontroler pertemuan 7
PDF
Mikrokontroler pertemuan 8
PDF
Mikrokontroler pertemuan 2
PPTX
Implementation and comparison of Low pass filters in Frequency domain
PDF
Digital image processing using matlab: filters (detail)
PDF
Mikrokontroler pertemuan 3
Image enhancement sharpening
03 image transform
Introduction to digital image processing
Image processing
Digital Image Processing
FIR filter designing using Matlab
Pantone Paper
Exploring Methods to Improve Edge Detection with Canny Algorithm
Fuzzy Logic Based Edge Detection
Lecture 8
Image mosaicing
Mp3 player working by digital signal processing
06 object measurement
Mikrokontroler pertemuan 4
Mikrokontroler pertemuan 7
Mikrokontroler pertemuan 8
Mikrokontroler pertemuan 2
Implementation and comparison of Low pass filters in Frequency domain
Digital image processing using matlab: filters (detail)
Mikrokontroler pertemuan 3

Similar to 04 image enhancement edge detection (20)

PPTX
Image Processing - Unit II - Image Enhancement discussed
PDF
Lec_2_Digital Image Fundamentals.pdf
PPT
Digital Image Processing UNIT-2.ppt
PPTX
2. filtering basics
PPTX
Digital Image Processing
PPTX
PPT
Chapter 1 introduction (Image Processing)
PPTX
ch-2.2 histogram image processing .pptx
PDF
Lecture 5
PPTX
Image Restoration (Digital Image Processing)
PPT
3 intensity transformations and spatial filtering slides
PDF
Image enhancement
PDF
IJCER (www.ijceronline.com) International Journal of computational Engineerin...
PPT
image_enhancement_spatial
PPT
Image Processing using Matlab . Useful for beginners to learn Image Processing
PPTX
Digital Image Processing Fundamental
PDF
Digital Image Processing - Image Enhancement
PDF
Digital image processing - Image Enhancement (MATERIAL)
PPTX
Image enhancement techniques
Image Processing - Unit II - Image Enhancement discussed
Lec_2_Digital Image Fundamentals.pdf
Digital Image Processing UNIT-2.ppt
2. filtering basics
Digital Image Processing
Chapter 1 introduction (Image Processing)
ch-2.2 histogram image processing .pptx
Lecture 5
Image Restoration (Digital Image Processing)
3 intensity transformations and spatial filtering slides
Image enhancement
IJCER (www.ijceronline.com) International Journal of computational Engineerin...
image_enhancement_spatial
Image Processing using Matlab . Useful for beginners to learn Image Processing
Digital Image Processing Fundamental
Digital Image Processing - Image Enhancement
Digital image processing - Image Enhancement (MATERIAL)
Image enhancement techniques

More from Rumah Belajar (20)

PPSX
Image segmentation 2
PPSX
Image segmentation 3 morphology
PPSX
point processing
PDF
02 2d systems matrix
PDF
01 introduction image processing analysis
PDF
Bab 11 bantalan dan sistem pelumasan
PDF
Bab 10 spring arif hary
PDF
Bab 06 kriteria kegagalan lelah
PDF
Bab 09 kekuatan sambungan las
PDF
Bab 08 screws, fasteners and connection syarif
PDF
Bab 07 poros dan aksesoriny
PDF
Bab 05 kriteria kegagalan 1
PDF
Bab 04 tegangan regangan defleksi
PDF
Bab 03 load analysis
PDF
Bab 02 material dan proses
PDF
Bab 11 bantalan dan sistem pelumasan
PDF
Mikrokontroler pertemuan 5
PDF
Mikrokontroler pertemuan 1
PDF
Mikrokontroler pertemuan 6
PPSX
15. ide pata dan sata
Image segmentation 2
Image segmentation 3 morphology
point processing
02 2d systems matrix
01 introduction image processing analysis
Bab 11 bantalan dan sistem pelumasan
Bab 10 spring arif hary
Bab 06 kriteria kegagalan lelah
Bab 09 kekuatan sambungan las
Bab 08 screws, fasteners and connection syarif
Bab 07 poros dan aksesoriny
Bab 05 kriteria kegagalan 1
Bab 04 tegangan regangan defleksi
Bab 03 load analysis
Bab 02 material dan proses
Bab 11 bantalan dan sistem pelumasan
Mikrokontroler pertemuan 5
Mikrokontroler pertemuan 1
Mikrokontroler pertemuan 6
15. ide pata dan sata

Recently uploaded (20)

PDF
Supply Chain Operations Speaking Notes -ICLT Program
PDF
Complications of Minimal Access Surgery at WLH
PDF
Physiotherapy_for_Respiratory_and_Cardiac_Problems WEBBER.pdf
PPTX
Institutional Correction lecture only . . .
PDF
RMMM.pdf make it easy to upload and study
PDF
Black Hat USA 2025 - Micro ICS Summit - ICS/OT Threat Landscape
PPTX
Cell Structure & Organelles in detailed.
PPTX
IMMUNITY IMMUNITY refers to protection against infection, and the immune syst...
PDF
Abdominal Access Techniques with Prof. Dr. R K Mishra
PDF
Classroom Observation Tools for Teachers
PDF
BÀI TẬP BỔ TRỢ 4 KỸ NĂNG TIẾNG ANH 9 GLOBAL SUCCESS - CẢ NĂM - BÁM SÁT FORM Đ...
PPTX
human mycosis Human fungal infections are called human mycosis..pptx
PPTX
Pharma ospi slides which help in ospi learning
PDF
Basic Mud Logging Guide for educational purpose
PDF
VCE English Exam - Section C Student Revision Booklet
PDF
ANTIBIOTICS.pptx.pdf………………… xxxxxxxxxxxxx
PPTX
Microbial diseases, their pathogenesis and prophylaxis
PPTX
master seminar digital applications in india
PDF
102 student loan defaulters named and shamed – Is someone you know on the list?
PDF
O7-L3 Supply Chain Operations - ICLT Program
Supply Chain Operations Speaking Notes -ICLT Program
Complications of Minimal Access Surgery at WLH
Physiotherapy_for_Respiratory_and_Cardiac_Problems WEBBER.pdf
Institutional Correction lecture only . . .
RMMM.pdf make it easy to upload and study
Black Hat USA 2025 - Micro ICS Summit - ICS/OT Threat Landscape
Cell Structure & Organelles in detailed.
IMMUNITY IMMUNITY refers to protection against infection, and the immune syst...
Abdominal Access Techniques with Prof. Dr. R K Mishra
Classroom Observation Tools for Teachers
BÀI TẬP BỔ TRỢ 4 KỸ NĂNG TIẾNG ANH 9 GLOBAL SUCCESS - CẢ NĂM - BÁM SÁT FORM Đ...
human mycosis Human fungal infections are called human mycosis..pptx
Pharma ospi slides which help in ospi learning
Basic Mud Logging Guide for educational purpose
VCE English Exam - Section C Student Revision Booklet
ANTIBIOTICS.pptx.pdf………………… xxxxxxxxxxxxx
Microbial diseases, their pathogenesis and prophylaxis
master seminar digital applications in india
102 student loan defaulters named and shamed – Is someone you know on the list?
O7-L3 Supply Chain Operations - ICLT Program

04 image enhancement edge detection

  • 1. Image Enhancement & Edge Detection Tati R Mengko
  • 2. Introduction Image Enhancement : accentuation and sharpening of image features (edges, boundaries, contrast) to improve image visual appearance and analysis. does not increase information content, but improves feature dynamic range to ease feature detection. Major challenge in image enhancement: quantification of the enhanced feature criterion.
  • 3. Image Enhancement Techniques Image Enhancement Point Spatial Transform Pseudo Operation operation Operation Coloring •Contrast •Noise •Linear Filtering •False Coloring Stretching Smoothing •Root Filtering •Psudocoloring •Noise Clipping •Median Filtering •Homomorphic •Window Slicing •Unsharp Filtering •Histogram Masking Modeling •Low-, High-, Band-pass Filtering •Zooming
  • 4. Point Operation Point Operation zero-memory operation Map graylevel u∈[0,L] to graylevel v∈[0,L], through transform relation v=f(u). Contrast stretching, clipping, thresholding α u, 0≤u<a vb v γ  v =  β ( u − a ) + va , a ≤ u < b β  va γ ( u − b ) + vb , b ≤ u < L α u α and β determination is based on a b L image histogram.
  • 5. Point Operation Contrast stretching Bad contrast: unadequate illumination, sensor non-linearity. In the contrast-stretched area, transforming gradient >1. Special contrast-stretching cases: Clipping: α=γ=0. Thresholding : α=γ=0 , a=b. v v vb v γ β va u u α u a b L stretching clipping tresholding
  • 6. Thresholding Example: Binarization Red Blood Cells Grayscale Image Red Blood Cells Binary Image
  • 7. Thresholding Example: Gamma Correction Original Image Gamma-corrected Image
  • 8. Digital Negative Reversed graylevel scaling: 50 50 100 100 v = L-u 150 150 200 200 250 250 50 100 150 200 250 50 100 150 200 250 %MATLAB I=imread('cameraman.tif'); figure(1);imagesc(I);colormap(gray); figure(2);imagesc(255-double(I)); colormap(gray);
  • 9. Intensity Level Slicing Segment a certain intensity level from the rest of the image. Without background:  L, a ≤ u ≤ b v= 0, lainnya With background:  L, a ≤ u ≤ b v= u , lainnya v v L u u a b a b L
  • 10. Intensity Level Slicing Original image Without background With background
  • 11. Range Compression and Digital Substraction Compress image intensity range: v = c log10(1+|u|) , c = scaling constant Digital Substraction: Detect difference/gradual intensity change between images. Example: Digital Substraction Angiography (DSA).
  • 12. Example of Range Compression
  • 13. Histogram Modeling Image histogram represents distribution of graylevel occurrence in an image. Histogram modeling: modification of an image histogram into a desired shape. Histogram Equalization: uniformly-distribute graylevel occurrence frequency distribution. I = imread('tire.tif');imshow(I); imhist(I,64) J = histeq(I);figure, imshow(J); figure; imhist(J,64) 2000 3000 1800 2500 1600 1400 2000 1200 1500 1000 1000 800 600 500 400 0 200 0 0 50 100 150 200 250 0 50 100 150 200 250 Before hist.equalization After hist.equalization
  • 15. Histogram Equalization Histogram equalization is not appropriate for narrow intensity distribution images. Original Histeq Image Result
  • 16. Spatial Operation Spatial Averaging Pixel intensity is replaced with weighted average of its neighborhood pixels intensity. v ( m, n ) = ∑ ∑ a (k,l ) y (m − k, n − l ) ( k ,l )∈W Spatial averaging: a(k,l) = constant 1 v ( m, n ) = ∑W ∑ y ( m − k , n − l ) NW ( k ,l )∈ a(k,l)=1/NW, NW = number of pixels within filtering window
  • 17. Spatial Operation Alternative method: every pixel is replaced by its 4- closest neioghbors average intensity value : v(m,n) = 0.5 [y(m,n) + 0.25{ y(m-1,n) + y(m+1,n) + y(m,n-1) + y(m,n+1)} ] Averaging ‘ mask’: ¼ ¼ 1/9 1/9 1/9 0 1/8 0 ¼ ¼ 1/9 1/9 1/9 1/8 ¼ 1/8 1/9 1/9 1/9 0 1/8 0 2×2 window 3×3 window 5-points weighted averaging
  • 18. Spatial Operation Spatial averaging: Smoothing Low-pass filtering Subsampling Noisy image: y(m,n) = u(m,n) + η(m,n) η(m,n) = white noise with variance= ση2 Output image: 1 v ( m, n ) = NW ∑ ∑ u ( m − k , n − l ) + η ( m, n ) ( k ,l )∈W η(m,n) = spatial average • If mean(η(m,n)) = 0, noise power suppression level is proportional to the number of pixels in the filtering window: ση2 = ση2/NW.
  • 19. Example of Spatial Operation Original Image Original Image + Noise
  • 20. Example of Spatial Operation
  • 21. Blurring Effect due to Averaging
  • 22. Blurring Effect due to Averaging
  • 23. Effects of Various Noise Energy
  • 24. Effects of Various Noise Energy
  • 25. Median Filter The last examples shows the weakness of averaging method Median filter overcome this problem
  • 27. Image Sharpening Enhance missing delicate structures due to blurring effect. Sharpen graylevel difference between neighbouring pixels in an image. High-pass filtering Shift-invariant operator Convolution mask contains positive number surrounded by negative numbers.  −1 −1 −1 1  −1 8 −1 9  −1 −1 −1  
  • 28. High Pass Filtering Relation between high-pass filtered image g, original image f, and its low-pass filtered version: g(m, n) = f(m, n) – lowpass(f(m, n))
  • 29. High-boost Filtering (Unsharp Masking) Substraction of amplified original image and low-pass fitered original image: g(m, n) = Af(m, n) – lowpass(f(m, n)) = (A-1)f(m, n) + [f(m, n)– lowpass(f(m, n))] = (A-1)f(m, n) + higpass(f(m, n)) Produce an edge-enhanced version of original image. Original Image High pass High boost
  • 30. Derivative Filter Sharpen image boundaries/edges, based on discrete spatial gradient operator: Implemented with 2-D convolution approach: hn = edge detector derivative filter convolution mask
  • 31. Derivative Filter: Roberts Operator Original Image
  • 32. Derivative Filter: Prewitt & Sobel Operator Sobel Prewitt
  • 33. Frequency-domain Method Enhancement conducted in the transform domain, followed by an inverse transform to obtain the spatial domain enhanced image representation. For original image U = {u(m,n)} being transformed into V = {v(k,l)} : V = AUAT. Enhancement operation produces v’(k,l) = f(u(m,n)). Spatial domain enhanced image: U = A-1V’(AT)-1 . Generalized Filtering: zero-memory transformation Pixel-to-pixel multiplication: v’(k, l) = g(k, l) v(k, l). g(k, l) = zonal mask. u(m,n) Transformasi v(k,l) Operasi v’(k,l) Transformasi u’(m,n) Inverse Uniter AUAT Titik f(.) A-1 V’(AT)-1
  • 34. Frequency-domain Method Frequency-domain processing is utilized to accelerate spatial image filtering. Time domain convolution is equivalent to fourier domain (FFT) pixel-to-pixel multiplication: g(m,n) = h(m,n)*f(m,n) ≈ G(u,v) = H(u,v) F(u,v)
  • 35. Ideal Low-pass Filter Ideal low-pass filter: 1, jika u 2 + v 2 ≤ r  r0=57 0 H ( u, v ) =  0, jika u 2 + v 2 > r0  Original Image LPF, r0 = 57 LPF, r0 = 36 LPF, r0 = 26 • Ringing effect: property of ideal filter.
  • 36. Butterworth Low Pass Filter Butterworth low-pass filter: n: order filter, r0: cutoff freq. Original Image r0 = 18 r0 = 13 r0 = 10 •Removes ringing effects.
  • 37. Butterworth Low-pass Filter False contouring removal and noise suppression. False False contour contour due removal with to LPF unadequate Butterworth quantization Original Image Noisy Image Filtered Image
  • 38. Ideal High-pass Filter Ideal high-pass filter 0, jika u 2 + v 2 ≤ r  r0 = 36 0 H ( u, v ) =  1, jika u 2 + v 2 > r0  Original Image HPF, r0 = 18 HPF, r0 = 36 HPF, r0 = 26 •Ringing effect: property of ideal filter
  • 39. Butterworth High-pass Filter Butterworth high-pass filter r0=47, n=2 n: filter order, r0: cutoff freq. Citra asli r0 = 47 r0 = 36 r0 = 81 •Removes ringing effects.
  • 41. Pyramid Edge Detection There may be a number of strong edges in the image that are not significant, because they are short or unconnected. Pyramid edge detection is used to enhance substantial (strong & long) edges, but to ignore the weak or short edges. repetitive shrinkage EDGE TRACKING 1. Cut down to quarter size by averaging 4 corresponding pixels 2. Repeat x times, keep each generated image 3. At the smallest image, perform edge detection (e.g Sobel) 4. Find edges ? (a threshold is needed) 5. If yes, perform edge detection on the group of 4 corresponding pixel in the next larger image. averaging 6. Continue to the next larger image till the largest image.