A Method of Apple Image Segmentation Based on Color-Texture Fusion Feature and Machine Learning
Abstract
:1. Introduction
- To assess and optimize the suitability of color features, texture features for apple fruit image segmentation.
- To develop an apple fruit pixel classifier based on machine learning to segmentation images.
2. Materials and Methods
2.1. Apple Orchard Image Capture
2.2. General Steps of the Apple Fruit Segmentation Algorithm
2.3. Apple Fruit Color Features Extraction
2.4. Apple Fruit Texture Features Extraction
2.5. Data Normalization and Dimension Reduction
2.6. Classifier Development and Pixels Classification
2.7. Apple Fruit Segmentation Result Test
3. Results and Disscussion
3.1. Color Features Selection Result
3.2. Texture Features Selection Result
3.3. Apple Fruit Pixels Classification Result
3.4. Apple Fruit Image Segmentation Result
3.5. Discussion
4. Conclusions
- (1)
- Color features could effectively distinguish apple fruit pixels from others, while texture features had a poor performance in this;
- (2)
- The classification algorithm based on Random Forest could effectively classify the apple fruit pixels, and the accuracy was 0.94
- (3)
- Image segmentation can be done through pixel classification. The average values of Af, FPR and FNR were 0.07, 0.13 and 0.15, respectively.
- (4)
- The image segmentation model established by pixel classification could effectively segment apple fruit from photos.
Author Contributions
Funding
Conflicts of Interest
References
- Lv, J.; Wang, Y.; Xu, L.; Gu, Y.; Zou, L.; Yang, B.; Ma, Z. A method to obtain the near-large fruit from apple image in orchard for single-arm apple harvesting robot. Sci. Hortic. 2019, 257, 108758. [Google Scholar] [CrossRef]
- Bednarz, C.W.; Shurley, W.D.; Anthony, W.S. Losses in Yield, Quality, and Profitability of Cotton from Improper Harvest Timing. Agron. J. 2002, 94, 1004–1011. [Google Scholar] [CrossRef] [Green Version]
- Pothula, A.K.; Zhang, Z.; Lu, R. Design features and bruise evaluation of an apple harvest and in-field presorting machine. Trans. ASABE 2018, 61, 1135–1144. [Google Scholar] [CrossRef]
- Linker, R.; Cohen, O.; Naor, A. Determination of the number of green apples in RGB images recorded in orchards. Comput. Electron. Agric. 2012, 81, 45–57. [Google Scholar] [CrossRef]
- Dong, C.; Tian, F.; Dong, X.; Zhao, X.; Li, F. The Structure and Control Analysis of AMR Automatic Harvesting Robot. In Proceedings of the International Conference on Mechatronics and Intelligent Robotics, Kunming, China, 20–21 May 2017; Springer: Cham, Switzerland, 2017; pp. 457–463. [Google Scholar]
- Qian, L.; Wang, X.; Luo, W.; Qi, Z.; Sun, H.; Luo, Y. An improved CROPR model for estimating cotton yield under soil aeration stress. Crop Pasture Sci. 2017, 68, 366–377. [Google Scholar] [CrossRef]
- Koirala, A.; Walsh, K.B.; Wang, Z.; Mccarthy, C. Deep learning—Method overview and review of use for fruit detection and yield estimation. Comput. Electron. Agric. 2019, 162, 219–234. [Google Scholar] [CrossRef]
- Stein, M.; Bargoti, S.; Underwood, J. Image Based Mango Fruit Detection, Localisation and Yield Estimation Using Multiple View Geometry. Sensors 2016, 16, 1915. [Google Scholar] [CrossRef]
- Gongal, A.; Amatya, S.; Karkee, M.; Zhang, Q.; Lewis, K. Sensors and systems for fruit detection and localization: A review. Comput. Electron. Agric. 2015, 116, 8–19. [Google Scholar] [CrossRef]
- Kang, H.; Chen, C. Fruit detection and segmentation for apple harvesting using visual sensor in orchards. Sensors 2019, 19, 4599. [Google Scholar] [CrossRef] [Green Version]
- Zemmour, E.; Kurtser, P.; Edan, Y. Automatic Parameter Tuning for Adaptive Thresholding in Fruit Detection. Sensors 2019, 19, 2130. [Google Scholar] [CrossRef] [Green Version]
- Feng, J.; Zeng, L.; He, L. Apple Fruit Recognition Algorithm Based on Multi-Spectral Dynamic Image Analysis. Sensors 2019, 19, 949. [Google Scholar] [CrossRef] [PubMed] [Green Version]
- Chaivivatrakul, S.; Dailey, M.N. Texture-based fruit detection. Precis. Agric. 2014, 15, 662–683. [Google Scholar] [CrossRef]
- Huang, L.; He, D.; Yang, S.X. Segmentation on Ripe Fuji Apple with Fuzzy 2D Entropy based on 2D histogram and GA Optimization. Intell. Autom. Soft Comput. 2013, 19, 239–251. [Google Scholar] [CrossRef] [Green Version]
- Sabzi, S.; Abbaspourgilandeh, Y.; Garciamateos, G.; Ruizcanales, A.; Molinamartinez, J.M. Segmentation of Apples in Aerial Images under Sixteen Different Lighting Conditions Using Color and Texture for Optimal Irrigation. Water 2018, 10, 1634. [Google Scholar] [CrossRef] [Green Version]
- Yu, Y.; Zhang, K.; Yang, L.; Zhang, D. Fruit detection for strawberry harvesting robot in non-structural environment based on Mask-RCNN. Comput. Electron. Agric. 2019, 163, 104846. [Google Scholar] [CrossRef]
- Liu, B.; Zhang, Y.; He, D.; Li, Y. Identification of Apple Leaf Diseases Based on Deep Convolutional Neural Networks. Symmetry 2017, 10, 11. [Google Scholar] [CrossRef] [Green Version]
- Gené-Mola, J.; Vilaplana, V.; Rosell-Polo, J.R.; Morros, J.R.; Ruiz-Hidalgo, J.; Gregorio, E. Multi-modal deep learning for Fuji apple detection using RGB-D cameras and their radiometric capabilities. Comput. Electron. Agric. 2019, 162, 689–698. [Google Scholar] [CrossRef]
- Bargoti, S.; Underwood, J. Image Segmentation for Fruit Detection and Yield Estimation in Apple Orchards. J. Field Robot. 2017, 34, 1039–1060. [Google Scholar] [CrossRef] [Green Version]
- Ji, W.; Meng, X.; Qian, Z.; Xu, B.; Zhao, D. Branch localization method based on the skeleton feature extraction and stereo matching for apple harvesting robot. Int. J. Adv. Robot. Syst. 2017, 14, 172988141770527. [Google Scholar] [CrossRef] [Green Version]
- Nguyen, T.T.; Vandevoorde, K.; Wouters, N.; Kayacan, E.; De Baerdemaeker, J.; Saeys, W. Detection of red and bicoloured apples on tree with an RGB-D camera. Biosyst. Eng. 2016, 146, 33–44. [Google Scholar] [CrossRef]
- Mendez, V.; Perezromero, A.; Solaguirado, R.; Mirandafuentes, A.; Manzanoagugliaro, F.; Zapatasierra, A.; Rodriguezlizana, A. In-Field Estimation of Orange Number and Size by 3D Laser Scanning. Agronomy 2019, 9, 885. [Google Scholar] [CrossRef] [Green Version]
- Kazmi, W.; Foix, S.; Alenya, G.; Andersen, H.J. Indoor and outdoor depth imaging of leaves with time-of-flight and stereo vision sensors: Analysis and comparison. ISPRS J. Photogramm. Remote Sens. 2014, 88, 128–146. [Google Scholar] [CrossRef] [Green Version]
- Linker, R. Machine learning based analysis of night-time images for yield prediction in apple orchard. Biosyst. Eng. 2018, 167, 114–125. [Google Scholar] [CrossRef]
- Nyarko, E.K.; Vidovic, I.; Radocaj, K.; Cupec, R. A nearest neighbor approach for fruit recognition in RGB-D images based on detection of convex surfaces. Expert Syst. Appl. 2018, 114, 454–466. [Google Scholar] [CrossRef]
- Sabzi, S.; Abbaspourgilandeh, Y.; Hernandezhernandez, J.L.; Azadshahraki, F.; Karimzadeh, R. The Use of the Combination of Texture, Color and Intensity Transformation Features for Segmentation in the Outdoors with Emphasis on Video Processing. Agriculture 2019, 9, 104. [Google Scholar] [CrossRef] [Green Version]
- Yamamoto, K.; Guo, W.; Yoshioka, Y.; Ninomiya, S. On Plant Detection of Intact Tomato Fruits Using Image Analysis and Machine Learning Methods. Sensors 2014, 14, 12191–12206. [Google Scholar] [CrossRef] [Green Version]
- Ismail, A.; Idris, M.Y.I.; Ayub, M.N.; Por, L.Y. Investigation of Fusion Features for Apple Classification in Smart Manufacturing. Symmetry 2019, 11, 1194. [Google Scholar] [CrossRef] [Green Version]
- Montalvo, M.; Guijarro, M.; Guerrero, J.M.; Ribeiro, A. Identification of Plant Textures in Agricultural Images by Principal Component Analysis. In Proceedings of the International Conference on Hybrid Artificial Intelligence Systems, Seville, Spain, 18–20 April 2016; pp. 391–401. [Google Scholar]
- Tufail, Z.; Khurshid, K.; Salman, A.; Nizami, I.F.; Khurshid, K.; Jeon, B. Improved dark channel prior for image defogging using RGB and YCbCr color space. IEEE Access 2018, 6, 32576–32587. [Google Scholar] [CrossRef]
- Zhang, T.; Hu, H.M.; Li, B. A naturalness preserved fast dehazing algorithm using HSV color space. IEEE Access 2018, 6, 10644–10649. [Google Scholar] [CrossRef]
- Kahu, S.Y.; Bhurchandi, K.M. A Low-Complexity, Sequential Video Compression Scheme Using Frame Differential Directional Filter Bank Decomposition in CIELa* b* Color Space. IEEE Access 2017, 5, 14914–14929. [Google Scholar] [CrossRef]
- Huang, X.; Liu, X.; Zhang, L. A Multichannel Gray Level Co-Occurrence Matrix for Multi/Hyperspectral Image Texture Representation. Remote Sens. 2014, 6, 8424–8445. [Google Scholar] [CrossRef] [Green Version]
- Rehman, T.U.; Zaman, Q.U.; Chang, Y.K.; Schumann, A.W.; Corscadden, K.; Esau, T. Optimising the parameters influencing performance and weed (goldenrod) identification accuracy of colour co-occurrence matrices. Biosyst. Eng. 2018, 170, 85–95. [Google Scholar] [CrossRef] [Green Version]
- Liu, X.; Zhao, D.; Jia, W.; Ji, W.; Sun, Y. A Detection Method for Apple Fruits Based on Color and Shape Features. IEEE Access 2019, 7, 67923–67933. [Google Scholar] [CrossRef]
- Ji, W.; Zhao, D.; Cheng, F.; Xu, B.; Zhang, Y.; Wang, J. Automatic recognition vision system guided for apple harvesting robot. Comput. Electr. Eng. 2012, 38, 1186–1195. [Google Scholar] [CrossRef]
- Zhao, Y.; Gong, L.; Huang, Y.; Liu, C. Robust Tomato Recognition for Robotic Harvesting Using Feature Images Fusion. Sensors 2016, 16, 173. [Google Scholar] [CrossRef] [PubMed] [Green Version]
- Haralick, R.M. Statistical and structural approaches to texture. Proc. IEEE 1979, 67, 786–804. [Google Scholar] [CrossRef]
- Lin, F.; Zhang, D.; Huang, Y.; Wang, X.; Chen, X. Detection of Corn and Weed Species by the Combination of Spectral, Shape and Textural Features. Sustainability 2017, 9, 1335. [Google Scholar] [CrossRef] [Green Version]
- Nakanishi, N. Normalization condition and normal and abnormal solutions of the bethe-salpeter equation. Phys. Rev. 1965, 138, B1182. [Google Scholar] [CrossRef]
- Pedregosa, F.; Varoquaux, G.; Gramfort, A.; Michel, V.; Thirion, B.; Grisel, O.; Blondel, M.; Prettenhofer, P.; Weiss, R.; Dubourg, V.; et al. Scikit-learn: Machine Learning in Python. J. Mach. Learn. Res. 2011, 12, 2825–2830. [Google Scholar]
- Wen, J.; Fang, X.; Cui, J.; Fei, L.; Yan, K.; Chen, Y.; Xu, Y. Robust Sparse Linear Discriminant Analysis. IEEE Trans. Circuits Syst. Video Technol. 2019, 29, 390–403. [Google Scholar] [CrossRef]
- Sabzi, S.; Abbaspourgilandeh, Y.; Garciamateos, G. A fast and accurate expert system for weed identification in potato crops using metaheuristic algorithms. Comput. Ind. 2018, 98, 80–89. [Google Scholar] [CrossRef]
- Sa, I.; Ge, Z.; Dayoub, F.; Upcroft, B.; Perez, T.; Mccool, C. DeepFruits: A Fruit Detection System Using Deep Neural Networks. Sensors 2016, 16, 1222. [Google Scholar] [CrossRef] [PubMed] [Green Version]
- Zhang, Q.; Liu, Y.; Gong, C.; Chen, Y.; Yu, H. Applications of Deep Learning for Dense Scenes Analysis in Agriculture: A Review. Sensors 2020, 20, 1520. [Google Scholar] [CrossRef] [PubMed] [Green Version]
Color Features | p-Value |
---|---|
R | |
G | |
B | |
H | |
S | |
V | |
X | |
Y | |
Z | |
L | |
A | |
B.1 | |
H.1 | |
E | |
D | |
Y.1 | |
U | |
V.1 | |
Y.2 | |
I | |
Q |
Texture Features | Minimum p-Value |
---|---|
Contrast | |
Dissimilarity | |
Homogeneity | |
ASM | |
Energy | |
Correlation |
Classifier Name | Train Set Accuracy | Test Set Accuracy | Train Set TPR | Test Set TPR |
---|---|---|---|---|
Nearest Neighbors | 0.94 | 0.85 | 0.89 | 0.86 |
Linear SVM | 0.87 | 0.88 | 0.88 | 0.79 |
RBF SVM | 0.90 | 0.91 | 0.85 | 0.83 |
Gaussian Process | 0.91 | 0.92 | 0.91 | 0.85 |
Decision Tree | 0.95 | 0.91 | 0.95 | 0.86 |
Random Forest | 0.94 | 0.94 | 0.94 | 0.90 |
Neural Net | 0.88 | 0.90 | 0.85 | 0.85 |
AdaBoost | 0.92 | 0.91 | 1.0 | 0.86 |
Naive Bayes | 0.90 | 0.90 | 0.86 | 0.83 |
QDA | 0.92 | 0.91 | 0.86 | 0.87 |
Method | Af | FPR | FNR |
---|---|---|---|
This designed segmentation method | 0.07 | 0.13 | 0.15 |
Otsu based on R-B and boundary object removal | 0.26 | 0.09 | 0.34 |
K-means cluster segmentation method based on R-B | 0.29 | 0.28 | 0.18 |
Adaptive threshold segmentation method based on R-B | 0.35 | 0.39 | 0.14 |
© 2020 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 (http://creativecommons.org/licenses/by/4.0/).
Share and Cite
Zhang, C.; Zou, K.; Pan, Y. A Method of Apple Image Segmentation Based on Color-Texture Fusion Feature and Machine Learning. Agronomy 2020, 10, 972. https://doi.org/10.3390/agronomy10070972
Zhang C, Zou K, Pan Y. A Method of Apple Image Segmentation Based on Color-Texture Fusion Feature and Machine Learning. Agronomy. 2020; 10(7):972. https://doi.org/10.3390/agronomy10070972
Chicago/Turabian StyleZhang, Chunlong, Kunlin Zou, and Yue Pan. 2020. "A Method of Apple Image Segmentation Based on Color-Texture Fusion Feature and Machine Learning" Agronomy 10, no. 7: 972. https://doi.org/10.3390/agronomy10070972
APA StyleZhang, C., Zou, K., & Pan, Y. (2020). A Method of Apple Image Segmentation Based on Color-Texture Fusion Feature and Machine Learning. Agronomy, 10(7), 972. https://doi.org/10.3390/agronomy10070972