Skip to main content
Log in

Quantum Algorithm for K-Nearest Neighbors Classification Based on the Categorical Tensor Network States

  • Published:
International Journal of Theoretical Physics Aims and scope Submit manuscript

Abstract

The quantum K-nearest neighbor algorithm is superior to the classical K-nearest neighbor algorithm in terms of classification efficiency and accuracy. We utilize a graphical data structure called categorical tensor network states to describe the quantum K-nearest neighbors algorithm. Compared with the quantum K-nearest neighbor algorithm described by quantum circuit, it can make the complex core structures of the algorithm more intuitive, clear and readable while keeping the computation efficient. In addition, compared with the performance of the classical K-nearest neighbor algorithm, it can realize an exponential speed-up in terms of the time logarithmic in both the number of vectors and their dimension.

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
Fig. 8

Similar content being viewed by others

References

  1. Zhou, Z.H.: Machine Learning. Tsinghua University Press, BeiJing (2016)

    Google Scholar 

  2. Nielsen, M.A., Chuang, I.L.: Quantum Computation and Quantum Information. Cambridge University Press, Cambridge (2000)

    MATH  Google Scholar 

  3. Kopczyk, D.: arXiv:1804.10068 (2018)

  4. Aïmeur, E., Brassard, G., Sébastien, G.: . Adv. Artif. Intell. 431-442, 4013 (2006)

    Google Scholar 

  5. Jacob, B., Wittek, P., Pancotti, N., Rebentrost, P., Wiebe, P., Lloyd, S.: . Nature 549, 195–202 (2017)

    Article  ADS  Google Scholar 

  6. Shor, P.W.: Algorithms for quantum computation: discrete logarithms and factoring. In: Proceedings, 35th Annual Symposium on Fundamentals of Comp. Science (FOCS), pp 124–134 (1994)

  7. Grover, L.K.: A fast quantum mechanical algorithm for database search. In: Proceedings of the twenty-eighth annual ACM symposium on Theory of Computing, pp 212–219 (1996)

  8. Lloyd, S., Mohseni, M., Rebentrost, P.: . Nat. Phys. 631, 10 (2014)

    Google Scholar 

  9. Lloyd, S., Mohseni, M., Rebentrost, P.: . Phys. Rev. Lett. 130503, 113 (2013)

    Google Scholar 

  10. Wiebe, N., Kapoor, A., Svore, K.: . Quant. Infor. Comput. 15, 316 (2014)

    Google Scholar 

  11. Sheng, Y.B., Zhou, L.: . Sci Bull. 1025, 62 (2017)

    Google Scholar 

  12. Schuld, M., Sinayskiy, I., Petruccione, F.: . Contemp. Phys. 172, 56 (2014)

    Google Scholar 

  13. Adcock, J., Allen, E., Day, M., Frick, S., Hinchliff, J., Johnson, M., Morley-Short, S., Pallister, S., Price, A., Stanisic, S.: arXiv:1512.02900v1 (2015)

  14. Li, R., Li, P., Dong, Q.Y., Wang, B.: Machine Learning in Action. Posts and Telecom Press, BeiJing (2013)

    Google Scholar 

  15. Li, Q., Jiang, J.P.: . Syst. Eng. Electron. 940-943, 05 (2008)

    Google Scholar 

  16. Chen, H.W., Gao, Y., Zhang, J.: . J. SE. Univ. Nat. Scie. Ed. 647-651, 04 (2015)

    Google Scholar 

  17. Ruan, Y., Xue, X.L., Liu, H., Tan, J.N., Li, X.: . Int. J. Theor. Phys. 56, 3496–3507 (2017)

    Article  Google Scholar 

  18. Jiang, N., Dang, Y.J., Wang, J.: . Quantum Inf. Process. 15, 3543–3572 (2016)

    Article  ADS  MathSciNet  Google Scholar 

  19. Basheer, A., Goyal, S.K.: arXiv:2003.09187 (2020)

  20. Lloyd, S., Mohseni, M., Rebentrost, P.: arXiv:1307.0411(2013)

  21. Wang, Y.X., Wang, R.J., Li, D.F., Adu-Gyamfi, D., Tian, K.B., Zhu, Y.X.: . Int. J. Theor. Phys. 2331-2340, 58 (2019)

    Google Scholar 

  22. Orús, R.: . Eur. Phys. J. B 280, 87 (2014)

    Google Scholar 

  23. Evenbly, G., Vidal, G.: . J. Stat. Phys. 891-918, 145 (2011)

    Google Scholar 

  24. Penrose, R.: Applications of Negative Dimensional tensors. Academic Press, London (1971)

    MATH  Google Scholar 

  25. Werner, A.H., Jaschke, D., Silvi, P., Kliesch, M., Calarco, T., Eisert, J., Montangero, S.: . Phys. Rev. Lett. 237201, 116 (2016)

    Google Scholar 

  26. O’Rourke, M.J., Chan, G.K: . Phys. Rev. B 205142, 101 (2020)

    Google Scholar 

  27. Lafont, Y.: . J. Pur. Appl. Algebra 257-310, 184 (2003)

    Google Scholar 

  28. Biamonte, J.D., Bergholm, V., Lanzagorta, M.: . J. Phys. A Math. Theor 475301, 46 (2013)

    Google Scholar 

  29. Orús, R.: . Ann. Phys. 117-158, 349 (2014)

    MathSciNet  Google Scholar 

  30. Sachdev, S.: Tensor Networks a New Tool for Old Problems. APS physics, Cambridge (2009)

    Book  Google Scholar 

  31. Biamonte, J., Bergholm, V.: arXiv:1708.00006 (2017)

  32. Hauru, M., Vidal, G.: . Phys. Rev. A 042316, 98 (2018)

    Google Scholar 

  33. Biamonte, J., Kardashin, A., Uvarov, A.: arXiv:1804.02398(2018)

  34. Denny, S.J., Biamonte, J.D., Jaksch, D., Clark, S.R.: . J. Phys. A Math. Theor 015309, 45 (2012)

    Google Scholar 

  35. Dumitrescu, E.: . Rev. Phys. A 062322, 96 (2017)

    Google Scholar 

  36. Biamonte, J.: . Proc. Natl. Acad. Sci. 28242712, 114 (2017)

    Google Scholar 

  37. Barenco, A., Charles, H.B., Cleve, R., DiVincenzo, D.P., Margolus, N., Shor, P., Sleator, T., Smolin, J.A., Weinfurter, H.: . Phys. Rev. A 3457, 52 (1995)

    Google Scholar 

  38. Biamonte, J.D., Clark, S.R., Jaksch, D.: . AIP Adv. 042172, 1 (2011)

    Google Scholar 

  39. Bergholm, V., Biamonte, J.D.: . J. Phys. A Math. Theor 245304, 44 (2011)

    Google Scholar 

  40. Ren, D., Chen, X.: . Comput. Age. 17, 3 (2007)

    Google Scholar 

  41. Samet, H.: The Design and Analysis of Spatial Data Structures. Addison-Wesley, Reading, MA (1990)

    Google Scholar 

Download references

Acknowledgements

J. Zhang thanks K. He and R.-F. Ma for valuable discussion. This work was supported by the National Natural Science Foundation of China, (Grant Nos.11771011,11901421) and the Natural Science Foundation of Shanxi Province, China (Grant Nos.201801D221032,201801D221019) and Scientific and Technological Innovation Programs of Higher Education Institutions in Shanxi (Grant No. 2019L0178) and Youth Foundation of Taiyuan University of technology (No.2017QN13).

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Jun Zhang.

Additional information

Publisher’s Note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Ma, Yz., Song, Hf. & Zhang, J. Quantum Algorithm for K-Nearest Neighbors Classification Based on the Categorical Tensor Network States. Int J Theor Phys 60, 1164–1174 (2021). https://doi.org/10.1007/s10773-021-04742-y

Download citation

  • Received:

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s10773-021-04742-y

Keywords

Navigation