Abstract:With the promotion of smart agriculture technology, there are issues such as low detection accuracy and resource limitations of real-time detection devices due to the small size of litchi fruits, severe occlusion, and complex background in natural environments. A lightweight litchi fruit detection method was proposed based on the improved YOLO v8s. Firstly, a lightweight network, MobileNetV3, was adopted as the backbone network to reduce the model parameters. On this basis, the convolutional local attention module (CLAM) was introduced to enhance the model's feature extraction ability for litchi fruits in natural environments both in channels and space. The concept of residual learning was also introduced to fuse the features before and after the attention module through weighted addition, ensuring the model's feature learning from the original image and improving the detection stability in complex environments. Secondly, some convolutional layers were replaced with depthwise separable convolutions, and multi-scale feature fusion was performed. Finally, to address the issues of small fruit size and severe occlusion, the αEIoU was used as the loss function to accelerate the convergence speed of the aspect ratio of the detection bounding box and reduce the missed detection rate of overlapping fruits. Experimental results indicated that the improved YOLO v8s achieved an accuracy rate of 91.75% and a detection precision of 79.07% on the experimental dataset, which were 17.29 and 14.75 percentage points higher than that of the original model, respectively. At the same time, the number of parameters was significantly reduced to 5.488×10?, a decrease of 50.7% compared with that of the original model. Compared with mainstream lightweight models such as YOLO v5s, EfficientNetV2, YOLO v7-Tiny, YOLO v9s, YOLO v10s, and YOLO 11s, this model demonstrated advantages in terms of precision, recall, and detection accuracy, providing a technical reference for litchi detection and yield estimation in modern orchard environments using mobile devices.