Histogram Equalization And Specification

  • Uploaded by: Azwar Tamim
  • 0
  • 0
  • June 2020
  • PDF

This document was uploaded by user and they confirmed that they have the permission to share it. If you are author or own the copyright of this book, please report to us by using this DMCA report form. Report DMCA


Overview

Download & View Histogram Equalization And Specification as PDF for free.

More details

  • Words: 436
  • Pages: 2
Histogram Equalization The goal of histogram equalization is to have a “flat” histogram, or a histogram as flat as possible. For an image with nr rows and nc columns, the ideal histogram with N bins nr * nc would have b = pixels in each bin. For example, if an image has 16 rows and 16 N columns, and 8 (0-7) possible gray levels, then each histogram bin (level) should have 16 x16 b= = 32 pixels. 8

Histogram equalization requires the following rule: The total number of pixels having a value k or less in the image will not be less that the ideal value of kb . Let hist be the gray-level histogram for an image. The number of pixels in hist with value k or less is called the cumulative sum. The cumulative sum is calculated according to the following equation: k
CS [i ] = ∑ hist[k ]

(1)

k =0

for all possible values of i.

Histogram Specification Histogram specification is a technique that transforms the histogram of one image into the histogram of another image. This transformation can be easily accomplished by recognizing that if instead of using an equally spaced ideal histogram (as in histogram equalization), one is specified explicitly. In this way it is possible to impose an arbitrary histogram on any image, subject to the constraint that single bins may not be split up. The technique can be implemented in the following steps: 1. Provide the template histogram. This can be accomplished by specifying a particular histogram shape, or by calculating the histogram of a target image. 2. Calculate the histogram of the image to be transformed. 3. Calculate the cumulative sum of the template histogram. This is the ideal cumulative sum (not the linear line as in histogram equalization). 4. Calculate the cumulative sum of the histogram of the image to be changed. 5. Map pixels from one bin to another according to the rules of histogram equalization. The primary rule is that the actual cumulative sum can be no less than the ideal (template) cumulative sum.

Histogram specification always imposes a template histogram on an image, but the technique works best if the template histogram is already similar to the actual one. For example, in situations where a large number of images of the same kind are being processed, it may be advantageous to make the histograms the same. In this way, the same set of image operations would have the same results. This is almost always the case when processing images from modern medical devices such as CT, MR, PET, or multidimensional ultrasound.

Related Documents


More Documents from ""