The bimodal method can automatically obtain the optimal segmentation threshold of the image, which is suitable for all gray image binarization tasks.