Skip to main content
Log in

An effective real-time color quantization method based on divisive hierarchical clustering

  • Special Issue
  • Published:
Journal of Real-Time Image Processing Aims and scope Submit manuscript

Abstract

Color quantization (CQ) is an important operation with many applications in graphics and image processing. Clustering algorithms have been extensively applied to this problem. In this paper, we propose a simple yet effective CQ method based on divisive hierarchical clustering. Our method utilizes the commonly used binary splitting strategy along with several carefully selected heuristics that ensure a good balance between effectiveness and efficiency. We also propose a slightly computationally expensive variant of this method that employs local optimization using the Lloyd–Max algorithm. Experiments on a diverse set of publicly available images demonstrate that the proposed method outperforms some of the most popular quantizers in the literature.

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.

Institutional subscriptions

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

Similar content being viewed by others

References

  1. Balasubramanian, R., Allebach, J.: A new approach to palette selection for color images. J. Imaging Technol. 17(6), 284–290 (1991)

    Google Scholar 

  2. Bentley, J.L.: Multidimensional binary search trees used for associative searching. Commun. ACM 18(9), 509–517 (1975)

    Article  MATH  MathSciNet  Google Scholar 

  3. Bing, Z., Junyi, S., Qinke, P.: An adjustable algorithm for color quantization. Pattern Recogn. Lett. 25(16), 1787–1797 (2004)

    Article  Google Scholar 

  4. Braudaway, G.W.: Procedure for optimum choice of a small number of colors from a large color palette for color imaging. In: Proceedings of the Electronic Imaging Conference, pp. 71–75 (1987)

  5. Brun, L., Mokhtari, M.: Two high speed color quantization algorithms. In: Proceedings of the 1st International Conference on Color in Graphics and Image Processing, pp. 116–121 (2000)

  6. Brun, L., Trémeau, A.: Color quantization. In: Sharma, G. (ed.) Digital Color Imaging Handbook, CRC Press, pp. 589–638 (2002)

  7. Cak, S., Dizdar, E.N., Ersak, A.: A fuzzy colour quantizer for renderers. Displays 19(2), 61–65 (1998)

    Article  Google Scholar 

  8. Celebi M.E.: An effective color quantization method based on the competitive learning paradigm. In: Proceedings of the International Conference on Image Processing, Computer Vision, and Pattern Recognition, vol. 2, pp. 876–880 (2009)

  9. Celebi, M.E.: Improving the performance of K-means for color quantization. Image Vis. Comput. 29(4), 260–271 (2011)

    Article  MathSciNet  Google Scholar 

  10. Celebi, M.E., Schaefer, G.: Neural gas clustering for color reduction. In: Proceedings of the International Conference on Image Processing, Computer Vision, and Pattern Recognition, pp. 429–432 (2010)

  11. Chan, C.K., Ma, C.K.: A fast method of designing better codebooks for image vector quantization. IEEE Trans. Commun. 42(2/3/4):237–242 (1994)

    Google Scholar 

  12. Chang, C.H., Xu, P., Xiao, R., Srikanthan, T.: New adaptive color quantization method based on self-organizing maps. IEEE Trans. Neural Netw. 16(1), 237–249 (2005)

    Article  Google Scholar 

  13. Cheng, S., Yang, C.: Fast and novel technique for color quantization using reduction of color space dimensionality. Pattern Recogn. Lett. 22(8), 845–856 (2001)

    Article  MATH  Google Scholar 

  14. Chung, K.L., Huang, Y.H., Wang, J.P., Cheng, M.S.: Speedup of color palette indexing in self-organization of kohonen feature map. Expert Syst. Appl. 39(3), 2427–2432 (2012)

    Article  Google Scholar 

  15. Cormen, T.H., Leiserson, C.E., Rivest, R.L., Stein, C.: Introduction to Algorithms. The MIT Press, Cambridge (2009)

  16. Dekker, A.: Kohonen neural networks for optimal colour quantization. Netw.: Comput. Neural Syst. 5(3), 351–367 (1994)

    Article  MATH  Google Scholar 

  17. Deng, Y., Manjunath, B.: Unsupervised segmentation of color-texture regions in images and video. IEEE Trans. Pattern Anal. Mach. Intell. 23(8), 800–810 (2001)

    Article  Google Scholar 

  18. Deng, Y., Manjunath, B., Kenney, C., Moore, M., Shin, H.: An efficient color representation for image retrieval. IEEE Trans. Image Process. 10(1), 140–147 (2001)

    Article  MATH  Google Scholar 

  19. Equitz, W.H.: A new vector quantization clustering algorithm. IEEE Trans. Acoust. Speech Signal Process. 37(10), 1568–1575 (1989)

    Article  Google Scholar 

  20. Frackiewicz, M., Palus, H.: KM and KHM clustering techniques for colour image quantisation. In: Joao Manuel, R., Tavares, S., Natal Jorge, R.M. (eds.) Computational Vision and Medical Image Processing: Recent Trends. Springer, Berlin, pp. 161–174 (2011)

  21. Gentile, R.S., Allebach, J.P., Walowit, E.: Quantization of color images based on uniform color spaces. J. Imaging Technol. 16(1), 11–21 (1990)

    Google Scholar 

  22. Gervautz, M., Purgathofer, W.: Simple method for color quantization: octree quantization. In: Magnenat-Thalmann, N., Thalmann, D. (eds.) New trends in Computer Graphics, Springer, Berlin, pp. 219–231 (1988)

  23. Goldberg, N.: Colour image quantization for high resolution graphics display. Image Vis. Comput. 9(5), 303–312 (1991)

    Article  Google Scholar 

  24. Heckbert, P.: Color image quantization for frame buffer display. ACM SIGGRAPH Comput. Graph. 16(3), 297–307 (1982)

    Article  Google Scholar 

  25. Hsieh, I.S., Fan, K.C.: An adaptive clustering algorithm for color quantization. Pattern Recogn. Lett. 21(4), 337–346 (2000)

    Article  Google Scholar 

  26. Hu, Y.C., Lee, M.G.: (2007) K-means based color palette design scheme with the use of stable flags. J. Electron. Imaging 16(3):033003

    Google Scholar 

  27. Hu, Y.C., Su, B.H.: Accelerated K-means clustering algorithm for colour image quantization. Imaging Sci. J. 56(1), 29–40 (2008)

    Article  Google Scholar 

  28. Hu, Y.C., Su, B.H.: Accelerated pixel mapping scheme for colour image quantisation. Imaging Sci. J. 56(2), 68–78 (2008)

    Article  Google Scholar 

  29. Huang, Y.L., Chang, R.F.: A fast finite-state algorithm for generating RGB palettes of color quantized images. J. Inf. Sci. Eng. 20(4), 771–782 (2004)

    Google Scholar 

  30. Jain, A.K., Murty, M.N., Flynn, P.J.: Data clustering: A review. ACM Comput. Surv. 31(3), 264–323 (1999)

    Article  Google Scholar 

  31. Joy, G., Xiang, Z.: Center-cut for color image quantization. Vis. Comput. 10(1), 62–66 (1993)

    Article  Google Scholar 

  32. Kanjanawanishkul, K., Uyyanonvara, B.: Novel fast color reduction algorithm for time-constrained applications. J. Vis. Commun. Image Represent. 16(3), 311–332 (2005)

    Article  Google Scholar 

  33. Kasuga, H., Yamamoto, H., Okamoto, M.: Color quantization using the fast k-means algorithm. Syst. Comput. Jpn. 31(8), 33–40 (2000)

    Article  Google Scholar 

  34. Kim, D.W., Lee, K., Lee, D.: A novel initialization scheme for the fuzzy c-means algorithm for color clustering. Pattern Recogn. Lett. 25(2), 227–237 (2004)

    Article  Google Scholar 

  35. Kuo, C.T., Cheng, S.C.: Fusion of color edge detection and color quantization for color image watermarking using principal axes analysis. Pattern Recogn. 40(12), 3691–3704 (2007)

    Article  MATH  Google Scholar 

  36. Lloyd, S.: Least squares quantization in PCM. IEEE Trans. Inf. Theory 28(2), 129–136 (1982)

    Article  MATH  MathSciNet  Google Scholar 

  37. Lo, K., Chan, Y., Yu, M.: Colour quantization by three-dimensional frequency diffusion. Pattern Recogn. Lett. 24(14), 2325–2334 (2003)

    Article  MATH  Google Scholar 

  38. Max, J.: Quantizing for minimum distortion. IRE Trans. Inf. Theory 6(1), 7–12 (1960)

    Article  MathSciNet  Google Scholar 

  39. Mojsilovic, A., Soljanin, E.: Color quantization and processing by fibonacci lattices. IEEE Trans. Image Process. 10(11), 1712–1725 (2001)

    Article  MATH  MathSciNet  Google Scholar 

  40. Orchard, M., Bouman, C.: Color quantization of images. IEEE Trans. Image Process. 39(12), 2677–2690 (1991)

    Article  Google Scholar 

  41. Ozdemir, D., Akarun, L.: Fuzzy algorithm for color quantization of images. Pattern Recogn. 35(8), 1785–1791 (2002)

    Article  Google Scholar 

  42. Papamarkos, N., Atsalakis, A., Strouthopoulos, C.: Adaptive color reduction. IEEE Trans. Syst. Man Cybern. B 32(1), 44–56 (2002)

    Article  Google Scholar 

  43. Rasti, J., Monadjemi, A., Vafaei, A.: Color reduction using a multi-stage kohonen self-organizing map with redundant features. Expert. Syst. Appl. 38(10), 13188–97 (2011)

    Google Scholar 

  44. Schaefer, G.: Intelligent approaches to colour palette design. In: Kwasnicka, H., Jain, L.C. (eds.) Innovations in Intelligent Image Analysis, Springer, Berlin, pp. 275–289 (2011)

  45. Schaefer, G., Zhou, H.: Fuzzy clustering for colour reduction in images. Telecommun. Syst. 40(1-2), 17–25 (2009)

    Article  Google Scholar 

  46. Scheunders, P.: Comparison of clustering algorithms applied to color image quantization. Pattern Recogn. Lett. 18(11–13), 1379–1384 (1997)

    Article  Google Scholar 

  47. Sertel, O., Kong, J., Catalyurek, U.V., Lozanski, G., Saltz, J.H., Gurcan, M.N.: Histopathological image analysis using model-based intermediate representations and color texture: Follicular lymphoma grading. J. Signal Process. Syst. 55(1–3), 169–183 (2009)

    Article  Google Scholar 

  48. Sherkat, N., Allen, T., Wong, S.: Use of colour for hand-filled form analysis and recognition. Pattern Anal. Appl. 8(1), 163–180 (2005)

    Article  MathSciNet  Google Scholar 

  49. Sirisathitkul, Y., Auwatanamongkol, S., Uyyanonvara, B.: Color image quantization using distances between adjacent colors along the color axis with highest color variance. Pattern Recogn. Lett. 25(9), 1025–1043 (2004)

    Article  Google Scholar 

  50. Uchiyama, T., Arbib, M.: An algorithm for competitive learning in clustering problems. Pattern Recogn. 27(10), 1415–1421 (1994)

    Article  Google Scholar 

  51. Velho, L., Gomez, J., Sobreiro, M.V.R.: Color image quantization by pairwise clustering. In: Proceedings of the 10th Brazilian Symposium on Computer Graphics and Image Processing, pp. 203–210 (1997)

  52. Verevka, O., Buchanan, J.: Local k-means algorithm for colour image quantization. In: Proceedings of the Graphics/Vision Interface Conference, pp. 128–135 (1995)

  53. Wan, S.J., Wong, S.K.M., Prusinkiewicz, P.: An algorithm for multidimensional data clustering. ACM Trans. Math. Softw. 14(2), 153–162 (1988)

    Article  Google Scholar 

  54. Wan, S.J., Prusinkiewicz, P., Wong, S.K.M.: Variance-based color image quantization for frame buffer display. Color Res. Appl. 15, 52–58 (1990)

    Article  Google Scholar 

  55. Wang, S., Cai, K., Lu, J., Liu, X., Wu, E.: Real-time coherent stylization for augmented reality. Vis. Comput. 26(6–8), 445–455 (2010)

    Article  Google Scholar 

  56. Ward, J.: Hierarchical grouping to optimize an objective function. J. Am. Stat. Assoc. 58(301), 236–244 (1963)

    Article  Google Scholar 

  57. Wen, Q., Celebi, M.E.: Hard versus Fuzzy c-means clustering for color quantization. EURASIP J. Adv. Sig. Process. 2011, 118–129 (2011)

    Article  Google Scholar 

  58. Wu, X.: Efficient statistical computations for optimal color quantization. In: Arvo, J. (ed.) Graphics Gems, vol. II, Academic Press, London, pp. 126–133 (1991)

  59. Xiang, Z.: Color image quantization by minimizing the maximum intercluster distance. ACM Trans. Graph. 16(3), 260–276 (1997)

    Article  Google Scholar 

  60. Xiang, Z.: Color quantization. In: Gonzalez, T.F. (ed.) Handbook of Approximation Algorithms and Metaheuristics. Chapman & Hall/CRC, London, pp 86-1–86-17 (2007)

  61. Xiang, Z., Joy, G.: Color image quantization by agglomerative clustering. IEEE Comput. Graph. Appl. 14(3), 44–48 (1994)

    Article  Google Scholar 

  62. Xiao, Y., Leung, C.S., Lam, P.M., Ho, T.Y.: Self-organizing map-based color palette for high-dynamic range texture compression. Neural Comput. Appl. 21(4), 639–647 (2012)

    Article  Google Scholar 

  63. Yang, C.K., Tsai, W.H.: Color image compression using quantization, thresholding, and edge detection techniques all based on the moment-preserving principle. Pattern Recogn. Lett. 19(2), 205–215 (1998)

    Article  Google Scholar 

  64. Yang, C.Y., Lin, J.C.: RWM-cut for color image quantization. Comput. Graph. 20(4), 577–588 (1996)

    Article  Google Scholar 

Download references

Acknowledgments

This publication was made possible by grants from the Louisiana Board of Regents (LEQSF2008-11-RD-A-12), US National Science Foundation (0959583, 1117457), and National Natural Science Foundation of China (61050110449, 61073120).

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to M. Emre Celebi.

Rights and permissions

Reprints and permissions

About this article

Cite this article

Celebi, M.E., Wen, Q. & Hwang, S. An effective real-time color quantization method based on divisive hierarchical clustering. J Real-Time Image Proc 10, 329–344 (2015). https://doi.org/10.1007/s11554-012-0291-4

Download citation

  • Received:

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s11554-012-0291-4

Keywords

Navigation