Research on Obtaining Pepper Phenotypic Parameters Based on Improved YOLOX Algorithm
Yukang Huo, Rui-Feng Wang, Chang-Tao Zhao, Pingfan Hu, Haihua Wang
Abstract
Pepper is a vital crop with extensive agricultural and industrial applications. Accurate phenotypic measurement, including plant height and stem diameter, is essential for assessing yield and quality, yet manual measurement is time-consuming and labor-intensive. This study proposes a deep learning-based phenotypic measurement method for peppers. A Pepper-mini dataset was constructed using offline augmentation. To address challenges in multi-plant growth environments, an improved YOLOX-tiny detection model incorporating a CA attention mechanism was developed, achieving a mAP of 95.16%. A detection box filtering method based on Euclidean distance was introduced to identify target plants. Further processing using HSV threshold segmentation, morphological operations, and connected component denoising enabled accurate region selection. Measurement algorithms were then applied, yielding high correlations with true values: R2 = 0.973 for plant height and R2 = 0.842 for stem diameter, with average errors of 0.443 cm and 0.0765 mm, respectively. This approach demonstrates a robust and efficient solution for automated phenotypic analysis in pepper cultivation.