Abstract

To enhance the efficiency of mechanical automatic picking of cherry tomatoes in a precision agriculture environment, this study proposes an improved target detection algorithm based on YOLOv5n. The improvement steps are as follows: First, the K-means++ clustering algorithm is utilized to update the scale and aspect ratio of the anchor box, adapting it to the shape characteristics of cherry tomatoes. Secondly, the coordinate attention (CA) mechanism is introduced to expand the receptive field range and reduce interference from branches, dead leaves, and other backgrounds in the recognition of cherry tomato maturity. Next, the traditional loss function is replaced by the bounding box regression loss with dynamic focusing mechanism (WIoU) loss function. The outlier degree and dynamic nonmonotonic focusing mechanism are introduced to address the boundary box regression balance problem between high-quality and low-quality data. This research employs a self-built cherry tomato dataset to train the target detection algorithms before and after the improvements. Comparative experiments are conducted with YOLO series algorithms. The experimental results indicate that the improved model has achieved a 1.4% increase in both precision and recall compared to the previous model. It achieves an average accuracy mAP of 95.2%, an average detection time of 5.3 ms, and a weight file size of only 4.4 MB. These results demonstrate that the model fulfills the requirements for real-time detection and lightweight applications. It is highly suitable for deployment in embedded systems and mobile devices. The improved model presented in this paper enables real-time target recognition and maturity detection for cherry tomatoes. It provides rapid and accurate target recognition guidance for achieving mechanical automatic picking of cherry tomatoes.

Full Text
Published version (Free)

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call