Analyzing the Impact of Histogram-Based Image Preprocessing on Melon Leaf Abnormality Detection Using YOLOv7

Analyzing the Impact of Histogram-Based Image Preprocessing on Melon Leaf Abnormality Detection Using YOLOv7

01 Jun 2025 Image Processing
Abstract: This study aims to analyze and implement image preprocessing techniques to improve the performance of melon leaf abnormality detection using the YOLOv7 algorithm. A total of 521 abnormal melon leaf images were processed using augmentation and three preprocessing methods: Averaging Histogram Equalization (AVGHEQ), Brightness Preserving Dynamic Histogram Equalization (BPDFHE), and Contrast Limited Adaptive Histogram Equalization (CLAHE), then compared with the original dataset. Modeling was conducted in three stages: initial training with an 80:20 split and default YOLOv7 augmentation; hyperparameter tuning via cross-validation using a 90:10 split without augmentation; and final training using the best parameters with augmentation reactivated. The models were evaluated using ensemble learning. Results showed mAP ranged from 58.6% to 66.3%, accuracy from 80.7% to 84.9%, and detection time from 9.8 to 20 milliseconds. Preprocessing improved mAP and detection time, though it had little effect on accuracy. The best performance was obtained with a kernel size of 3 and a learning rate of 0.001, while changes in activation function, pooling, batch size, and momentum had minimal impact. The top models, trained with maximum epochs and standard augmentation, achieved mAP of 84.12%, accuracy of 91.19%, and detection time of 4.55 milliseconds. Models using early stopping (patience = 300) reached mAP of 81.57%, accuracy of 92.23%, and detection time of 5.03 milliseconds. The best model outperformed previous works, which reported only 48.85% with Faster R-CNN, 33.16% with SSD, and 16.56% with YOLOv3. Although histogram-based preprocessing methods mainly enhanced inference speed, the overall improvements to YOLOv7 significantly boosted detection performance.
← Back to Journals