CS 654 Digital Image Analysis Lecture 18 Image
- Slides: 25
CS 654: Digital Image Analysis Lecture 18: Image Enhancement in Spatial Domain (Histogram)
Recap of Lecture 17 • Image enhancement • Dynamic range • Point processing • Contrast stretching • Intensity level slicing
Outline of Lecture 18 • Image histogram • Histogram stretching • Histogram equalization • Histogram specification
Histogram • It is a graphical representation of the distribution of numerical data. • It is an estimate of the probability distribution of a continuous variable • Divide the entire range of values into a series of intervals • Count how many values fall into each interval. • The bins (intervals) must be adjacent, non-overlapping and are usually equal size
Example
Shape of histogram Symmetric, unimodal Skewed, right Skewed, left Bimodal Multimodal Symmetric
Intensity Histogram • Histogram of the pixel intensity values. • Number of pixels in an image at each different intensity value found in that image Demonstration
Images: Gonzalez & Woods, 3 rd edition Basic types of images Dark Light Low-contrast High-contrast
Histogram stretching • Contrast is the difference between maximum and minimum pixel intensity. • Histogram stretching increases contrast • Failing of histogram stretching • Histogram equalization Demonstration
PMF and CDF • PMF: Probability of each number in the data set • The count or frequency of each element. • Monotonically increasing function • CDF: cumulative sum of all the values that are calculated by PMF
Images: Gonzalez & Woods, 3 rd edition Mapping functions Monotonically increasing Strictly Monotonically increasing
Histogram Equalization • Histogram equalization is used to enhance contrast. • Not necessary that contrast will always be increase • Some cases were histogram equalization can be worse
Images: Gonzalez & Woods, 3 rd edition Uniform PDF generation
Algorithm •
Histogram Equalization Process 1. Calculate the PMF of the given image 2. Calculation of CDF 3. Multiply the CDF value with (Grey levels (minus) 1) 4. Map the new grey level values into number of pixels
Example 4 4 4 3 4 5 4 3 I F(I) PMF CDF 3 5 5 5 3 CDF * ~L Mapping (L-1) 3 4 5 4 3 0 0 0 0 4 4 4 1 0 0 0 6 Input image 2 0 0 0 3 6 0. 24 1. 68 1 0 5 5 5 4 14 0. 56 0. 80 5. 6 5 0 1 5 7 5 1 5 5 0. 2 1 7 7 14 1 7 7 7 1 6 0 0 1 7 7 0 1 5 5 5 1 7 0 0 1 7 7 5 5 5 Equalized image
Example: Alternate method 4 4 4 3 4 5 4 3 I F(I) CDF F(Id) CDF (Id) 3 5 5 5 3 ~L Mapping 3 4 5 4 3 0 0 0 3 3 0 0 4 4 4 1 0 0 3 6 0 6 Input image 2 0 0 3 9 0 0 3 6 6 3 12 1 0 5 5 5 4 14 20 4 16 5 0 1 5 7 5 1 5 5 25 3 19 7 14 1 7 7 7 1 6 0 25 3 22 7 0 1 5 5 5 1 7 0 25 3 25 7 5 5 5 Equalized image
Histogram Specification/ Matching • Histogram equalization produces (in theory) image with uniform distribution of pixel intensities • To enhance image based on a specified histogram: Histogram Specification • Histogram matching: transform a given image into a similar image that has a pre-defined histogram • A desired histogram can be specified according to various needs • Allows interactive image enhancement
Steps of Histogram Specification •
Example 0. 3 0. 25 0. 21 0. 2 0. 19 0. 2 0. 16 0. 15 0. 08 0. 06 0. 05 0. 03 0 0 1 0. 02 0 2 3 Input 4 Specified 5 6 7
Example Graylevel Input Image PDF CDF Mapping Specified Image PDF CDF 0 0. 19 33 0. 0 1 0. 25 0. 44 4 0. 0 2 0. 21 0. 65 5 0. 0 3 0. 16 0. 81 6 0. 15 4 0. 08 0. 89 6 0. 20 0. 35 5 0. 06 0. 95 7 0. 30 0. 65 6 0. 03 0. 98 7 0. 20 0. 85 7 0. 02 1. 0 7 0. 15 1. 0
Example: Final result 0. 3 0. 25 0. 2 0. 15 0. 1 0. 05 0 0 1 Input 2 3 Specified 4 5 Resultant 6 7
Image quality metrics •
Issues MSE=309 MSE=306 MSE=313 MSE=309 MSE=308 MSE=309
Thank you Next lecture: Image Enhancement: Spatial Filters
- Math 55
- Adding significant figures
- 654
- Ece 654
- 01:640:244 lecture notes - lecture 15: plat, idah, farad
- Image transform in digital image processing
- Optimum notch filter in image processing
- Image compression in digital image processing
- Image segmentation in digital image processing
- Analog image and digital image
- Error free compression
- Image sharpening and restoration
- Geometric transformation in digital image processing
- Steps of image processing
- Image transforms in digital image processing
- Maketform matlab
- Image restoration in digital image processing
- Image processing lecture notes
- Fluorocein
- Exploratory data analysis lecture notes
- Sensitivity analysis lecture notes
- Factor analysis lecture notes
- Analysis of algorithms lecture notes
- Quadrant streak
- Power system analysis lecture notes
- Apakah yang dimaksud dengan warga digital?