Histogram Equalization

Slides:



Advertisements
Similar presentations
Point Processing Histograms. Histogram Equalization Histogram equalization is a powerful point processing enhancement technique that seeks to optimize.
Advertisements

Chapter 3 Image Enhancement in the Spatial Domain.
Chapter - 2 IMAGE ENHANCEMENT
Histogram Specification
Topic 4 - Image Mapping - I DIGITAL IMAGING Course 3624 Department of Physics and Astronomy Professor Bob Warwick.
Intensity Transformations (Chapter 3)
HISTOGRAM TRANSFORMATION IN IMAGE PROCESSING AND ITS APPLICATIONS Attila Kuba University of Szeged.
EE663 Image Processing Histogram Equalization Dr. Samir H. Abdul-Jauwad Electrical Engineering Department King Fahd University of Petroleum & Minerals.
Digital Image Processing
Histogram Processing The histogram of a digital image with gray levels from 0 to L-1 is a discrete function h(rk)=nk, where: rk is the kth gray level nk.
Image Enhancement in the Spatial Domain II Jen-Chang Liu, 2006.
Image Enhancement in the Spatial Domain
HISTOGRAM TRANSFORMATION IN IMAGE PROCESSING SHINTA P TEKNIK INFORMATIKA STMIK MDP 2011.
Digital Image Processing & Pattern Analysis (CSCE 563) Intensity Transformations Prof. Amr Goneid Department of Computer Science & Engineering The American.
Lecture 4 Digital Image Enhancement
Basis beeldverwerking (8D040) dr. Andrea Fuster Prof.dr. Bart ter Haar Romeny Prof.dr.ir. Marcel Breeuwer dr. Anna Vilanova Histogram equalization.
EEE 498/591- Real-Time DSP1 What is image processing? x(t 1,t 2 ) : ANALOG SIGNAL x : real value (t 1,t 2 ) : pair of real continuous space (time) variables.
Continuous Random Variables and Probability Distributions
Digital Image Processing
CS 376b Introduction to Computer Vision 02 / 25 / 2008 Instructor: Michael Eckmann.
Lecture 4 Digital Image Enhancement
 Image Enhancement in Spatial Domain.  Spatial domain process on images can be described as g(x, y) = T[f(x, y)] ◦ where f(x,y) is the input image,
Digital Image Processing
Continuous Probability Distributions  Continuous Random Variable  A random variable whose space (set of possible values) is an entire interval of numbers.
K. Shum Lecture 16 Description of random variables: pdf, cdf. Expectation. Variance.
Digital Image Processing Contrast Enhancement: Part I
Modular 11 Ch 7.1 to 7.2 Part I. Ch 7.1 Uniform and Normal Distribution Recall: Discrete random variable probability distribution For a continued random.
Digital Image Processing Lecture 4: Image Enhancement: Point Processing Prof. Charlene Tsai.
CS654: Digital Image Analysis Lecture 18: Image Enhancement in Spatial Domain (Histogram)
Intensity Transformations (Histogram Processing)
Random Variable The outcome of an experiment need not be a number, for example, the outcome when a coin is tossed can be 'heads' or 'tails'. However, we.
Discrete Random Variables. Introduction In previous lectures we established a foundation of the probability theory; we applied the probability theory.
Digital Image Processing Lecture 4: Image Enhancement: Point Processing January 13, 2004 Prof. Charlene Tsai.
EE 7730 Image Enhancement. Bahadir K. Gunturk2 Image Enhancement The objective of image enhancement is to process an image so that the result is more.
Lecture Six Figures from Gonzalez and Woods, Digital Image Processing, Second Edition, Copyright 2002.
Thanks to David Jacobs for the use of some slides
Cumulative distribution functions and expected values
IMAGE ENHANCEMENT TECHNIQUES
Image Enhancement.
3.1 Expectation Expectation Example
Intensity Transformations and Spatial Filtering
Digital Image Processing
Histogram Histogram is a graph that shows frequency of anything. Histograms usually have bars that represent frequency of occuring of data. Histogram has.
Image Processing – Contrast Enhancement
Image Enhancement in the Spatial Domain
Lecture Five Figures from Gonzalez and Woods, Digital Image Processing, Second edition, Prentice-Hall,2002.
CSC 381/481 Quarter: Fall 03/04 Daniela Stan Raicu
Digital Image Processing
Histogram Probability distribution of the different grays in an image.
3.0 Functions of One Random Variable
Chapter 3 Image Enhancement in the Spatial Domain
Functions of Random variables
Digital Image Processing Week III
Digital Image Procesing Introduction to Image Enhancement Histogram Processing DR TANIA STATHAKI READER (ASSOCIATE PROFFESOR) IN SIGNAL PROCESSING IMPERIAL.
Grey Level Enhancement
Statistical analysis and its application
Random Variate Generation
IT523 Digital Image Processing
Lecture 6 Histogram processing.
9. Two Functions of Two Random Variables
IT523 Digital Image Processing
Further Topics on Random Variables: Derived Distributions
The spatial domain processes discussed in this chapter are denoted by the expression
Further Topics on Random Variables: Derived Distributions
Experiments, Outcomes, Events and Random Variables: A Revisit
Image Enhancement in the Spatial Domain
Further Topics on Random Variables: Derived Distributions
Generating Random Variates
Continuous Random Variables: Basics
Presentation transcript:

