## 5 Conclusions  
In conclusion, this study proposes the RT-DETR-Tomato model for tomato object detection, with significant research background and implications. Addressing the issue of poor detection performance for small targets in complex and dense scenes, this study builds upon the RT-DETR model framework. The original model employs a ResNet50 backbone network with limited feature extraction capabilities. Therefore, Swin Transformer is selected as the new backbone network due to its superior ability to capture extensive global dependencies and contextual information. Furthermore, to mitigate the issue of the large number of parameters in the Swin Transformer modules, a lightweight BiFormer block is adopted. This module effectively reduces computational complexity through content-aware flexible computation allocation. The model is trained on the dataset, and comparative experiments reveal that the improved model achieves better detection accuracy. This demonstrates that replacing the backbone network and incorporating attention mechanisms can effectively enhance model performance and accuracy in detecting small targets within scenes. The \(mAP\) (mean Average Precision) increased by 3.3 percentage points compared to the original model. At the same time, the training time was reduced by half, adequately meeting the requirements for tomato object detection in densely populated plant environments. The main contributions of this improvement to the tomato production process are as follows: In the tomato production process, the harvesting stage is particularly labor-intensive and time-consuming. By using a tomato object detection model, ripe tomatoes can be quickly and accurately identified, providing precise location information for harvesting robots, thereby improving harvesting efficiency. Given the large number of tomatoes, a 3.3% improvement in model efficiency means that more tomatoes can be identified within the same time frame, further increasing harvesting speed and reducing tomato waste for growers. Additionally, tomato sorting is a key step in ensuring tomato quality. Traditional sorting methods rely mainly on manual labor, which is inefficient and prone to errors. Utilizing the tomato object detection model, tomatoes at different stages of ripeness can be automatically identified and classified according to set standards. A 3.3% improvement in model efficiency helps to increase sorting speed, reduce labor costs, and ensure tomato quality. Future work will focus on achieving a lightweight model structure that ensures precision while accelerating detection speed, enabling deployment on mobile devices with limited hardware resources. This practical application aims to enhance the monitoring efficiency of tomato yield and quality, promote safe tomato production, and provide more reliable decision support for farmers and food processing enterprises. Methodology, Z.Z. ; Software, Y.G. ; Formal analysis, S.C.; Investigation, P.Y. ; Resources, Z.Z. ; Writing - original draft, Z.Z. ; Writing - review & editing, Y.S. ; Supervision, Y.W. and Y.S. ; Project administration, Y.S. All authors have read and agreed to the published version of the manuscript. This research was supported by the Shandong Provincial Natural Science Foundation, China (no. ZR2020 MF146), and the Open Project Foundation of Intelligent Information Processing Key Laboratory of Shanxi Province (no. CICIP2021002). Not applicable. The data presented in this study are available from the first author upon request. This paper was completed by the Key Laboratory of Huang-Huai-Hai Smart Agricultural Technology of the Ministry of Agriculture and Rural Affairs, Shandong Agricultural University. We thank the school for its support and help. The authors declare no conflicts of interest. This paper represents the opinions of the authors and does not mean to represent the position or opinions of the Shandong Agricultural University.