MSW-YOLOv11n: A Lightweight Model with Spatial–Channel Attention for Cherry Tomato Maturity Detection
Accurate cherry tomato maturity detection is important for automated harvesting and grading. To address occlusion, fruit overlap, illumination variation, and edge computing constraints, this study proposes a lightweight model, MSW-YOLOv11n. Based on YOLOv11n, the model incorporates a MobileNetV4 backbone to reduce model complexity, a spatial–channel attention module, RipenessAttn, to enhance maturity-related feature representation, and the Wise-IoU v3 (WIoU v3) loss to improve bounding-box regression. Comparative, ablation, and pruning experiments were conducted on a custom dataset covering five maturity stages. The unpruned model achieved a precision of 89.49%, a recall of 89.33%, and an [email protected] of 94.82%, with 2.15 × 106 parameters and 4.76 GFLOPs. Compared with YOLOv11n, these detection metrics increased by 6.21, 6.06, and 6.62 percentage points, respectively, while parameter count and computational cost decreased by 16.99% and 26.09%. At a pruning ratio of 50%, the model required 1.47 × 106 parameters and 3.65 GFLOPs, with an [email protected] of 93.15% and an ONNX file size of 5.98 MB. Deployed on Jetson Nano using TensorRT FP16, the pruned model achieved a measured processing time of 47.22 ms per frame and a processing rate of 21.18 frames/s under the tested conditions. These results demonstrate improved detection accuracy with reduced model complexity, supporting further development of intelligent cherry tomato grading systems.
Authors
- Shiping Zhu
- Yafeng Chen
- Yuhui Shan
Institutions
- Southwest University (CN)
Publication Details
- Journal
- Mathematics
- Published
- 2026-11-24
- DOI
- https://doi.org/10.3390/math14234320
- Primary Topic
- Smart Agriculture and AI
- Type
- article
- Field-Weighted Citation Impact
- 0.00