Abstract:Robotic automated harvesting proves to be an efficient solution for greenhouse tomato cluster harvesting operations. The ripeness of tomato clusters stands as a vital criterion influencing the decision-making process for the harvesting robot. Aiming to employ Deep White-Balance and Zero-DCE deep neural networks for color cast correction and shadow detail enhancement in tomato images to enhance image quality by addressing color cast issues and improving local illumination in both fill light and night environments, the concept of the deep residual shrinkage network was introduced, incorporating the RSBottleneck-CW module into YOLO v5s. This module conducted soft threshold processing on the feature map to effectively suppress noise interference in the image. Experimental results demonstrated that in the night environment, after enhancing the image solely with the Zero-DCE algorithm, the recall of the detection model reached 0.924, capturing more tomato fruits and trusses. In a supplementary light environment, the image underwent joint processing with Deep White-Balance and Zero-DCE to restore authentic colors and enhance texture details. This resulted in the detection model achieving an mAP of 0.849, reflecting a 0.038 increase compared with that of the before processing. The YOLO v5s integrated with the RSBottleneck-CW module exhibited robust adaptability to feature map noise. Irrespective of whether the image underwent depth enhancement, its mAP and F1-Score consistently surpassed those of the original YOLO v5s. In the nighttime environment, the highest recorded mAP and F1-Score values were 0.902 and 0.844, respectively. Similarly, in the supplementary light environment, the peak mAP and F1-Score values reached 0.868 and 0.817, respectively. After the detection model detected the fruits and trusses, the final ripeness level of the tomato clusters were determined by using the bounding boxes aligning algorithm. In the ripeness stage of tomato clusters ranged from 90% to 100%, the average absolute errors in ripeness recognition under nighttime and supplementary light conditions were 1.837% and 1.067%, respectively. These findings can serve as decision-making criteria for night automated harvesting operations of tomato-picking robots.