Summary
In this chapter, we had a walk-through of the methods of histogram equalization and CLAHE in grayscale and color images. For color images, we implemented these methods in the RGB, LAB, and HSV color spaces. We concluded that CLAHE outperforms simple histogram equalization for both grayscale and color images. We also saw that for color images, the histogram equalization of the R, G, and B planes in the BGR color space introduces artifacts because color information is independently changed in all these planes. Hence, it is always best to do histogram equalization for color images in the HSV or LAB color spaces, because the color information is separated from the intensity information and the color planes are not changed.
In the next chapter, you will learn about contours and how contour detection is a handy technique for fetching objects of interest from an image. You will learn how you can select certain objects from an image according to their shape and hierarchy.