A transformer-enhanced real-time detection method for young fruits in complex orchard environments

Accurate detection of apple young fruits is a critical prerequisite for achieving automated orchard management. However,due to the small size of young fruits, their similarity in color to the background, and frequent overlap and occlusion, real-time detection in complex orchard environments becomes a significant challenge. To overcome these challenges, we propose a multi-level, end-to-end, Transformer-enhanced real-time detection method–HLEdetection. This architecture is composed of three core modules: (1) a Hierarchical Multi-scale Feature Extraction module, which extracts fruit features at multiple resolutions to enhance the perception of small objects; (2) a Learned Positional Encoding Injection module, which introduces learnable positional embeddings during the decoding stage to strengthen feature alignment across scales, thereby improving localization precision and semantic consistency; and (3) the EMASlideLoss function, which combines an exponential moving average strategy with IoU-based weighting to mitigate severe class imbalance, further enhancing training stability and accuracy. We construct a custom dataset comprising four representative orchard scenarios to rigorously evaluate the proposed method. Experimental results demonstrate that HLEdetection achieves an average Precision of 91.7% and Recall of 79.7% across complex scenes, while maintaining a real-time inference speed of 27.8 FPS ( ≈ 36.0 ms/frame), thereby achieving an optimal balance between accuracy and efficiency. Compared with mainstream object detectors such as the YOLO series, DynamicDet, Faster R-CNN, and RT-DETR, our model shows over 20% improvement in both F1 score and mAP50-95, particularly excelling in densely occluded environments. These results confirm that the proposed method offers a robust and efficient solution for young fruit detection, providing solid technical support for the development of intelligent orchard equipment such as robotic harvesting, precision thinning, and targeted spraying systems.The source code is available at https://github.com/lijinyan628-ops/-recognition-of-apple.

Authors

Publication Details

Journal
Smart Agricultural Technology
Published
2026-01-02
DOI
https://doi.org/10.1016/j.atech.2025.101762
Primary Topic
Smart Agriculture and AI
Type
article
Field-Weighted Citation Impact
0.00
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

A transformer-enhanced real-time detection method for young fruits in complex orchard environments

Jiyong Hu, Jinyan Li, Mingxia Liang, Keyi Jiang et al.
Smart Agricultural Technology
Smart Agriculture and AI
article

A transformer-enhanced real-time detection method for young fruits in complex orchard environments

Jiyong Hu, Jinyan Li, Mingxia Liang, Keyi Jiang, Xiyang Li, Min Tian, Hongfei Yang
article en

Abstract

Accurate detection of apple young fruits is a critical prerequisite for achieving automated orchard management. However,due to the small size of young fruits, their similarity in color to the background, and frequent overlap and occlusion, real-time detection in complex orchard environments becomes a significant challenge. To overcome these challenges, we propose a multi-level, end-to-end, Transformer-enhanced real-time detection method–HLEdetection. This architecture is composed of three core modules: (1) a Hierarchical Multi-scale Feature Extraction module, which extracts fruit features at multiple resolutions to enhance the perception of small objects; (2) a Learned Positional Encoding Injection module, which introduces learnable positional embeddings during the decoding stage to strengthen feature alignment across scales, thereby improving localization precision and semantic consistency; and (3) the EMASlideLoss function, which combines an exponential moving average strategy with IoU-based weighting to mitigate severe class imbalance, further enhancing training stability and accuracy. We construct a custom dataset comprising four representative orchard scenarios to rigorously evaluate the proposed method. Experimental results demonstrate that HLEdetection achieves an average Precision of 91.7% and Recall of 79.7% across complex scenes, while maintaining a real-time inference speed of 27.8 FPS ( ≈ 36.0 ms/frame), thereby achieving an optimal balance between accuracy and efficiency. Compared with mainstream object detectors such as the YOLO series, DynamicDet, Faster R-CNN, and RT-DETR, our model shows over 20% improvement in both F1 score and mAP50-95, particularly excelling in densely occluded environments. These results confirm that the proposed method offers a robust and efficient solution for young fruit detection, providing solid technical support for the development of intelligent orchard equipment such as robotic harvesting, precision thinning, and targeted spraying systems.The source code is available at https://github.com/lijinyan628-ops/-recognition-of-apple.

Smart Agricultural TechnologyVol. 13
Openalex Percentile: Top 99%
Smart Agriculture and AI
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.