Color Theory in Computer Vision
Last Updated on November 16, 2020 by Editorial Team
Author(s): Akula Hemanth Kumar
Making computer vision easy with Monk, a low code Deep Learning tool, and a unified wrapper for Computer Vision.
History of Color theory:
Color model from the book “Theory of Colors” by Johann Wolfgang.
Proof as to why RYB was Considered to be primary colors
- Also known as Young-Helmholtz theory.
Three types of cone photoreceptors
RGB Space Spanning
Opponent color theory
- There are colors not directly perceivable in normal lighting conditions.
- The trichromatic theory fails to incorporate these colors.
- The opponent-process works through excitatory and inhibitory responses, with the two components of each mechanism opposing each other.
- Monochromatic Single Channel
- Pixel values from 0(Black) to 255(White)
- Grayscale images contain only shades of gray.
- Less data complexity and storage requirements
- Many applications work well with gray scales. Complex channels are not required.
- Improved computation speeds.
- The additive color space is based on the RGB color model.
- Three Channels Red, Green, and Blue.
- Used in many image processing and computer vision applications.
Accessing channels of RGB image using OpenCV
Additive and Subtractive Color Theory
Convert RGB to CMYK using PIL
L -Lightness ( Intensity)
a -Green to Magenta
b -Blue to Yellow
Convert RGB to LAB using SkImage
Y-Luminance , Cr -Red, Cb -Blue
- Resemblance with YUV mode
Convert RGB to YCrCb using SkImage
Convert RGB to XYZ using SkImage
Convert RGB to HSV using Skimage
Other Color Spaces
- CIE-LCH color space
- YUV color space
- YIQ color space
- Stain color space
- HSL color space
You can find the complete jupyter notebook here.
If you have any questions, you can reach Abhishek. Feel free to reach out to him.
You can also see my other writings at:
Published via Towards AI