Abstract:Aiming to address the issue of low weed detection accuracy caused by occlusion and varying lighting conditions in complex farmland environments, a weed image dataset was constructed and augmented and an improved detection model, SDE-YOLO v10, was proposed based on YOLO v10. Firstly, the original pooling structure in the backbone network was replaced with the simplified spatial pyramid pooling fast (SimSPPF) module to enhance the extraction of multi-scale weed features. Secondly, the deformable convolutional networks v3 (DCNv3) was introduced into the C2f module in the neck network to improve adaptive perception of irregularly shaped weeds. Meanwhile, the efficient multi-scale attention (EMA) mechanism was embedded to strengthen the model's focus on key feature dimensions. Experiments were conducted on the self-constructed and augmented weed dataset (3126 images). Results from ablation experiments and multi-model comparisons indicated that the SDE-YOLO v10 model achieved the highest precision, recall, mAP@0.5, and mAP@0.5:0.95 scores of 91.3%, 80.2%, 86.7% and 73.1%, respectively. These represent improvements of 5.4, 4.7, 1.5 and 2.3 percentage points over the baseline YOLO v10 model. Under conditions of varying lighting and occlusion, the improved model attained detection success rates of 86.42% and 82.72%, corresponding to improvements of 13.58 and 12.35 percentage points compared with that of the original model, demonstrating its strong robustness in complex scenarios. SDE-YOLO v10 enabled accurate identification of weeds with complex morphology while optimizing the network architecture, providing a technical reference for real-time weed detection in smart agriculture scenarios.