Here are 3 different format for images:
- RGB
- YUV
- HSV
- HSI
RGB (Red, Green, Blue)
- RGB is the standard additive hardware color space
- It represents how camera sensors physically capture light and how monitors display it
- However, because color and brightness are mixed across all three channels, it is highly sensitive to lighting changes and shadows, making color-based segmentation difficult.
YUV: Luminance (Y) and Chrominance (U and V)
- YUV is split into:
- Brightness which is Luminance (Y) channel
- Color details into two Chrominance (U and V) channels
- By separating brightness, video codecs and television broadcasts use YUV to discard redundant color details that the human eye doesn't easily notice (known as chroma subsampling), saving massive amounts of bandwidth.
HSV (Hue, Saturation, Value)
- HSV (Hue, Saturation, Value) is a cylindrical coordinate model that matches human visual perception.
- By separating the type of color (Hue) from its purity (Saturation) and brightness (Value), it is highly robust to shadows and reflections.
- This makes it the gold standard in computer vision for color-based object tracking and thresholding.
HSI (Hue, Saturation, Intensity)
- Also a cylindrical coordinate model
- H (which colour), S (how vivid) represents what colour it is
- In the colour wheel, Hue represents the angle will saturation represents the radius
- I represents how bright
- HSI and HSV differ in the way they calculate brightness components differently
- HSI way of calculating intensity is by averaging all the RGB of a particular pixel
- But HSV way of calculating HSV is by finding the maximum of the red, green or blue colour channels
- For a fully red pixel, in HSV terms, the value, is 255. Whereas for HSI's Intensity is