# Image Classification for Automated Image Cross-Correlation Applications in the Geosciences
## 4 Results
### Cross-Validation and Image Classification  
The results of the cross-validation (Table 4) show that the minimum classification curve is achieved by using three or four features to train the SVMs (Figure 7), where the minimum error obtained ranges between 0.03% and 7.9% (with a weighted mean of 5.2%). In contrast, greater errors are obtained when more than four features are employed; this can probably be ascribed to overfitting in the training phase, as the number of training elements is limited.  
The _colorNum_ is evidently the predominant and most relevant feature in the classification. For each dataset, it is found to be the most important feature; it alone provides a misclassification error in the range of 6% to 18%. _InueMean_ is included in the group of relevant features in five of the datasets, whereas _greyNum_ and _satMean_ are never selected as relevant features. However, the features required for a proper training of the SVM differ between the datasets, and it is thus necessary to train a dedicated SVM for each specific scene.  
For the MNS2_b dataset, a local minimum is achieved with only two features, while the absolute maximum is obtained with four features. Considering that this dataset comprises a limited number of images, training the SVM with two features is probably the best solution to avoid overfitting.  
\begin{table}
\begin{tabular}{c c c c c c c c} \hline
**Dataset** & **I** & **II** & **III** & **IV** & **V** & **VI** & **VII** \\ \hline ACC & _colorNum_ & _lueMean_ & _maxPeak_ & _posPeak_ & _satMean_ & _greyNum_ & _blackNum_ \\ SAXE1 & _colorNum_ & _posPeak_ & _hueMean_ & _blackNum_ & _maxPeak_ & _greyNum_ & _satMean_ \\ SAXE2 & _colorNum_ & _maxPeak_ & _posPeak_ & _hueMean_ & _greyNum_ & _satMean_ & _blackNum_ \\ SAXE3\_a & _colorNum_ & _hueMean_ & _greyNum_ & _maxPeak_ & _satMean_ & _posPeak_ & _blackNum_ \\ MNS2\_b & _colorNum_ & _blackNum_ & _maxPeak_ & _greyNum_ & _hueMean_ & _satMean_ & _posPeak_ \\ PPCX1 & _colorNum_ & _hueMean_ & _blackNum_ & _posPeak_ & _satMean_ & _greyNum_ & _maxPeak_ \\ PPCX2\_a & _colorNum_ & _posPeak_ & _hueMean_ & _blackNum_ & _maxPeak_ & _greyNum_ & _satMean_ \\ \hline \end{tabular}
\end{table}
Table 4: Order of features identified during cross-validation analysis for each dataset; features in black are those selected for classification.  
Figure 6: Mean and standard deviation of cross-correlation maps for all possible couples of shaded relief images. The two matrices on the left refer to the horizontal direction and those on the right refer to the vertical. The elements of the matrices correspond to the couples formed from the \(i\)th and \(j\)th images of a sequence of ten images that were ordered to simulate the motion of the sun during the day.  
It is also worth noting that to select the minimum number of features, it may be a good criterion to use the features up to where the error curve decreases by less than 0.5% when one more feature is added. Using this approach, two or three features would be sufficient, depending on the dataset.  
Figure 8 shows an example of image classification using the two of the most relevant features obtained from the cross-validation (Table 4), to illustrate the migration of feature values among the different visual conditions. From the graph, it can be seen how _colorNum_ increases from the NoVis, DiffLight and SunLight classes (which is expected) while _hueMean_ of the SunLight class is lower.  
Figure 8: Image classification of PPCX_1 images using the two principal features _hueMean_ and _colorNum_. The regions delimit the areas where new elements within are classified as belonging to the corresponding class.  
Figure 7: Error curves (expressed as fraction of misclassification) obtained from cross-validation of the support vector machine (SVM) training. The minimum was always reached by employing three or four features.