# A Novel Method for Wheat Spike Phenotyping Based on Instance Segmentation and Classification
## 3 Results and Discussion
### Classification Results of Spiklets
However, the spikelets containing two grains were easily predicted as those containing three grains and vice versa. The AUC values of ROC curves also verified that the SVM model had better classification results for the spikelets containing zero and one grain, and it had slightly worse results for the spikelets containing two and three grains. Some of the spikelets containing two and three grains had certain similarities in the extracted image features, resulting in larger classification errors of the latter two categories of spikelets. Despite all that, the SVM model still achieved excellent overall classification performance in accuracy, precision, recall, and F1 score, and was stable. It is feasible to classify the spikelet grain quantities by the machine learning model with the spikelet image features as inputs. The feature importance scores obtained by the six feature selection methods in Figure 12 show that there were different degrees of importance for the 52 image features in the classification of spikelets. From the overall analysis, the correlation between texture features and grain number was the highest, while the correlation between color features and grain number was the lowest. In more detail, the features that were highly correlated with grain number were Are, Per, CHAR, CHPR, FEH1, FEH2, FEH3, Con, Ene, and bin0-bin9. The features that were weakly correlated with grain number were WLR, H1-H7, Ic, FED3, FEV3, and Hom. This study set the importance score threshold at 0.2 to select more correlated features from all 52 spikelet image features. The classification results of the spikelets are based on selected features and the SVM model, as shown in Table 3.  
The SVM models with the image features selected by the CS test and F-test had the worst overall performance in predicting the grain number of spikelets. MIE, L1, and ERT had more advantages in mining nonlinear correlation, thus the SVM models with the image features selected by the above three methods had superior performance. The overall performance in classifying spikelets based on the features selected by RF was closest to that achieved when classifying spikelets based on all features. The accuracy of training datasets and the accuracy, precision, recall, and F1 score of testing datasets reached 0.838, 0.840, 0.843, 0.845, and 0.844, respectively. RF removed nearly half of the unimportant features and improved the efficiency of the SVM model. Therefore, the feature selection method, RF, achieved the best comprehensive performance in classification efficiency and accuracy. Figure 12: Importance score of spikelet image feature based on different feature selection methods. \begin{table}
\begin{tabular}{c c c c c c} \hline \hline
**Feature Selection** & **A of Training** & **A of Test** & **P of Test** & **R of Test** & **F1 Score of Test** \\
**Methods** & **Dataset** & **Dataset** & **Dataset** & **Dataset** & **Dataset** \\ \hline CS test & 0.742 & 0.760 & 0.785 & 0.738 & 0.756 \\ \hline F-test & 0.742 & 0.758 & 0.784 & 0.737 & 0.755 \\ \hline MIE & 0.798 & 0.819 & 0.827 & 0.833 & 0.830 \\ \hline L1 & 0.791 & 0.805 & 0.807 & 0.811 & 0.809 \\ \hline RF & 0.838 & 0.840 & 0.843 & 0.845 & 0.844 \\ \hline ERT & 0.801 & 0.812 & 0.812 & 0.821 & 0.815 \\ \hline \hline \end{tabular}
\end{table} 
Table 3: Classification results of the spikelets based on selected features and SVM.