Histogram Equalization Good afternoon and thank you everyone for coming. My talk today will describe the research I performed at the IRIS at USC, the object of this work being to build a computational framework that addresses the problem of motion analysis and interpretation.

Image Enhancement: Histogram Based Methods What is the histogram of a digital image? · The histogram of a digital image with gray values is the discrete function nk: Number of pixels with gray value rk n: total Number of pixels in the image · The function p(rk) represents the fraction of the total number of pixels with gray value rk.

· Histogram provides a global description of the appearance of the image. · If we consider the gray values in the image as realizations of a random variable R, with some probability density, histogram provides an approximation to this probability density. In other words,

Some Typical Histograms · The shape of a histogram provides useful information for contrast enhancement. Dark image

Bright image Low contrast image

High contrast image

Histogram Equalization · What is the histogram equalization? · The histogram equalization is an approach to enhance a given image. The approach is to design a transformation T(.) such that the gray values in the output is uniformly distributed in [0, 1]. · Let us assume for the moment that the input image to be enhanced has continuous gray values, with r = 0 representing black and r = 1 representing white. · We need to design a gray value transformation s = T(r), based on the histogram of the input image, which will enhance the image.

· As before, we assume that: (1) T(r) is a monotonically increasing function for 0 £ r £ 1 (preserves order from black to white). (2) T(r) maps [0,1] into [0,1] (preserves the range of allowed Gray values).

· Let us denote the inverse transformation by r = T -1(s) . We assume that the inverse transformation also satisfies the above two conditions. · We consider the gray values in the input image and output image as random variables in the interval [0, 1]. · Let pin(r) and pout(s) denote the probability density of the Gray values in the input and output images.

· If pin(r) and T(r) are known, and r = T -1(s) satisfies condition 1, we can write (result from probability theory): · One way to enhance the image is to design a transformation T(.) such that the gray values in the output is uniformly distributed in [0, 1], i.e. pout (s) = 1, 0 £ s £1 · In terms of histograms, the output image will have all gray values in “equal proportion” . · This technique is called histogram equalization.

Next we derive the gray values in the output uniformly distributed in [0, 1]. ·Consider the transformation · Note that this is the cumulative distribution function (CDF) of pin (r) and satisfies the previous two conditions. · From the previous equation and using the fundamental theorem of calculus,

· Therefore, the output histogram is given by · The output probability density function is uniform, regardless of the input. · Thus, using a transformation function equal to the CDF of input gray values r, we can obtain an image with uniform gray values. · This usually results in an enhanced image, with an increase in the dynamic range of pixel values.

How to implement histogram equalization? Step 1:For images with discrete gray values, compute: L: Total number of gray levels nk: Number of pixels with gray value rk n: Total number of pixels in the image Step 2: Based on CDF, compute the discrete version of the previous transformation :

Example: · Consider an 8-level 64 x 64 image with gray values (0, 1, …, 7). The normalized gray values are (0, 1/7, 2/7, …, 1). The normalized histogram is given below: NB: The gray values in output are also (0, 1/7, 2/7, …, 1).

Normalized gray value Fraction of # pixels Gray value # pixels

· Applying the transformation, we have

· Notice that there are only five distinct gray levels --- (1/7, 3/7, 5/7, 6/7, 1) in the output image. We will relabel them as (s0, s1, …, s4 ). · With this transformation, the output image will have histogram

Histogram of output image # pixels Gray values · Note that the histogram of output image is only approximately, and not exactly, uniform. This should not be surprising, since there is no result that claims uniformity in the discrete case.

Original image and its histogram Example Original image and its histogram

Histogram equalized image and its histogram

· Comments: Histogram equalization may not always produce desirable results, particularly if the given histogram is very narrow. It can produce false edges and regions. It can also increase image “graininess” and “patchiness.”