# Hyperspectral Image Classification with Imbalanced Data Based on Semi-Supervised Learning
## 4 Results
### Comparison of Different Multi-Classification Algorithms  
NearPseudo is a preprocessing technique that can improve the capacity of most machine-learning classifiers to handle imbalanced data. As described in the previous subsections, RF was used as the main classifier in NearPseudo. In this experiment, we utilized several types of common classifiers in the hyperspectral images to classify the unbalanced and balanced dataset after preprocessing by NearPseudo. These classifiers included RF, CART, LR, and \(k\)NN. Based on the results of classification accuracy (Table 5), we quantitatively evaluated the improvement in the imbalanced ability of these classifiers after the processing of NearPseudo. For this experiment, we illustrate our results by using a detailed example of the imbalanced dataset **T2**.  
As shown in Table 5, before preprocessing, the RF classifier exhibited the best classification accuracy (OA = 73.3%), followed by \(k\)NN (OA = 65.8%), LR (OA = 63.1%), and CART (OA = 57.0%). After processing by NearPseudo, the best classification accuracy was still achieved by the RF (OA = 75.1%), followed by \(k\)NN (OA = 69.8%), LR (OA = 69.5%), and CART (OA = 60.7%). As can be seen, after balancing the imbalanced training set **T2** using NearPseudo, the classification performance of the four commonly used multi-classifiers improved. Compared with the unbalanced condition, the OA values of RF, \(k\)NN, LR, and CART increased by 1.8%, 4.0%, 6.4%, and 3.7%, respectively. The effect of NearPseudo on accuracy is related to the capacity of machine-learning algorithms to handle imbalanced datasets. The classification performance of most multi-classifiers with imbalanced data can be improved by using NearPseudo.  
Figure 2: Mean change in overall accuracy from baseline (unbalanced dataset) to balanced dataset after processing on the three sub-training sets. **T1**, **T2**, and **T3** represent datasets with different degrees of imbalance. **T1** represents an extremely imbalanced training dataset with R (Max/Min) = 14.0, **T2** represents a relatively imbalanced training dataset with R (Max/Min) = 3.5, and **T3** represents a slightly imbalanced training dataset with R (Max/Min) = 1.6. All data are mean \(\pm\) standard error from five measurements.  
A significant improvement was observed in F1 scores of minority classes in each classifier before and after processing by NearPseudo. In imbalanced dataset **T2**, the _Amygdalu_ (NO. 12) and _Zea mays_ (NO. 8) classes were the minority classes and had the fewest samples (only 800 training samples) (Table 1). The F1 scores of these two classes using four common classifiers improved after processing by NearPseudo. In particular, for _Zea mays_ (NO. 8), the F1 scores of RF, _k_NN, LR and CART increased by 2.4%, 11.1%, 20%, and 11.9%, respectively. For _Amygdalu_ (NO. 12), the F1 scores of RF, _k_NN, LR, and CART increased by 6.9%, 11.1%, 20%, and 11.9%, respectively. This further illustrates the improvement in the accuracy of most minority classes and the reduction of bias of most models by NearPseudo.