Semi-Supervised Density Estimation with Background-Augmented Data for In Situ Seed Counting
Abstract
1. Introduction
- We employ a framework that combines semi-supervised learning and density map estimation to improve domain-invariant representation for seed counting under diverse agricultural environments.
- We showed that in situ seed density can be estimated using small-scale labeled data by leveraging a paired dataset constructed with background augmentation.
- The proposed method outperforms previous methods on field data, thereby demonstrating superior generalization ability.
2. Materials and Methods
2.1. Task Overview
2.2. Dataset Construction
2.3. Density Estimation Model
2.4. Semi-Supervised Training and Implementation
2.5. Evaluation
3. Result and Discussion
3.1. Model Training
3.2. Density Map Estimation
3.3. Seed Counting
3.4. Comparison and Discussion
4. Conclusions
Author Contributions
Funding
Institutional Review Board Statement
Data Availability Statement
Conflicts of Interest
References
- Fukagawa, N.K.; Ziska, L.H. Rice: Importance for global nutrition. J. Nutr. Sci. Vitaminol. 2019, 65, S2–S3. [Google Scholar] [CrossRef]
- Wang, X.; Li, Z.; Tan, S.; Li, H.; Qi, L.; Wang, Y.; Chen, J.; Yang, C.; Chen, J.; Qin, Y.; et al. Research on density grading of hybrid rice machine-transplanted blanket-seedlings based on multi-source unmanned aerial vehicle data and mechanized transplanting test. Comput. Electron. Agric. 2024, 222, 109070. [Google Scholar] [CrossRef]
- Ali, A.M.; Thind, H.S.; Singh, V.; Singh, B. A framework for refining nitrogen management in dry direct-seeded rice using GreenSeeker™ optical sensor. Comput. Electron. Agric. 2015, 110, 114–120. [Google Scholar] [CrossRef]
- Hwang, W.H.; Jeong, J.H.; Lee, H.S.; Yang, S.Y.; Lee, C.K.; Lim, Y.H.; Cho, S.H.; Min, H.K.; Kim, S.K.; Nam, J.W.; et al. Proper growing regions and management practices for improving production stability in direct-seeded rice cultivation. Korean J. Crop Sci. 2019, 64, 336–343. [Google Scholar] [CrossRef]
- Lee, C.M.; Kim, C.S.; Shin, W.C.; Baek, M.K.; Park, H.S.; Ko, J.C.; Kim, J.J.; Suh, J.P.; Jeong, O.Y.; Lee, K.M.; et al. ‘Saebonghwang’: A high grain quality mid-late-maturing rice cultivar adaptable to direct seeding and transplanting cultivation. Korean J. Breed. Sci. 2024, 56, 147–159. [Google Scholar] [CrossRef]
- Xie, C.; Zhang, D.; Yang, L.; Cui, T.; Yu, T.; Wang, D.; Xiao, T. Experimental analysis on the variation law of sensor monitoring accuracy under different seeding speed and seeding spacing. Comput. Electron. Agric. 2021, 189, 106369. [Google Scholar] [CrossRef]
- Liu, W.; Zhou, Z.; Xu, X.; Gu, Q.; Zou, S.; He, W.; Luo, X.; Huang, J.; Lin, J.; Jiang, R. Evaluation method of rowing performance and its optimization for UAV-based shot seeding device on rice sowing. Comput. Electron. Agric. 2023, 207, 107718. [Google Scholar] [CrossRef]
- Moreno, F.G.; Zimmermann, G.G.; Jasper, S.P.; da Silva Ferraz, R.; Savi, D. Sensors installation position and its interference on the precision of monitoring maize sowing. Smart Agric. Technol. 2023, 4, 100150. [Google Scholar] [CrossRef]
- Xie, C.; Zhang, D.; Yang, L.; Cui, T.; He, X.; Du, Z. Precision seeding parameter monitoring system based on laser sensor and wireless serial port communication. Comput. Electron. Agric. 2021, 190, 106429. [Google Scholar] [CrossRef]
- Peng, J.; Yang, Z.; Lv, D.; Yuan, Z. A dynamic rice seed counting algorithm based on stack elimination. Measurement 2024, 227, 114275. [Google Scholar] [CrossRef]
- Zhang, W.; Zhao, B.; Gao, S.; Zhu, Y.; Zhou, L.; Niu, K.; Qiu, Z.; Jin, X. Design and experiment of an intelligent testing bench for air-suction seed metering devices for small vegetable seeds. Biosyst. Eng. 2024, 245, 84–95. [Google Scholar] [CrossRef]
- Lin, P.; Chen, Y.M.; He, Y.; Hu, G.W. A novel matching algorithm for splitting touching rice kernels based on contour curvature analysis. Comput. Electron. Agric. 2014, 109, 124–133. [Google Scholar] [CrossRef]
- Jing, H.; Peiyuan, L.; Hanwei, C. Research on the rice counting method based on connected component labeling. In Proceedings of the Sixth International Conference on Measuring Technology and Mechatronics Automation (ICMTMA), Zhangjiajie, China, 10–11 January 2014; pp. 552–555. [Google Scholar] [CrossRef]
- Wu, W.; Zhou, L.; Chen, J.; Qiu, Z.; He, Y. GainTKW: A measurement system of thousand kernel weight based on the android platform. Agronomy 2018, 8, 178. [Google Scholar] [CrossRef]
- Tan, S.; Ma, X.; Mai, Z.; Qi, L.; Wang, Y. Segmentation and counting algorithm for touching hybrid rice grains. Comput. Electron. Agric. 2019, 162, 493–504. [Google Scholar] [CrossRef]
- Sun, J.; Zhang, Y.; Zhu, X.; Zhang, Y.D. Deep learning optimization method for counting overlapping rice seeds. J. Food Process Eng. 2021, 44, e13787. [Google Scholar] [CrossRef]
- Feng, A.; Li, H.; Liu, Z.; Luo, Y.; Pu, H.; Lin, B.; Liu, T. Research on a rice counting algorithm based on an improved MCNN and a density map. Entropy 2021, 23, 721. [Google Scholar] [CrossRef] [PubMed]
- Zhang, Y.; Zhou, D.; Chen, S.; Gao, S.; Ma, Y. Single-image crowd counting via multi-column convolutional neural network. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition (CVPR 2016), Las Vegas, NV, USA, 26 June–1 July 2016; pp. 589–597. [Google Scholar] [CrossRef]
- Qian, Y.; Zhang, L.; Guo, Z.; Hong, X.; Arandjelović, O.; Donovan, C.R. Perspective-assisted prototype-based learning for semi-supervised crowd counting. Pattern Recognit. 2025, 158, 111073. [Google Scholar] [CrossRef]
- Ibáñez-Asensio, S.; Marqués-Mateu, A.; Moreno-Ramón, H.; Balasch, S. Statistical relationships between soil colour and soil attributes in semiarid areas. Biosyst. Eng. 2013, 116, 120–129. [Google Scholar] [CrossRef]
- Zhang, H.; Cisse, M.; Dauphin, Y.N.; Lopez-Paz, D. mixup: Beyond empirical risk minimization. arXiv 2017, arXiv:1710.09412. [Google Scholar] [CrossRef]
- DeVries, T.; Taylor, G.W. Improved regularization of convolutional neural networks with cutout. arXiv 2017, arXiv:1708.04552. [Google Scholar] [CrossRef]
- Yun, S.; Han, D.; Chon, S.; Oh, S.J.; Yoo, Y.; Choe, J. Cutmix: Regularization strategy to train strong classifiers with localizable features. In Proceedings of the IEEE/CVF International Conference on Computer Vision (ICCV 2019), Seoul, Republic of Korea, 27 October–2 November 2019; pp. 6022–6031. [Google Scholar] [CrossRef]
- Divyanth, L.G.; Guru, D.S.; Soni, P.; Machavaram, R.; Nadimi, M.; Paliwal, J. Image-to-image translation-based data augmentation for improving crop weed classification models for precision agriculture applications. Algorithms 2022, 15, 401. [Google Scholar] [CrossRef]
- Qian, Y.; Hong, X.; Guo, Z.; Arandjelović, O.; Donovan, C.R. Semi-supervised crowd counting with contextual modeling: Facilitating holistic understanding of crowd scenes. IEEE Trans. Circuits Syst. Video Technol. 2024, 34, 8230–8241. [Google Scholar] [CrossRef]
- Tarvainen, A.; Valpola, H. Mean teachers are better role models: Weight-averaged consistency targets improve semi-supervised deep learning results. In Proceedings of the 31st Annual Conference on Neural Information Processing Systems (NIPS 2017), Long Beach, CA, USA, 4–9 December 2017; p. 30. [Google Scholar]
- Rural Development Administration. Agricultural Technology Guide 169: Cultivation Method by Direct Sowing, 2nd ed.; RDA: Jeonju, Republic of Korea, 2018. [Google Scholar]
- Kim, T.; Lee, D.H.; Kim, W.S.; Zhang, B.T. Domain adapted broiler density map estimation using negative-patch data augmentation. Biosyst. Eng. 2023, 231, 165–177. [Google Scholar] [CrossRef]
- Lin, T.Y.; Dollar, P.; Girshick, R.; He, K.; Hariharan, B.; Belongie, S. Feature pyramid networks for object detection. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition (CVPR 2017), Honolulu, HI, USA, 21–26 July 2017; pp. 2117–2125. [Google Scholar] [CrossRef]
- He, K.; Zhang, X.; Ren, S.; Sun, J. Deep Residual Learning for Image Recognition. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition (CVPR 2016), Las Vegas, NV, USA, 26 June–1 July 2016; pp. 770–778. [Google Scholar] [CrossRef]
- Ronneberger, O.; Fischer, P.; Brox, T. U-Net: Convolutional networks for biomedical image segmentation. In Proceedings of the Medical Image Computing and Computer-Assisted Intervention–MICCAI 2015: 18th International Conference, Munich, Germany, 5–9 October 2015; pp. 234–241. [Google Scholar] [CrossRef]
- Liu, M.; Zhang, J.; Adeli, E.; Shen, D. Joint classification and regression via deep multi-task multi-channel learning for Alzheimer’s disease diagnosis. IEEE Trans. Biomed. Eng. 2019, 66, 1195–1206. [Google Scholar] [CrossRef]
- Sohn, K.; Berthelot, D.; Carlini, N.; Zhang, Z.; Zhang, H.; Raffel, C.A.; Cubuk, E.D.; Kurakin, A.; Li, C.L. Fixmatch: Simplifying semi-supervised learning with consistency and confidence. In Proceedings of the 33rd Annual Conference on Neural Information Processing Systems (NeurIPS 2020), Vancouver, BC, Canada, 6–12 December 2020; pp. 596–608. [Google Scholar]
- Yang, Y.; Sun, G.; Zhang, T.; Wang, R.; Su, J. Semi-supervised medical image segmentation via weak-to-strong perturbation consistency and edge-aware contrastive representation. Med. Image Anal. 2025, 101, 103450. [Google Scholar] [CrossRef]
- Qian, Y.; Zhang, L.; Hong, X.; Donovan, C.; Arandjelović, O. Segmentation assisted u-shaped multi-scale transformer for crowd counting. In Proceedings of the British Machine Vision Conference (BMVC 2022), London, UK, 21–24 November 2022; p. 397. [Google Scholar]
- Loshchilov, I.; Hutter, F. Decoupled weight decay regularization. arXiv 2017, arXiv:1711.05101. [Google Scholar] [CrossRef]
- Lin, H.; Ma, Z.; Hong, X.; Wang, Y.; Su, Z. Semi-supervised crowd counting via density agency. In Proceedings of the 30th ACM International Conference on Multimedia (MM 2022), New York, NY, USA, 10–14 October 2022; pp. 1416–1426. [Google Scholar] [CrossRef]
- Ma, N.; Su, Y.; Yang, L.; Li, Z.; Yan, H. Wheat Seed Detection and Counting Method Based on Improved YOLOv8 Model. Sensors 2024, 24, 1654. [Google Scholar] [CrossRef] [PubMed]
- Wang, Z.; Bovik, A.C.; Sheikh, H.R.; Simoncelli, E.P. Image quality assessment: From error visibility to structural similarity. IEEE Trans. Image Process. 2004, 13, 600–612. [Google Scholar] [CrossRef] [PubMed]
- Hendrycks, D.; Dietterich, T. Benchmarking neural network robustness to common corruptions and perturbations. arXiv 2019. [Google Scholar] [CrossRef]
- Krijthe, J.H.; Loog, M. The peaking phenomenon in semi-supervised learning. In Proceedings of the Structural, Syntactic, and Statistical Pattern Recognition (S+SSPR 2016), Mérida, Mexico, 30 November–2 December 2016; pp. 299–309. [Google Scholar] [CrossRef]
- Yang, X.; Song, Z.; King, I.; Xu, Z. A survey on deep semi-supervised learning. IEEE Trans. Knowl. Data Eng. 2023, 35, 8934–8954. [Google Scholar] [CrossRef]
Data Source | Data Domain | Number of Samples | |||
---|---|---|---|---|---|
Training | Validation | Test | Total | ||
Indoor | Known | 159 | 40 | 51 | 250 |
Field | Unknown | - | - | 73 | 73 |
Backbone | Input Size (Height × Width × Channel) | Params (M) | FLOPs (M) |
---|---|---|---|
Resnet-50 [30] | 512 × 512 × 3 | 72.0 | 222.7 |
Method | Ground Truth | p Value | ||
---|---|---|---|---|
5% Labeled Data | 10% Labeled Data | 40% Labeled Data | ||
Baseline | 88.5 ± 58.7 | 0.007 ** | 0.002 ** | 0.104 |
Our method | 0.055 | 0.736 | 0.065 |
Method | MAE | SSIM | PSNR (dB) | |||
---|---|---|---|---|---|---|
Test | Field | Test | Field | Test | Field | |
Baseline | 11.93 ± 13.10 a | 50.91 ± 55.29 a | 0.87 | 0.94 | 18.9 | 21.1 |
Mixup [21] | 7.25 ± 5.16 b | 47.98 ± 50.54 a | 0.86 | 0.94 | 16.7 | 21.9 |
Cutout [22] | 10.19 ± 7.25 a,b | 25.14 ± 21.75 b | 0.85 | 0.88 | 15.1 | 16.8 |
Cutmix [23] | 5.14 ± 4.98 b,c | 53.74 ± 45.71 a | 0.86 | 0.84 | 17.1 | 16.0 |
Faster-RCNN [16] | 5.14 ± 7.41 b,c | 23.86 ± 30.72 b | - | - | - | - |
YOLOv8n [38] | 7.49 ± 9.10 a,b | 35.85 ± 43.14 a,b | - | - | - | - |
Our method | 3.37 ± 3.57 b,c | 22.33 ± 20.03 b | 0.87 | 0.88 | 20.5 | 19.0 |
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2025 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).
Share and Cite
Sung, B.-G.; Lee, C.-G.; Kang, Y.-H.; Yu, S.-H.; Lee, D.-H. Semi-Supervised Density Estimation with Background-Augmented Data for In Situ Seed Counting. Agriculture 2025, 15, 1682. https://doi.org/10.3390/agriculture15151682
Sung B-G, Lee C-G, Kang Y-H, Yu S-H, Lee D-H. Semi-Supervised Density Estimation with Background-Augmented Data for In Situ Seed Counting. Agriculture. 2025; 15(15):1682. https://doi.org/10.3390/agriculture15151682
Chicago/Turabian StyleSung, Baek-Gyeom, Chun-Gu Lee, Yeong-Ho Kang, Seung-Hwa Yu, and Dae-Hyun Lee. 2025. "Semi-Supervised Density Estimation with Background-Augmented Data for In Situ Seed Counting" Agriculture 15, no. 15: 1682. https://doi.org/10.3390/agriculture15151682
APA StyleSung, B.-G., Lee, C.-G., Kang, Y.-H., Yu, S.-H., & Lee, D.-H. (2025). Semi-Supervised Density Estimation with Background-Augmented Data for In Situ Seed Counting. Agriculture, 15(15), 1682. https://doi.org/10.3390/agriculture15151682