1 / 34

CIS 601 – 04 Image ENHANCEMENT in the SPATIAL DOMAIN Longin Jan Latecki

CIS 601 – 04 Image ENHANCEMENT in the SPATIAL DOMAIN Longin Jan Latecki. Based on Slides by Dr. Rolf Lakaemper. Most of these slides base on the textbook Digital Image Processing by Gonzales/Woods/Eddins Chapter 3. Introduction. Image Enhancement ? Enhance otherwise hidden information

elina
Download Presentation

CIS 601 – 04 Image ENHANCEMENT in the SPATIAL DOMAIN Longin Jan Latecki

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. CIS 601 – 04 Image ENHANCEMENT in the SPATIAL DOMAIN Longin Jan Latecki Based on Slides by Dr. Rolf Lakaemper

  2. Most of these slides base on the textbook Digital Image Processing by Gonzales/Woods/Eddins Chapter 3

  3. Introduction • Image Enhancement ? • Enhance otherwise hidden information • Filter important image features • Discard unimportant image features • Spatial Domain ? • Refers to the image plane (the ‘natural’ image) • Direct image manipulation

  4. Remember ? A 2D gray value - image is a 2D -> 1D function, v = f(x,y)

  5. Remember ? As we have a function, we can apply operators to this function, e.g. T(f(x,y)) = f(x,y) / 2 Operator Image (= function !)

  6. Remember ? T transforms the given image f(x,y) into another image g(x,y) T f(x,y) g(x,y)

  7. Spatial Domain • The operator T can be defined over • The set of pixels (x,y) of the image • The set of ‘neighborhoods’ N(x,y) of each pixel • A set of images f1,f2,f3,…

  8. Spatial Domain Operation on the set of image-pixels 6 8 2 0 3 4 1 0 12 200 20 10 6 100 10 5 (Operator: Div. by 2)

  9. 6 8 12 200 Spatial Domain Operation on the set of ‘neighbourhoods’ N(x,y) of each pixel (Operator: sum) 6 8 2 0 226 12 200 20 10

  10. Spatial Domain Operation on a set of images f1,f2,… 6 8 2 0 12 200 20 10 11 13 3 0 (Operator: sum) 14 220 23 14 5 5 1 0 2 20 3 4

  11. Spatial Domain • Operation on the set of image-pixels • Remark: these operations can also be seen as operations on the neighborhood of a pixel (x,y), by defining the neighborhood as the pixel itself. • The easiest case of operators • g(x,y) = T(f(x,y)) depends only on the value of f at (x,y) • T is called a • gray-level or intensity transformation function

  12. Transformations • Basic Gray Level Transformations • Image Negatives • Log Transformations • Power Law Transformations • Piecewise-Linear Transformation Functions • For the following slides L denotes the max. possible gray value of the image, i.e. f(x,y)  [0,L]

  13. Transformations Image Negatives: T(f)= L-f T(f)=L-f Output gray level Input gray level

  14. Transformations Log Transformations: T(f) = c * log (1+ f)

  15. Transformations Log Transformations InvLog Log

  16. Transformations Log Transformations

  17. Transformations Power Law Transformations T(f) = c*f 

  18. Transformations • varying gamma () obtains family of possible transformation curves •  > 1 • Compresses dark values • Expands bright values •  < 1 • Expands dark values • Compresses bright values

  19. Transformations • Used for gamma-correction

  20. Transformations • Used for general purpose contrast manipulation

  21. Transformations Piecewise Linear Transformations

  22. Piecewise Linear Transformations Thresholding Function g(x,y) = L if f(x,y) > t, 0 else t = ‘threshold level’ Output gray level Input gray level

  23. Piecewise Linear Transformations • Gray Level Slicing • Purpose: Highlight a specific range of grayvalues • Two approaches: • Display high value for range of interest, low value else (‘discard background’) • Display high value for range of interest, original value else (‘preserve background’)

  24. Piecewise Linear Transformations Gray Level Slicing

  25. Image Histogram (3, 8, 5)

  26. Image histogram is a vector If f:[1, n]x[1, m]  [0, 255] is a gray value image, then H(f): [0, 255]  [0, n*m] is its histogram, where H(f)(k) is the number of pixels (i, j)such that F(i, j)=k Similar images have similar histograms Warning: Different images can have similar histograms

  27. Histograms Histogram Processing 1 4 5 0 3 1 5 1 Number of Pixels gray level

  28. Hg Hr Hb

  29. Histogram Equalization Let h=[n1, n2, …, nG] be an image histogram, i.e., h(rk)=nk for rk is kth intensity level in interval [0,G] Normalized histogram is a probability density function (PDF) : p(rk) = h(rk) / n = nk / n - probability of occurrence of intensity level rk, where n is the total number of pixels. Equalized histogram is a cumulative distribution function (CDP):

  30. Implement in Matlab histogram equalization and Find an example image for which histogram equalization improves its quality Find an example image for which histogram equalization degrades its quality Homework 2

More Related