Outline

Ingegneria Sismica

Ingegneria Sismica

Counting Optimization of a Spatio-Temporally Decoupled YOLOv8 Model in Scenes with Dense Pods

Author(s): Han Yang1
1School of Liberal Arts and Sciences, Northeast Agricultural University, Harbin 150030, Heilongjiang, China
Yang, Han. “Counting Optimization of a Spatio-Temporally Decoupled YOLOv8 Model in Scenes with Dense Pods.” Ingegneria Sismica Volume 43 Issue 3: 1-19, doi:10.65102/is20261241.

Abstract

To improve counting accuracy in dense soybean pod scenes under small-object occlusion, overlap, and repeated response conditions, this study proposes a spatiotemporal feature-decoupled improved YOLOv8 model that differs from detection-then-tracking counting methods. In this paper, “spatiotemporal decoupling” is defined as encoding soybean pod boundaries, contour gradients, and neighborhood occlusion relationships within the detection network as spatial structural representations, while encoding cross-frame center displacement, scale fluctuation, and short-term visibility variation as temporal association representations. Before the detection head, gated fusion is used to calibrate candidate box confidence and constrain counting bias. Unlike post-processing methods such as DeepSORT and ByteTrack, which rely on detection results for trajectory association, the temporal branch in the proposed method directly participates in candidate generation, candidate filtering, and quantity regression, allowing dense target responses to be corrected before NMS over-suppression and short-term missed detections occur. To address the susceptibility of conventional YOLOv8 to single-frame texture interference, weakened slender pod boundaries, and candidate drift in highly overlapping regions, the model constructs a spatial structural branch and a temporal association branch, and further introduces a P2 fine-grained fidelity branch, multi-scale semantic fusion, candidate target filtering constraints, and repeated-counting and missed-counting bias correction methods. On this basis, the model establishes a joint optimization strategy using localization loss, quantity regression loss, and temporal consistency loss. Experimental results show that the improved model achieves MAE/RMSE/F1 values of 4.2/6.8/0.91, 3.1/5.0/0.94, and 6.4/8.9/0.88 on the self-built soybean field dataset, PlantCrop subset, and occlusion-enhanced synthetic sequence, respectively, significantly reducing counting errors compared with the YOLOv8n baseline.The model operates at 51.7 FPS with a single-frame inference time of 19.3 ms on an NVIDIA RTX 4090 platform, meeting the real-time requirements of field counting.

Keywords
pod counting; YOLOv8; spatio-temporal feature decoupling; small object detection; counting optimization

Related Articles

Zhihao Jiang1,2, Limi Chen1,2, Jing Yang1
1Hainan Vocational University of Science and Technology, Haikou 571126, China
2Institute for Mathematical Research, Universiti Putra Malaysia, Serdang 43400, Malaysia
Limi Chen1,2, Zhihao Jiang1,2, Jing Yang1
1Hainan Vocational University of Science and Technology, Haikou 571126, China
2Institute for Mathematical Research, Universiti Putra Malaysia, Serdang 43400, Malaysia
Hui Yuan1, Minjie Chai2, Siqing Xu1, Jinsong Li1, Jinwan Zheng1
1Electric Power Research Institute, State Grid Shanxi Electric Power Co., Ltd., Taiyuan, 030001, Shanxi, China
2Jincheng Power Supply Branch, State Grid Shanxi Electric Power Co., Ltd., Jincheng, 048000, Shanxi, China
Yanhan Zhu1,2
1China Academy of Cultural Heritage, Chaoyang District, 100029, Beijing, China
2Beijing University of Civil Engineering and Architecture, Xicheng District, 100044, Beijing, China
Ken Wang1, Jinhan Shu2, Kan Yuan1
1School of Digital Media, Shenzhen Polytechnic University, Shenzhen 518055, Guangdong, China
2Postdoctoral Mobile Station of Journalism and communication, Fudan University, Shanghai 200433, Shanghai, China