Skip to main content
Log in

Fusion of the YOLOv4 network model and visual attention mechanism to detect low-quality young apples in a complex environment

  • Published:
Precision Agriculture Aims and scope Submit manuscript

Abstract

The accurate detection of young fruits in complex scenes is of great significance for automatic fruit growth monitoring systems. The images obtained in the open orchard contain interference factors including strong illumination, blur and occlusion, and the image quality is low. To improve the detection accuracy of young apples in low-quality images, a novel young apple detection algorithm that fuses the YOLOv4 network model and visual attention mechanism was proposed. The Non-local attention module (NLAM) and Convolutional block attention model (CBAM) were added to the baseline of the YOLOv4 model, and the proposed model was named YOLOv4–NLAM–CBAM. NLAM was used to extract the long-range dependency information from high-level visual features; CBAMs were used to further enhance the perception ability of the region of interest (ROI). To verify the effectiveness of the proposed algorithm, 3 000 young apple images were used for training and testing. The results showed that the detection precision, recall rate, average precision and F1 score of the YOLOv4–NLAM–CBAM model were 85.8%, 97.3%, 97.2% and 91.2%, respectively, and the average run time was 35.1 ms. For highlight/shadow, blur, severe occlusion and other images in test set, the average precision of the proposed algorithm was 98.0%, 96.2%, 97.0% and 96.9%, respectively. The experimental results showed that this method can achieve high-efficiency detection of low-quality images. The method can provide a certain reference for the research on automatic monitoring of young fruit growth.

This is a preview of subscription content, log in via an institution to check access.

Access this article

We’re sorry, something doesn't seem to be working properly.

Please try refreshing the page. If that doesn't work, please contact support so we can address the problem.

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5
Fig. 6
Fig. 7
Fig. 8
Fig. 9

Similar content being viewed by others

References

Download references

Acknowledgements

This work was supported by the National Key R&D Program of China (Grant No: 2019YFD1002401), the National High Technology Research and Development Program of China (863 Program) (No. 2013AA10230402) and the National Natural Science Foundation of China (Grant No: 31701326). The authors would like to thank all of the authors cited in this article and the anonymous referees for their helpful comments and suggestions.

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Huaibo Song.

Additional information

Publisher's Note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Jiang, M., Song, L., Wang, Y. et al. Fusion of the YOLOv4 network model and visual attention mechanism to detect low-quality young apples in a complex environment. Precision Agric 23, 559–577 (2022). https://doi.org/10.1007/s11119-021-09849-0

Download citation

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s11119-021-09849-0

Keywords

Navigation