Abstract:In response to the lack of specific missing seedling data for the transverse replanting machine of pre-cut double bud sugarcane segments, resulting in poor replanting efficiency, a method for locating missing ratoon sugarcane seedlings based on UAV RGB images was proposed. Firstly, high-resolution images of ratoon sugarcane seedlings in the field were rapidly captured by using UAVs, which were then segmented into multiple sub-images and subjected to data augmentation to construct a dataset. Secondly, enhancements to the YOLO v5s model involved the introduction of P2 small target feature layers and DyHead modules to improve the detection accuracy of small seedling targets. Additionally, an image weighting strategy was employed during training to address sample imbalance issues and further improve detection accuracy, especially for occluded seedlings. Subsequently, a framework incorporating sliced-assisted inference facilitated the detection of ratoon sugarcane seedlings in large-scale field images by using the trained model. Finally, a row recognition algorithm based on an improved DBSCAN clustering algorithm and PCA fitting algorithm was developed to locate missing seedling positions along crop rows. Experimental results demonstrated that the improved ratoon sugarcane seedling detection model achieved an average detection accuracy of 96.8% on sub-images and recognition precision and recall rates of 94.5% and 91.8%, respectively, on large-scale images, with a detection time of 0.32s. Utilizing the detection coordinates, the row recognition algorithm achieved 100% clustering accuracy, with an average angular error of 0.2455° for fitted row angles, and precision and recall rates of 91.9% and 97.1%, respectively, for missing seedling detection along rows. This method can be applied to intelligent missing seedling localization in large-scale, complex field images of ratoon sugarcane, providing technical support for replanting operations and holding significant implications for extending ratoon lifespan and increasing sugarcane yield.