lecture3_contrast_enhancement

lecture3_contrast_enhancement - Contrast Enhancement Yao...

Info iconThis preview shows pages 1–13. Sign up to view the full content.

View Full Document Right Arrow Icon
Contrast Enhancement Yao Wang olytechnic University Brooklyn NY 11201 Polytechnic University, Brooklyn, NY 11201 With contribution from Zhu Liu, Onur Guleryuz, and Gonzalez/Woods, Digital Image Processing, 2ed
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Lecture Outline Introduction inear stretching Linear stretching Nonlinear stretching Histogram equalization istogram specification Histogram specification Adaptive histogram modification Yao Wang, NYU-Poly EL5123: Contrast Enhancement 2
Background image of page 2
What is Contrast Enhancement riginal image with low contrast nhanced image Yao Wang, NYU-Poly EL5123: Contrast Enhancement 3 Original image with low contrast Enhanced image
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
How to enhance the contrast • Low contrast image values concentrated near a narrow range (mostly dark, or mostly bright, or mostly medium values) ontrast enhancement hange the image value Contrast enhancement change the image value distribution to cover a wide range Contrast of an image can be revealed by its histogram Yao Wang, NYU-Poly EL5123: Contrast Enhancement 4
Background image of page 4
Histogram Histogram of a monochrome image with L ossible gray levels f = 0 1 L possible gray levels, f = 0, 1, …, L-1. P(l) = n l / n, the number of pixels with gray level l n l is the number of pixels with gray level l. n is the total number of pixels in the image. Yao Wang, NYU-Poly EL5123: Contrast Enhancement 5
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Histogram Calculation function h = histogram(imgname) img = imread(imgname); figure; imshow(img); % method 2 img = double(img); = zeros(256 1); % method 1 h = zeros(256,1); r l = 0:255 h = zeros(256,1); for i=1:M, for j=1:N, f = img(i,j); for l 0:255 for i = 1:N, for j = 1:M, if img(i, j) == l, h(f+1) = h(f+1) + 1; end end h(l + 1) = h(l + 1) + 1; end end nd % method 3 h = zeros(256,1); for l = 0 : 255, Photoshop has extensive histogram display tools end end figure; bar(h); h(l + 1)=sum(sum(img == l)); end Yao Wang, NYU-Poly EL5123: Contrast Enhancement 6 otos op ase te s e stoga dspaytoos Matlab: imhist ( ): can compute and display histograms
Background image of page 6
istogram vs Histogram vs. Image Contrast Images with figure captions in this nd other slides are from and other slides are from [Gonzalez02]
Background image of page 7

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Examples of Histograms p(f) p(f) p(f) f f f Yao Wang, NYU-Poly EL5123: Contrast Enhancement 8 (a) Too dark (b) Too bright (c) Well balanced
Background image of page 8
Very Different Images May Have Same Histogram! Histogram reflects the pixel intensity Yao Wang, NYU-Poly EL5123: Contrast Enhancement 9 distribution, not the spatial distribution!
Background image of page 9

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Previous Example riginal image with low contrast nhanced image Yao Wang, NYU-Poly EL5123: Contrast Enhancement 10 Original image with low contrast Enhanced image
Background image of page 10
Histograms of Example Images 1400 1600 400 1600 00 1000 1200 00 1000 1200 1400 400 600 800 400 600 800 0 50 100 150 200 250 0 200 0 50 100 150 200 250 0 200 Original girl image with low contrast Enhancement image with histogram equalization Yao Wang, NYU-Poly EL5123: Contrast Enhancement 11
Background image of page 11

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
How to change the histogram? Using Point-Wise Transformation Use a “function” g(f) to generate a new image B from a given image A via: The function g ( f ) operates on each image pixel dependently All pixels with original gray level f 1 ,..., 0 , 1 ,..., 0 )), , ( ( ) , ( M j N i j i A g j i B independently. All pixels with original gray level f
Background image of page 12
Image of page 13
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 01/22/2012 for the course EL 5123 taught by Professor Yaowang during the Fall '07 term at NYU Poly.

Page1 / 46

lecture3_contrast_enhancement - Contrast Enhancement Yao...

This preview shows document pages 1 - 13. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online