Submitted:
29 April 2023
Posted:
30 April 2023
You are already at the latest version
Abstract
Keywords:
1. Introduction
2. Materials and Methods
2.1. Sample preparation
2.2. Walnut x-ray images acquisition
2.3. Basic framework of Faster R-CNN network
2.4. Optimization method of Fast R-CNN model
2.4.1. Feature fusion based on FPN structure
2.4.2. ROI Align
2.4.3. Softer-NMS
2.5. Training Platform
2.6. Evaluation indicators of model
3. Results and Discussion
3.1. Construction of fast R-CNN model
3.2. Training results of the improved Faster R-CNN Model
3.3. Performance analysis of the improved Faster R-CNN model
4. Conclusions
Author Contributions
Funding
Institutional Review Board Statement
Informed Consent Statement
Data Availability Statement
Acknowledgments
Conflicts of Interest
References
- Dong, C.L. Thoughts on high-quality development of walnut industry in Chuxiong. Green Science and Technology 2021, 23, 110–112. [Google Scholar] [CrossRef]
- Kotwaliwale, N.; Singh, K.; Kalne, A.; Jha, S.N.; Seth, N.; Kar, A. X-ray imaging methods for internal quality evaluation of agricultural produce. J Food Sci Technol 2014, 51, 1–15. [Google Scholar] [CrossRef] [PubMed]
- Shahin, M.A.; Tollner, E.W.; McClendon, R.W. AE—Automation and Emerging Technologies. Journal of Agricultural Engineering Research 2001, 79, 265–274. [Google Scholar] [CrossRef]
- Van Dael, M.; Verboven, P.; Zanella, A.; Sijbers, J.; Nicolai, B. Combination of shape and X-ray inspection for apple internal quality control: in silico analysis of the methodology based on X-ray computed tomography. Postharvest Biology and Technology 2019, 148, 218–227. [Google Scholar] [CrossRef]
- Van de Looverbosch, T.; Raeymaekers, E.; Verboven, P.; Sijbers, J.; Nicolai, B. Non-destructive internal disorder detection of Conference pears by semantic segmentation of X-ray CT scans using deep learning. Expert Systems with Applications 2021, 176, 114925. [Google Scholar] [CrossRef]
- Gao, T.Y.; Zhang, S.J.; Sun, P.; Zhao, H.M.; Sun, H.X.; Niu, R.M. Variety Classification of walnut based on X-ray image. Food Science and Technology 2020, 45, 284–288. [Google Scholar] [CrossRef]
- Zhang, S.; Gao, T.; Ren, R.; Sun, H. Detection of Walnut Internal Quality Based on X-ray Imaging Technology and Convolution Neural Network. Trans. Chin. Soc. Agric. Mach 2022, 53, 383–388. [Google Scholar]
- LeCun, Y.; Bengio, Y.; Hinton, G. Deep learning. Nature 2015, 521, 436–444. [Google Scholar] [CrossRef] [PubMed]
- Ren, S.Q.; He, K.M.; Girshick, R.; Sun, J. Faster R-CNN: Towards Real-Time Object Detection with Region Proposal Networks. Ieee T Pattern Anal 2017, 39, 1137–1149. [Google Scholar] [CrossRef] [PubMed]
- Zeng, Y.X.; Lu, H.C.; Lv, H.F. Research on cotton packaging defect detection method based on improved Faster R-CNN. Electronic Measurement and Instrumentation 2022, 36, 179–186. [Google Scholar] [CrossRef]
- Xia, Y.; Xiao, J.Q.; Weng, Y.S. Surface defect detection of polarizer based on improved Faster R-CNN. Optical Technique 2021, 47, 695–702. [Google Scholar] [CrossRef]
- Zhu, W.T.; Lan, X.C.; Luo, H.L.; Yue, B.; Wang, Y. Remote sensing aircraft target detection based on improved Fasterr-CNN. Computer Science 2022, 49, 378–383. [Google Scholar]
- Li, L.S.; Zeng, P.P. Apple target detection based on improved Faster-RCNN framework of deep learning. Machine Design and Research 2019, 35, 24–27. [Google Scholar] [CrossRef]
- Chen, B.; Rao, H.H.; Wang, Y.L.; Li, Q.S.; Wang, B.Y.; Liu, M.H. Study on detection of camellia fruit in natural environment based on Faster-RCNN. Acta Agriculturae Jiangxi 2021, 33, 67–70. [Google Scholar] [CrossRef]
- Yan, J.W.; Zhao, Y.; Zhang, L.W.; Su, X.D.; Liu, H.Y.; Zhang, F.G.; Fan, W.G.; He, L. Recognition of Rosa roxbunghii in natural environment based on improved Faster-RCNN. Transactions of the Chinese Society of Agricultural Engineering 2019, 35, 143–150. [Google Scholar]
- Wei, R.; Pei, Y.K.; Jiang, Y.C.; Zhou, P.Z.; Zhang, Y.F. Detection of cherry defects based on improved Faster R-CNN model. Food&Machinery 2021, 37, 98–105. [Google Scholar] [CrossRef]
- Saidi, L.; Ben Ali, J.; Fnaiech, F. Application of higher order spectral features and support vector machines for bearing faults classification. ISA Trans 2015, 54, 193–206. [Google Scholar] [CrossRef] [PubMed]







| Model | Accuracy (%) | Recall (%) | F1-value (%) |
mAP (%) |
Total training time (h) |
Training time of single image (ms) |
|---|---|---|---|---|---|---|
| YOLOv3 YOLOv5 |
86.14 87.32 |
79.02 83.25 |
82.43 85.24 |
85.87 88.43 |
10.27 9.73 |
14 8 |
| Faster R-CNN | 89.47 | 86.47 | 87.94 | 89.71 | 11.38 | 10 |
| The model framework | mAP(%) | F1-value (%) |
|---|---|---|
| Faster R-CNN | 89.71 | 87.94 |
| Faster R-CNN +FPN | 91.33 | 89.07 |
| Faster R- CNN +FPN+ROI Align | 93.06 | 91.43 |
| Faster R-CNN +FPN +ROI Align +Softer-NMS | 95.57 | 93.59 |
| Actual Class | Predicted Class | Discrimination Accuracy(%) |
Overall Accuracy(%) |
||
|---|---|---|---|---|---|
| Empty-shell walnut |
Shriveled walnut |
Sound walnut |
|||
| Empty-shell walnut (173) | 164 | 8 | 1 | 94.80% | 94.22% |
| Shriveled walnut (145) | 8 | 133 | 4 | 91.72% | |
| Sound walnut (207) | 2 | 6 | 199 | 96.14% | |
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. |
© 2023 by the author. 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/).