Skip to main content
Log in

Spectral–Spatial Hyperspectral Image Classification Based on KNN

  • Original Paper
  • Published:
Sensing and Imaging Aims and scope Submit manuscript

Abstract

Fusion of spectral and spatial information is an effective way in improving the accuracy of hyperspectral image classification. In this paper, a novel spectral–spatial hyperspectral image classification method based on K nearest neighbor (KNN) is proposed, which consists of the following steps. First, the support vector machine is adopted to obtain the initial classification probability maps which reflect the probability that each hyperspectral pixel belongs to different classes. Then, the obtained pixel-wise probability maps are refined with the proposed KNN filtering algorithm that is based on matching and averaging nonlocal neighborhoods. The proposed method does not need sophisticated segmentation and optimization strategies while still being able to make full use of the nonlocal principle of real images by using KNN, and thus, providing competitive classification with fast computation. Experiments performed on two real hyperspectral data sets show that the classification results obtained by the proposed method are comparable to several recently proposed hyperspectral image classification methods.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5
Fig. 6
Fig. 7

Similar content being viewed by others

References

  1. Hughes, G. (1968). On the mean accuracy of statistical pattern recognizers. IEEE Transactions on Information Theory, 14(1), 55–63.

    Article  Google Scholar 

  2. Plaza, A., Benediktsson, J. A., Boardman, J. W., Brazile, J., Bruzzone, L., Camps-Valls, G., et al. (2009). Recent advances in techniques for hyperspectral image processing. Remote Sensing of Environment, 113(Supplement 1), S110–S122.

    Article  Google Scholar 

  3. Prasad, S., & Bruce, L. M. (2008). Limitations of principal components analysis for hyperspectral target recognition. IEEE Geoscience and Remote Sensing Letters, 5(4), 625–629.

    Article  Google Scholar 

  4. Villa, A., Benediktsson, J. A., Chanussot, J., & Jutten, C. (2011). Hyperspectral image classification with independent component discriminant analysis. IEEE Transactions on Geoscience and Remote Sensing, 49(12), 4865–4876.

    Article  Google Scholar 

  5. Jackson, Q., & Landgrebe, D. A. (2002). Adaptive bayesian contextual classification based on Markov random fields. IEEE Transactions on Geoscience and Remote Sensing, 40(11), 2454–2463.

    Article  Google Scholar 

  6. Ratle, F., Camps-Valls, G., & Weston, J. (2010). Semisupervised neural networks for efficient hyperspectral image classification. IEEE Transactions on Geoscience and Remote Sensing, 48(5), 2271–2282.

    Article  Google Scholar 

  7. Bittencourt, H.R., de Oliveira Moraes, D.A., & Haertel, V. (2007). A binary decision tree classifier implementing logistic regression as a feature selection and classification method and its comparison with maximum likelihood. In Proceedings of IEEE International Geoscience Remote Sensing Symposium (pp. 1755–1758).

  8. Stavrakoudis, D. G., Galidaki, G. N., Gitas, I. Z., & Theocharis, J. B. (2012). A genetic fuzzy-rule-based classifier for land cover classification from hyperspectral imagery. IEEE Transactions on Geoscience and Remote Sensing, 50(1), 130–148.

    Article  Google Scholar 

  9. Melgani, F., & Bruzzone, L. (2004). Classification of hyperspectral remote sensing images with support vector machines. IEEE Transactions on Geoscience and Remote Sensing, 42(8), 1778–1790.

    Article  Google Scholar 

  10. Benediktsson, J. A., Pesaresi, M., & Amason, K. (2003). Classification and feature extraction for remote sensing images from urban areas based on morphological transformations. IEEE Transactions on Geoscience and Remote Sensing, 41(9), 1940–1949.

    Article  Google Scholar 

  11. Plaza, A., Martinez, P., Plaza, J., & Perez, R. (2005). Dimensionality reduction and classification of hyperspectral image data using sequences of extended morphological transformations. IEEE Transactions on Geoscience and Remote Sensing, 43(3), 466–479.

    Article  Google Scholar 

  12. Kang, X., Li, S., & Benediktsson, J. A. (2014). Spectral-spatial hyperspectral image feature extraction with image fusion and recursive filtering. IEEE Transactions on Geoscience and Remote Sensing, 52(6), 3742–3752.

    Article  Google Scholar 

  13. Erturk, A., Gullu, M. K., & Erturk, S. (2013). Hyperspectral image classification using empirical mode decomposition with spectral gradient enhancement. IEEE Transactions on Geoscience and Remote Sensing, 51(5), 2787–2798.

    Article  Google Scholar 

  14. Demir, B., & Erturk, S. (2010). Empirical mode decomposition of hyperspectral images for support vector machine classification. IEEE Transactions on Geoscience and Remote Sensing, 48(11), 4071–4084.

    Google Scholar 

  15. Kang, X., Li, S., & Benediktsson, J. A. (2014). Spectral-spatial hyperspectral image classification with edge-preserving filtering. IEEE Transactions on Geoscience and Remote Sensing, 52(5), 2666–2677.

    Article  Google Scholar 

  16. Zhang, L., Zhang, L., Tao, D., & Huang, X. (2012). On combining multiple features for hyperspectral remote sensing image classification. IEEE Transactions on Geoscience and Remote Sensing, 50(3), 879–893.

    Article  Google Scholar 

  17. Zhang, L., Zhang, Q., Zhang, L., Tao, D., Huang, X., & Du, B. (2015). Ensemble manifold regularized sparse low-rank approximation for multiview feature embedding. Pattern Recognition, 48(10), 3102–3112.

    Article  Google Scholar 

  18. Fauvel, M., Tarabalka, Y., Benediktsson, J. A., Chanussot, J., & Tilton, J. C. (2013). Advances in spectral–spatial classification of hyperspectral images. Proceedings of the IEEE, 101(3), 652–675.

    Article  Google Scholar 

  19. Tarabalka, Y., Chanussot, J., & Benediktsson, J. A. (2010). Segmentation and classification of hyperspectral images using watershed transformation. Pattern Recognition, 43(7), 2367–2379.

    Article  MATH  Google Scholar 

  20. Tarabalka, Y., Benediktsson, J. A., & Chanussot, J. (2009). Spectral-spatial classification of hyperspectral imagery based on partitional clustering techniques. IEEE Transactions on Geoscience and Remote Sensing, 47(8), 2973–2987.

    Article  Google Scholar 

  21. Tarabalka, Y., Benediktsson, J. A., Chanussot, J., & Tilton, J. C. (2010). Multiple spectral–spatial classification approach for hyperspectral data. IEEE Transactions on Geoscience and Remote Sensing, 48(11), 4122–4132.

    Google Scholar 

  22. Chen, Q., Li, D., & Tang, C. K. (2013). KNN matting. IEEE Transactions on Pattern Analysis and Machine Intelligence, 35(9), 2175–2188.

    Article  MathSciNet  Google Scholar 

  23. Kang, X., Li, S., Fang, L., Li, M., & Benediktsson, J. A. (2015). Extended random walker-based classification of hyperspectral images. IEEE Transactions on Geoscience and Remote Sensing, 53(1), 144–153.

    Article  Google Scholar 

  24. Ma, L., Crawford, M. M., & Tian, J. (2010). Local manifold learning-based k-nearest-neighbor for hyperspectral image classification. IEEE Transactions on Geoscience and Remote Sensing, 48(11), 4099–4109.

    Google Scholar 

  25. Blanzieri, E., & Melgani, F. (2008). Nearest neighbor classification of remote sensing images with the maximal margin principle. IEEE Transactions on Geoscience and Remote Sensing, 46(6), 1804–1811.

    Article  Google Scholar 

  26. Jia, X., & Richards, J. A. (2005). Fast k-NN classification using the cluster-space approach. IEEE Geoscience and Remote Sensing Letters, 2(2), 225–228.

    Article  Google Scholar 

  27. Muja, M., Lowe, D.G. (2009). Fast approximate nearest neighbors with automatic algorithm configuration. In International Conference on Computer Vision Theory and Application (pp. 331–340). INSTICC Press.

  28. Chang, C. C., & Lin, C. J. (2011). LIBSVM: A library for support vector machines. ACM Transactions on Intelligent Systems and Technology, 2(3), 27:1–27:27.

    Article  Google Scholar 

  29. Li, J., Bioucas-Dias, J. M., & Plaza, A. (2011). Hyperspectral image segmentation using a new Bayesian approach with active learning. IEEE Transactions on Geoscience and Remote Sensing, 49(10), 3947–3960.

    Article  Google Scholar 

  30. Li, J., Bioucas-Dias, J. M., & Plaza, A. (2013). Spectral-spatial classification of hyperspectral data using loopy belief propagation and active learning. IEEE Transactions on Geoscience and Remote Sensing, 51(2), 844–856.

    Article  Google Scholar 

Download references

Acknowledgments

The authors would like to thank Dr. J. Li for providing the software of the LBP and LMLL methods. This paper was supported in part by the National Natural Science Foundation for Distinguished Young Scholars of China under Grant No. 61325007, the National Natural Science Foundation of China under Grant No. 61172161.

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Shutao Li.

Additional information

This article is part of the Topical Collection on Hyperspectral Imaging and Image Processing.

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Huang, K., Li, S., Kang, X. et al. Spectral–Spatial Hyperspectral Image Classification Based on KNN. Sens Imaging 17, 1 (2016). https://doi.org/10.1007/s11220-015-0126-z

Download citation

  • Received:

  • Revised:

  • Published:

  • DOI: https://doi.org/10.1007/s11220-015-0126-z

Keywords

Navigation