What is a color structure histogram, and how is it different from a regular color histogram?

Asked 1/8/2015

5 views

2 answers

0

I understand a standard histogram can show the distribution of tones or RGB values in an image, but what exactly is a color structure histogram? How does it work, and how is it different from a regular color histogram that only counts how many pixels of each color are present?

Originally by Photography Stack Exchange contributor. Source · Licensed CC BY-SA 4.0

Photography Stack Exchange contributor

11y ago

2 Answers

2

A great answer to this question was posted on Quora by Kadir A. Peker:

Color structure histogram was proposed to alleviate the problem of the regular histogram that it reflects nothing of the spatial distribution of the colors in the image. That is, given a color histogram, the colors could be each lumped as blobs of colors, or they could be randomly distributed all over the image where each pixel is a different color; the color histogram will tell you nothing about this "structure".

The proposed histogram works as follows: You have a "structuring element", basically a kernel or a sliding window, that you slide over your image just like when filtering. At each position of the structuring element, you check whether color X appears in the window, and increment its bin value if it does. You do this for all colors in your histogram.

The effect of this process, i.e. using a window to count colors rather than counting them pixel by pixel is as follows: If a color is distributed all over the image, then each pixel of that color appears in a sliding window (many times actually, as the window slides over it) by itself. So, each single pixel contributes significantly. If, on the other hand, the color appears as a single blob in the image, then the pixels of that color count only as one in the bin when the sliding window is on top of them. So, in short, color structure histogram boosts the weight of a color in the histogram if that color is well distributed over the image rather than accumulated at a single location.

(FYI: Quora allows content to be reproduced on other sites, as long as you attribute the author properly)

There is also a good visualization of the scanning process in the following presentation:

enter image description here

Originally by user59187. Source · Licensed CC BY-SA 4.0

user59187

8y ago

0

AI Answer

Generated from our catalog & community — verify before relying on it.

A color structure histogram is a variant of a color histogram designed to include some spatial information, not just color counts.

A regular color histogram tells you how much of each color appears in an image, but it says nothing about where those colors are or how they are arranged. Two images can have very similar color histograms even if one has large solid color regions and the other has the same colors scattered throughout.

A color structure histogram addresses this by sliding a small window (a structuring element) across the image. At each window position, it checks whether a given color is present anywhere inside that window; if so, that color’s bin is incremented. This means it records how often colors appear within local neighborhoods, giving some sense of image structure and spatial distribution.

By contrast, the RGB or luminance histograms shown in cameras and editing software are mainly used for exposure and tonal analysis, not for describing spatial color arrangement.

UniqueBot

AI

11y ago

Your Answer