LETTERS International Journal of Recent Trends in Engineering, Vol 2, No. 2, November 2009
A Neural Network Approach for Color Image Compression in Transform Domain S. Immanuel Alex Pandian1, J.Anitha2 1
Dept. of Electronics & Communication Engg., Karunya University Coimbatore 2 Dept. of Computer Science & Engg Karunya University Coimbatore. Email:
[email protected],
[email protected] .
Abstract - This paper presents a novel technique for color image compression in the transform domain. For compression of images vector quantization (VQ) technique is used and the codebook in VQ is designed using Kohonen’s Self Organizing Feature Maps (SOFM). This work exploits the special features of SOFM for generic codebook generation that enables to construct the codebook only once. Apart from spatial quantizers, we implemented the generic codebook approach in transform domains such as DCT and DWT. The performance of decompression is observed by using image quality measures such as PSNR, Structural Content, Image Fidelity and Mean Structural Similarity Index of the images on HSV color space. This scheme produces the reconstructed image of good quality and achieves better compression ratio at low bit rates. Index Terms – VQ, generic codebook, color image compression, SOFM, quality measures
I. INTRODUCTION In a digital true- color images, each color component is quantized with 8 bits, and so a color is specified with 24 bits. As a result, there are 224 possible colors for the image. Furthermore, a color image usually contains a lot of data redundancy and requires a large amount of storage space. In order to lower the transmission and storage cost, image compression is desired [1], [11]. Most color images are recorded in RGB model, however, it is not suited for image processing purpose. In this paper, we propose a scheme for designing a transform vector quantizer for color image compression using Kohonen’s SOFM. The compression of color images is performed by converting color images from RGB to HSV color space. We use a set of training images to design a generic codebook that is used for encoding the training as well as other images. The set of code indices produced by the encoder is further compressed using Huffman coding. The qualitative analysis of decompressed images by applying various quality measures is also presented. II. VECTOR QUANTIZER DESIGN USING SELF ORGANIZING FEATURE MAPS Vector quantization [2], [3], is one of the well known image compression techniques and can be defined as a mapping work from a k-dimensional Euclidean space Rk with plenty of uncertain pattern type vj into a finite subset CB of
Rk. Here CB= {ci; i=1, 2…M} is called the VQ codebook with size M. The key to VQ data compression on a good quality of reconstructed image is to generate a excellent representative codebook from an abundant vector set of image. For VQ of color images, three codebooks are needed to be designed for three color spaces [7]. Self-organizing feature maps (SOFM) a special class of artificial neural networks based on competitive learning. This was developed by T.Kohonen [5], [6]. SOFM learn to classify input vectors according to how they are grouped (pattern) in the input space. III. TRANSFORM CODING Images can be encoded by finding out, for each image vector, the code vector with the least Euclidean distance. However, all spatial vector quantizers produce some blockiness in the reconstructed image [3], i.e. the boundaries of the blocks become visible. Even though the reconstructed image shows quite good PSNR, this effect often has some adverse psychovisual impact. Often, transform and/or subband coding is used to overcome this effect. The goal of the transformation process is to decorrelate the pixels of each sub image, or to pack much information as possible into the smallest number of transform coefficients. Hence the raw image has to be transformed into frequency domain before encoding using the quantizer, and, also in decoder, the image has to be converted back into the spatial domain from the frequency domain. In our method, we have experimented both DCT [9] and DWT [8] transformation. IV. DESIGN OF GENERIC CODEBOOK Keith R.L.Godfrey [10], in their paper described the use of SOFM for codebook generation of color images. In our experimentation we have trained the SOFM network with selective training approach, which gives better performance in saturation levels of color. The similar idea is presented by Laha et.al [4], but our one is enhanced and extended to color images. The construction of generic codebook can be used to encode any image with acceptable fidelity. Such a codebook allows us one time construction of the encoder-decoder and making the codebook a permanent part of it. To achieve this, we select a set of images having widely varied natures in terms of details, contrasts, and textures.
152
© 2009 ACADEMY PUBLISHER
LETTERS International Journal of Recent Trends in Engineering, Vol 2, No. 2, November 2009 V. QUANTITATIVE ASSESSMENTS USED FOR EVALUATION OF DECOMPRESSED IMAGE Ismail Avibas et.al [12], Ahmet M. Eskicioglu et.al [13] has presented many quality measures. X(j,k) denote the original image and X^(j,k) denotes the reconstructed image. MxN are pixels in rows and columns respectively. The quality measures are described in the Table 1. In Mean Structural Similarity Index µ and σ are mean and variance respectively. The MSSIM is calculated by taking mean of SSIM and UQI is calculated by substituting C1 and C2=0. The quality analysis is also done using pshycovisual parameter like mean opinion score (MOS). This is because many times irrespective of good quality image, PSNR and others do not give correct values. TABLE 1. QUALITY MEASURES Peak Signal to Noise Ratio (PSNR)
10 log M
255 * 255 dB MSE
N
M
N
∑ ∑ X ( j, k ) / ∑ ∑ X ^ ( j, k )
Structural Content (SC)
2
j =1 k = 1 M
2
j = 1 k =1
N
∑ ∑ [ X ( j, k ) X ^ ( j, k )
2
]
j =1 k =1
Image Fidelity (IF)
M
N
∑ ∑ [ X ( j, k )
2
]
c) DCT based VQ
d) DWT based VQ
Figure 1. Results on 256x256 Lena image.
The algorithm is also implemented in DWT transform domain using db4 with level 3. The performance of the vector quantizers in DWT domain is summarized in Table 3. The main features to consider in the compression algorithm are compression ratio and quality of the reconstructed image. Depending upon the nature of the application, the algorithm is implemented in spatial or transform domain. The preservation of psychovisual quality for the reconstructed image is obtained in both spatial and transform domain. However, better compression ratio is attained by applying SOFM in transform domain. With reference to the table and the graphical chart in Fig. 2 it is found that, compression of color image using DWT gives better compression ratio with comparable visual quality.
j =1 k =1
Structural Similarity Index (SSIM)
M
N
M
N
∑ ∑ [ X ( j , k ) X ^ ( j , k )] / ∑ ∑ [ X ( j , k ) j =1 k =1
2
22
]
j =1 k =1
(2 µ x µ ( µ x2 + µ
2 y
y
+ C 1 )( 2 σ
+ C 2 )( σ
2 x
xy
20
File Size (KB)
Normalized Correlation Quality (NK)
+ C2)
+σ
2 y
+ C2)
VI. EXPERIMENTAL RESULTS
18 16
Brain
14
Lena
12 10
The performance of the vector quantizers for training and testing color images for the proposed method are summarized in Table 2. The image compressed using the DCT transform provides better compression rate with good PSNR values. To compare the psychovisual qualities, we display in Fig.1 the Lena image compressed using spatial vector quantization and transformed vector quantization.
8 Spatial
DCT
DWT
Figure 2. Graphical comparison of compressed file size in spatial and transform domain.
VII. CONCLUSION The successful application of this compression scheme for designing VQ for color image compression using generic codebooks produce reconstructed image with good psychovisual quality. The image compressed using the DCT transform provides better compression rate with good PSNR values. In conclusion, the conversion to HSV space happens to be beneficial for getting better quality decompressed image. Thus the proposed scheme, achieves compression at low bit rates with good quality reconstructed images.
a) Original Image
© 2009 ACADEMY PUBLISHER
b) Spatial VQ
153
LETTERS International Journal of Recent Trends in Engineering, Vol 2, No. 2, November 2009 TABLE 2. PERFORMANCE COMPARISON OF SPATIAL VQ WITH DCT BASED VQ, CODEBOOK 1K X 3
Images Peppers Mandrill Lena Fabric Bubbles
Domain
PSNR
Spatial DCT Spatial DCT Spatial DCT Spatial DCT Spatial DCT
CR
SC
NK
MSSIM
10.11:1
0.9906
1.0096
0.9990
0.999
0.435
29.16
10.11:1
0.9928
1.0077
0.9983
0.999
0.420
31.47
9.85:1
1.0013
0.9987
0.9980
0.999
0.475
31.52
9.79:1
1.0022
0.9978
0.9976
0.999
0.470
36.16
10.05:1
1.0028
0.9973
0.9978
0.999
0.503
36.05
10.05:1
1.0027
0.9973
0.9978
0.999
0.501
28.75
9.64:1
0.9973
1.0027
0.9974
0.999
0.335
28.95
9.6:1
0.9982
1.0019
0.9972
1
0.302
33.03
9.69:1
1.0007
0.9993
0.9992
1
0.466
33.02
9.69:1
1.0005
0.9995
0.9993
1
0.432
Images
PSNR
CR
SC
IF
NK
Peppers
19.614
20.73:1
0.911
1.12
1.01
Mandrill
23.63
20.93:1
0.998
0.99
0.99
Lena
28.73
21.38:1
1.009
0.99
0.99
Fabric
21.11
20.23:1
0.961
1.04
1.01
Bubbles
24.94
20.57:1
1.010
0.99
0.99
Brain
25.74
21.02:1
1.021
0.97
0.99
House
28.91
21.33:1
1.002
0.99
0.99
REFERENCES [1]. S. J. Sangwine and R.E.Horne, “The Colour Image Processing Handbook”, Chapman & Hall, 1st Ed., 1998. [2]. R. M. Gray, “Vector quantization,” IEEE ASSP Magazine, vol. 1, pp. 4– 29, 1984. [3]. N. M. Nasrabadi and R. A. King, “Image coding using vector quantization: A review,”IEEE Trans. Communications, vol. 36, no. 8, pp. 957–971, August 1988. [4]. A. Laha, N.R. Pal, and B. Chanda, “Design of Vector Quantizer for image compression using Self Organizing Feature
Map and Surface Fitting” IEEE Trans. On Image processing .Vol 13, pp 1291-1302, Oct 2004. [5]. T.Kohonen “The Self Organizing Maps “Invited Paper, Proceedings of IEEE, Vol 78, No 9 pp 1464- 1480, 1990. [6]. T. Kohonen,” Self-Organization and Associative Memory”. New York: Springer-Verlag, 2nd ed, 1988. [7]. Yogesh Dandawate,M.A.Joshi and A.V.Chitre “ Color Image Compression using Enhanced Vector Quantizer designed with Self Organizing feature maps”, The Proceedings of International Conference on Information Processing, Banglore (India) pp 80-85, August 2007. [8]. M. Antonini, M. Barlaud, P. Mathieu, and I. Daubechies, “Image coding using wavelet transformation,” IEEE Transactions on Image Processing, vol. 1, no. 2, pp. 205-220, April 1992. [9]. Subhasis Saha, “Image compression – from DCT to Wavelets: A Review,” www.acm.org/crossroads/xrds63/sahaimgcoding.html. [10]. Keith R. L. Godfrey and Yiannis Attikiouzel “Applying Neural Networks to Color Image Data Compression” IEEE Region 10 Conference. Tencon 92, Melbourne. Australia, November, 1992. [11]. Rafael C. Gonzalez, Richard E.Woods, “Digital Image Processing”, 2nd Ed., Pearson Asia., 2005. [12]. Ismail Avicibas, Bulent Sankur, Khalid Sayood “Statistical Evaluation of Image Quality Measures” Journal of Electronic Imaging 11(2), pp. 206-223, April 2002. [13]. Ahmet M. Eskicioglu and Paul S. Fisher “Image Quality Measures and their performance “IEEE Transactions on Communications, Vol, 43, No.12, December 1995.
b) MOS 9.2(Spatial)
c) MOS 9.5(DCT)
d) MOS 8.6(DWT)
Figure 3. MOS values for spatial and transform domain color image compression.
154 © 2009 ACADEMY PUBLISHER
UQI
28.98
TABLE 3. PERFORMANCE OF DWT BASED VQ, CODEBOOK 1K X 3
a) Bubbles
IF