For the harvesting operation of tomato in agricultural production,it is very important to distinguish the maturity of tomato.For tomato picked,if the maturity is too low,the nutrition of the fruit has not been fully accumulated and can not be sold;Otherwise,if the maturity is too high,it is easy to rot and can not be stored for a long time.However,the traditional detection method of tomato maturity depends on manual.It has the disadvantages of subjective judgment error,time-consuming and laborious,and can not be carried out in batches.In order to solve this problem,in this paper,the computer vision technology is proposed to realize the automatic detection of tomato maturity for red and yellow fruit.Firstly,this paper contrasts and analyzes different image pre-processing and segmentation methods.The results indicate that linear interpolation in image size normalization,median filtering in image denoising and R-component and B-component difference in image segmentation could be more better.Secondly,this paper experiments two kinds of classification model tools based on SVM.Fitcecoc model extracts different color,shape,texture and other features of tomato,and proposes to extract features of color,shape and texture respectively by R,G,B,H,S,V mean values,Hu invariant matrix and gray-level co-occurrence matrix could be more better by using model evaluation indices such as confusion matrix.Libsvm model extracts color square and color moment features of tomato image,and conducts model training and testing after cross validation to find the optimal parameters.The experimental results show that the accuracies of the two models are 83.3% and 94.4% respectively.Finally,in this paper,the tomato maturity detection system based on MATLAB platform is designed,including the three modules:training model,tomato pictures input module and maturity results display module.The research results of this paper have positive and practical significance for promoting the application in the detection of tomato maturity by using computer vision technology. |