Timely harvesting of fresh tomatoes is urgently needed. To address this issue, this study proposes DDC-YOLOv11n, a model suitable for real-time detection of tomato ripeness in complex greenhouse environments. A Zero-DCE adaptive enhancement module is first deployed at the input stage to restore and enhance the true color and texture details of the images. An improved Deep Residual Shrinkage Network (DRSN) is then added to YOLOv11n to perform adaptive soft-threshold filtering on feature maps, reducing the interference of image noise on the detection targets. Finally, the CBAM spatial attention is enhanced through dilated convolution and channel grouping to form the LKCBAM module, which expands the equivalent receptive field while controlling the increase in parameters, thereby improving tomato detection accuracy in occluded and dense scenes. Experimental results show that the DDC-YOLOv11n model achieves the best recognition performance: compared with the original YOLOv11n, its mAP@0.5, precision, recall, and F1 score are increased by 16.8%, 24.6%, 8.3%, and 18.1%, respectively. These findings facilitate real-time tomato ripeness detection in complex greenhouse environments and provide perceptual information for subsequent management tasks such as harvesting.
Cheng et al. (Thu,) studied this question.