Skip to main content
Log in

CUDAQuat: new parallel framework for fast computation of quaternion moments for color images applications

  • Published:
Cluster Computing Aims and scope Submit manuscript

Abstract

Quaternion moments are widely used in several applications, such as image classification, object recognition, and multimedia security. The computation of these moments requires a vast computational time, especially for big-size images. Several attempts to accelerate quaternion moments are not enough to process big-size color images with the desired speedup. In this work, we proposed a new parallel framework for fast computation of quaternion moments in Cartesian coordinates using multi-core CPUs and many-core graphics processing units (GPUs) with the Compute Unified Device Architecture (CUDA). We called the proposed unified computational framework “CUDAQuat.” This framework was tested by eleven sets of quaternion moments. Several applications executed using the proposed parallel framework where the CPU times, execution-time-improvement ratio, and speedup were reported. The evaluation outlined significant speedup over the single-core CPU implementation, where the proposed framework accelerated several sets of quaternion moments with speedup 600x.

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. He, B., Cui, J.: Weighted spherical Bessel–Fourier image moments. Clust. Comput. 22, 12985–12996 (2019)

    Article  Google Scholar 

  2. Papakostas, G.A.: Over 50 Years of Image Moments and Moment Invariants. Moments and Moment Invariants-Theory and Applications, pp. 3–32. Science Gate Publishing, Thrace (2014)

    Google Scholar 

  3. Flusser, J., Suk, T., Zitova, B.: 2D and 3D Image Analysis by Moments. Wiley, Hoboken (2016)

    Book  MATH  Google Scholar 

  4. Ell, T.A., Sangwine, S.J.: Robust hand gesture recognition of color images. IEEE Trans. Image Process. 16, 22–35 (2007)

    Article  MathSciNet  MATH  Google Scholar 

  5. Hamilton, W.R.: Elements of Quaternions. Longmans Green, London (1866)

    Google Scholar 

  6. Guo, L., Zhu, M.: Quaternion Fourier–Mellin moments for color images. Pattern Recogn. 44(2), 187–195 (2011)

    Article  MATH  Google Scholar 

  7. Chen, B.J., Shu, H.Z., Zhang, H., Chen, G., Toumoulin, C., Dillenseger, J.L., Luo, L.M.: Quaternion Zernike moments and their invariants for color image analysis and object recognition. Signal Process. 92(2), 308–318 (2012)

    Article  Google Scholar 

  8. Chen, B., Xingming, S., Wang, D., Zhao, X.: Color face recognition using quaternion representation of color image. Acta Autom. Sin. 38(11), 1815–1823 (2012)

    Article  MathSciNet  MATH  Google Scholar 

  9. Wang, X., Li, W., Yang, H., Wang, P., Li, Y.: Quaternion polar complex exponential transform for invariant color image description. Appl. Math. Comput. 256, 951–967 (2015)

    MathSciNet  MATH  Google Scholar 

  10. Wang, X., Li, W., Yang, H., Niu, P., Li, Y.: Invariant quaternion radial harmonic Fourier moments for color image retrieval. Opt. Laser Technol. 66, 78–88 (2015)

    Article  Google Scholar 

  11. Yang, H.Y., Liang, L.L., Li, Y.W., Wang, X.Y.: Quaternion exponent moments and their invariants for color image. Fundamenta Informaticae 145(2), 189–205 (2016)

    Article  MathSciNet  MATH  Google Scholar 

  12. Hosny, K.M., Darwish, M.M.: New set of quaternion moments for color images representation and recognition. J. Math. Imaging Vision 60(5), 717–736 (2018)

    Article  MathSciNet  MATH  Google Scholar 

  13. Singh, C., Singh, J.: Quaternion generalized Chebyshev–Fourier and pseudo-Jacobi–Fourier moments. Opt. Laser Technol. 106, 234–250 (2018)

    Article  Google Scholar 

  14. Hosny, K.M., Darwish, M.M.: Invariant color images representation using accurate quaternion Legendre–Fourier moments. Pattern Anal. Appl. 22(3), 1105–1122 (2019)

    Article  MathSciNet  Google Scholar 

  15. Darwish, M.M., Kamal, S.T., Hosny, K.M.: “Improved Color Image Watermarking using Logistic Maps and Quaternion Legendre-Fourier moments Studies in Computational Intelligence, pp. 137–158. Springer, New York (2020). https://doi.org/10.1007/978-3-030-38700-6_6

    Book  Google Scholar 

  16. Hosny, K.M., Darwish, M.M.: Resilient color image watermarking using quaternion radial substituted Chebychev moments. ACM Trans. Multimedia Comput. Commun. Appl. 15(2), 46 (2019)

    Article  Google Scholar 

  17. Chunpeng, W., Xingyuan, W., Zhiqiu, X., Chuan, Z.: Ternary radial harmonic Fourier moments based robust stereo image zero-watermarking algorithm. Inf. Sci. 470, 109–120 (2019)

    Article  Google Scholar 

  18. Hosny, K.M., Darwish, M.M.: Robust color image watermarking using invariant quaternion Legendre-Fourier moments. Multimedia Tools Appl. 77, 24727–24750 (2018)

    Article  Google Scholar 

  19. Xia, Z., Wang, X., Zhou, W., Li, R., Wang, C., Zhang, C.: Color medical image lossless watermarking using chaotic system and accurate quaternion polar harmonic transforms. Signal Process. 157, 108–118 (2019)

    Article  Google Scholar 

  20. Zhiqiu, X., Xingyuan, W., Xiaoxiao, L., Chunpeng, W., Unar, S., Mingxu, W., Tingting, Z.: Efficient copyright protection for three CT images based on quaternion polar harmonic Fourier moments. Signal Process. 164, 368–379 (2019)

    Article  Google Scholar 

  21. Ouyang, J., Wen, X., Liu, J., Chen, J.: Robust Hashing Based on Quaternion Zernike Moments for Image Authentication. ACM Trans. Multimedia Comput. Commun. Appl. 12(45), 1–13 (2016). https://doi.org/10.1145/2978572

    Article  Google Scholar 

  22. Hosny, K.M., Khedr, Y.M., Khedr, W.I., Mohamed, E.R.: Robust color image hashing using quaternion polar complex exponential transform for image robust copy-move forgery detection authentication. J. Circ. Syst. Signal Process. 37(12), 5441–5462 (2018)

    Article  Google Scholar 

  23. Wang, X.Y., Liu, Y.N., Xu, H., Wang, P., Yang, H.Y.: Robust copy-move forgery detection using quaternion exponent moments. Pattern Anal. Appl. 21(2), 451–467 (2018)

    Article  MathSciNet  Google Scholar 

  24. Hosny, K.M., Hamza, H.M., Lashin, N.A.: Copy-for-duplication forgery detection in colour images using QPCETMs and sub-image approach. IET Image Proc. 13(9), 1437–1446 (2019)

    Article  Google Scholar 

  25. Thajeel, S.A., Mahmood, A.S., Humood, W.R., Sulong, G.: Detection copy-move forgery in image via quaternion polar harmonic transforms. TIIS 13(8), 4005–4025 (2019)

    Google Scholar 

  26. Su, L., Li, C., Lai, Y., Yang, J.: A fast forgery detection algorithm based on exponential-Fourier moments for video region duplication. IEEE Trans. Multimedia 20(4), 825–840 (2018)

    Article  Google Scholar 

  27. Chen, B., Qi, X., Sun, X., Shi, Y.-Q.: Quaternion pseudo-Zernike moments combining both of RGB information and depth information for color image splicing detection. J. Vis. Commun. Image Represent. 49, 283–290 (2017)

    Article  Google Scholar 

  28. Camacho-Bello, C., Padilla-Vivanco, A., Toxqui-Quitl, C., Báez-Rojas, J.J.: Reconstruction of color biomedical images by means of quaternion generic Jacobi-Fourier moments in the framework of polar pixels. J. Med. Imaging 3(1), (2016)

    Article  Google Scholar 

  29. Hua, L., Qiang, Y., Gu, J., Chen, L., Zhang, X., Zhu, H.: Mechanical fault diagnosis using color image recognition of vibration spectrogram based on quaternion invariable moment. Math. Probl. Eng. 15, 1–11 (2015). https://doi.org/10.1155/2015/702760

    Article  MathSciNet  MATH  Google Scholar 

  30. Guo, L., Dai, M., Zhu, M.: Quaternion moment and its invariants for color object classification. Inf. Sci. 273, 132–143 (2014)

    Article  MathSciNet  Google Scholar 

  31. Dad, N., En-Nahnahi, N., El El Alaoui Ouatik, S.: Quaternion Harmonic moments and extreme learning machine for color object recognition. Multimedia Tools Appl. 78, 20935–20959 (2019)

    Article  Google Scholar 

  32. Dad, N., En-Nahnahi, N., El Alaoui Ouatik, S.: Combining minutiae triplets and quaternion orthogonal moments for fingerprint verification. J. Electron. Imaging 26(3), (2017). https://doi.org/10.1117/1.JEI.26.3.033012

    Article  Google Scholar 

  33. Wang, X.-Y., Zhi-Fang, W., Chen, L., Zheng, H.-L., Yang, H.-Y.: Pixel classification based color image segmentation using quaternion exponent moments. Neural Netw. 74, 1–13 (2016)

    Article  Google Scholar 

  34. Wang, X.Y., Wang, Q., Wang, X.B., Yang, H.Y., Wu, Z.F., Niu, P.P.: Color image segmentation using proximal classifier and quaternion radial harmonic Fourier moments. Pattern Anal. Appl. (2019). https://doi.org/10.1007/s10044-019-00826-y

    Article  Google Scholar 

  35. Wang, X.-Y., Liang, L.-L., Li, Y.-W., Yang, H.-Y.: Image retrieval based on exponent moments descriptor and localized angular phase histogram. Multimedia Tools Appl. 76, 7633–7659 (2017)

    Article  Google Scholar 

  36. Hassan, G., Hosny, K.M., Farouk, R.M., AlZohairy, A.M.: An efficient retrieval system for biomedical images based on Radial Associated Laguerre Moments. IEEE Access 8, 175669–175687 (2020)

    Article  Google Scholar 

  37. Hassan, G., Hosny, K.M., Farouk, R.M., AlZohairy, A.M.: Efficient Quaternion Moments for Representation and Retrieval of Biomedical Color Images. Biomed. Eng. 32(5), 16 (2020)

    Google Scholar 

  38. Elouariachi, I., Benouini, R., Zenkouar, K., Zarghili, A.: Robust hand gesture recognition system based on a new set of quaternion Tchebichef moment invariants. Pattern Anal. Appl. (2020). https://doi.org/10.1007/s10044-020-00866-9

    Article  Google Scholar 

  39. Karakasis, E.G., Papakostas, G.A., Koulouriotis, D.E., Tourassis, V.D.: A unified methodology for computing accurate quaternion color moments and moment invariants. IEEE Trans. Image Process. 23(2), 596–611 (2014)

    Article  MathSciNet  MATH  Google Scholar 

  40. Hosny, K.M., Darwish, M.M.: Accurate computation of quaternion polar complex exponential transform for color images in different coordinate systems. J. Electron. Imaging 26(2), (2017)

    Article  Google Scholar 

  41. Hosny, K.M., Darwish, M.M.: Highly accurate and numerically stable higher-order QPCET moments for color image representation. Pattern Recogn. Lett. 97, 29–36 (2017)

    Article  Google Scholar 

  42. Singh, S.P., Urooj, S.: A new computational framework for fast computation of a class of polar harmonic transforms. J. Signal Process. Syst. 91, 915–922 (2019)

    Article  Google Scholar 

  43. Çavuşoğlu, Ü., Kaçar, S.: A novel parallel image encryption algorithm based on chaos. Clust. Comput. 22, 1211–1223 (2019)

    Article  Google Scholar 

  44. Magid, S.A., Petrini, F., Dezfouli, B.: Image classification on IoT edge devices: profiling and modeling. Clust. Comput. 23, 1025–1043 (2020)

    Article  Google Scholar 

  45. Tariq, S.A., Iqbal, S., Ghafoor, M., Taj, I.A., Jafri, N.M., Razzaq, S., Zia, T.: Massively parallel palmprint identification system using GPU. Clust. Comput. 22, 7201–7216 (2019)

    Article  Google Scholar 

  46. Alawneh, L., Shehab, M.A., Al-Ayyoub, M., Jararweh, Y., Al-Sharif, Z.A.: A scalable multiple pairwise protein sequence alignment acceleration using hybrid CPU–GPU approach. Clust. Comput. 23, 2677–2688 (2020)

    Article  Google Scholar 

  47. Afif, M., Said, Y., Atri, M.: Computer vision algorithms acceleration using graphic processors NVIDIA CUDA. Clust. Comput. 23, 3335–3347 (2020)

    Article  Google Scholar 

  48. Toharia, P., Robles, O.D., SuáRez, R., Bosque, J.L., Pastor, L.: Shot boundary detection using Zernike moments in multi-GPU multi-CPU architectures. J. Parallel Distrib. Comput. 72(9), 1127–1133 (2012)

    Article  Google Scholar 

  49. Requena, M.J.M., Moscato, P., Ujaldón, M.: Efficient data partitioning for the GPU computation of moment functions. J. Parallel Distrib. Comput. 74(1), 1994–2004 (2014)

    Article  Google Scholar 

  50. Lachiondo, J.A., Ujaldón, M., Berretta, R., Moscato, P.: Legendre moments as high performance bone biomarkers: computational methods and GPU acceleration. Comput. Methods Biomech. Biomed. Eng. 4(3–4), 146–163 (2016)

    Google Scholar 

  51. Xuan, Y., Li, D., Han, W.: Efficient optimization approach for fast GPU computation of Zernike moments. J. Parallel Distrib. Comput. 111, 104–114 (2018)

    Article  Google Scholar 

  52. Zhao, Z., Kuang, X., Zhu, Y., Liang, Y., Xuan, Y.: Combined kernel for fast GPU computation of Zernike moments. J. Real-Time Image Process. 1, 11 (2020). https://doi.org/10.1007/s11554-020-00979-8

    Article  Google Scholar 

  53. Hosny, K.M., Salah, A., Saleh, H.I., Sayed, M.: Fast computation of 2D and 3D Legendre moments using multi-core CPUs and GPU parallel architectures. J. Real-Time Image Proc. 16(6), 2027–2041 (2019)

    Article  Google Scholar 

  54. Yang, Zhuo, Tang, Mingkai, Li, Zhuozhang, Ren, Ziliang, Zhang, Qieshi: GPU Accelerated Polar Harmonic Transforms for Feature Extraction in ITS Applications. IEEE Access 8, 95099–95108 (2020)

    Article  Google Scholar 

  55. Heidari, H., Chalechale, A. and Mohammadabadi, A.A.: Accelerating of color moments and texture features extraction using GPU based parallel computing. In 2013 8th Iranian Conference on Machine Vision and Image Processing (MVIP) (pp. 430–435). IEEE (2013)

  56. Hosny, K.M., Darwish, M.M., Li, K., Salah, A.: Parallel multi-core CPU and GPU for fast and robust medical image watermarking. IEEE Access 6, 77212–77225 (2018)

    Article  Google Scholar 

  57. Salah, A., Li, K., Hosny, K.M., Darwish, M.M., Tian, Q.: Accelerated CPU–GPUs implementations for quaternion polar harmonic transform of color images. Fut. Gener. Comput. Syst. 107, 368–382 (2020)

    Article  Google Scholar 

  58. Wen-mei, W.H.: GPU Computing Gems, Emerald edn. Elsevier, Amsterdam (2011)

    Google Scholar 

  59. Di Carlo S., Gambardella G., Indaco M. et al.: A software-based self test of CUDA Fermi GPUs. pp. 1–6 (2013)

  60. Lazebnik, S., Schmid, C., Ponce, J.: A maximum entropy framework for part-based texture and object recognition. Proc. IEEE Int. Conf. Comput. Vis. Beijing China 1, 832–838 (2005)

  61. Navin, G., George, B., Nefian, A.V.: Face recognition experiments with random projections. In: SPIE Conference on Biometric Technology for Human Identification (2005)

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Khalid M. Hosny.

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

Hosny, K.M., Darwish, M.M., Salah, A. et al. CUDAQuat: new parallel framework for fast computation of quaternion moments for color images applications. Cluster Comput 24, 2385–2406 (2021). https://doi.org/10.1007/s10586-021-03271-x

Download citation

  • Received:

  • Revised:

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s10586-021-03271-x

Keywords

Navigation