Histogram equalization is to distribute a certain gray range of the original image evenly in the gray range of all the images. The image can be stretched nonlinear and the pixel value of the image can be reallocated so that the number of pixels on the image is about the same in a certain gray range. Its essence is to change the histogram distribution of a given image into a "uniform" histogram distribution.