Lossy Image Compression Using PCA and Contourlet Transform

. With the rapid development of Internet, image information is growing. It requires a lot of image storage and transmission. In order to reduce the storage and get better image quality, image compression algorithm is studied. The paper proposes a new image compression algorithm that combines principal component analysis (PCA) and Contourlet Transform (CT). Because PCA has good image quality, but the compression ratio is low, and CT compression algorithm has high compression ratio and good PNSR value. The image is decomposed by PCA. The image data is divided into blocks, and each block is used as a sample vector, then select covariance matrix of k larger eigenvalues corresponding eigenvector to realize image compression. Then the image is compressed again using CT compression algorithm. Compared with the results of JEPG2000 and CT compression algorithm, the results show that the proposed algorithm has better performance than JEPG2000 and CT compression algorithm. In the same compression ratio, PNSR value of proposed algorithm is about 3dB higher than that of JEPG2000, and 2dB higher than that of CT compression algorithm.


Introduction
With the rapid development of Internet, image information is growing.It requires a lot of image storage and transmission [1].The amount of information in the digital image is very large, and it occupies a large amount of resources.So it is important to use appropriate method to compress the image in order to store and transmit.Image compression is divided into lossless compression and lossy compression [2][3].Principal component analysis algorithm is a kind of feature vector based lossy compression algorithm, which has many applications in image compression and digital watermarking [4][5][6][7][8].Principal component analysis converts the data set into a low dimensional feature space, and retains most of the original data information content [9].Contourlet transform are used in the image denoising [10], image fusion [11] and image enhancement [12], and the effect is good.CT compression algorithm is to make full use of contourlet transform to decompose the image with multiscale and multidirection [13], despite contourlet transform can produce 4 / 3 redundancy, but the use of hard threshold of coefficients processing and run length coding with redundancy is eliminated and realize image compression [14].JPEG2000 is a new generation of still image compression standard, it uses the wavelet transform, the optimized truncation embedded block encoding and efficient code stream organization form [15][16].In this paper, a new image compression algorithm is proposed, which combines PCA and contourlet transform.CT compression algorithm is to first convert by contourlet transform, using hard threshold for contourlet transform coefficients, treatment with run length coding for image compression.Because PCA has good image quality, but the compression ratio is low, and CT compression algorithm has high compression ratio and good PNSR value.The proposed algorithm has been tested in the famous images such as airfield, Lena, etc., and has been compared with JEPG2000 and CT compression algorithm.

Image compression based on principal component analysis and Contourlet transform 2.1 Principal component analysis of image compression
Principal component analysis is a kind of exploratory statistical analysis method, which will be distributed on a set of variables to focus on a few principal components.Principal component analysis is a kind of non-supervised method, because it does not need to output information.
Assume a sample set X, contains m samples, the dimension of each sample is n, The sample set X is organized into a sample matrix, each row of which is a sample, and each column is a dimension, S is m n matrix.

¦
The sample matrix of is denoted as u , then the covariance matrix of S is C, which is known by the formula (1).

¦
According to matrix theory, we know that there exists an orthogonal matrix P, P T CP=A.For the specific operation of the orthogonal matrix P: The C eigenvalue decomposition, get the eigenvalue matrix as a feature vector, and the orthogonal matrix is denoted as P. Obviously, P, A R n*n .To take the maximum of the former K eigenvalues, then the K feature values of the A 1 feature vectors are composed of new feature vector matrix, which is the principal component of PCA transform.Because of P 1 T CP 1 =A 1 , it can be obtained Then , the formula (4) deformation is PCA is used to image compression and block image data, each block as a sample vector, and then calculate corresponding feature vector based on the k eigenvalues of covariance matrix C, which is main component of PCA, and give up the corresponding feature vector of the smaller n-k eigenvalues, which constitute the transformation matrix P 1 .The center of the sample matrix after transformation to get S 1 , the compression ratio is n:k , The formula (6) can reconstruct the original image, and the mean square error is equal to the sum of n-k eigenvalues.

Contourlet transform of image compression
Contourlet Transform is the use of Laplacian pyramid decomposition(LP)and directional filter banks(DBF) to achieve a multiresolution, local and multi direction image representation method.Firstly, the image is decomposed by using LP to capture the singular points, and then the DFB is used to connect the singular points of the similar direction.LP is a low pass filter for the original image, and then the low frequency image is sampled and filtered, The difference between the original image and the predicted image is Laplasse's decomposition.The low pass image continues to carry on the Laplasse decomposition, and finally completes the multi scale decomposition of the image.In the reconstruction, the low pass image is sampled and filtered with a band-pass image to complete the reconstruction, the transformation process is performed on the low frequency image, and the image is reconstructed.After the image is decomposed by Laplasse, the singular points of the close direction of the image are connected to the linear structure, so that the image can be decomposed by using a binary tree decomposition.The band pass image is divided into 2 L wedge frequency sub band.The wedge frequency spectrum is obtained by using the combination of Quincunx Bank and DFB.
Because of the structure of the contourlet transformation, the support set is the "long form" structure which is transformed with the scale, so that the image can be decomposed completely.Image Peppers can be carried out by contourlet transform.

Figure 1. Block diagram of the proposed image compression algorithm
Secondly, Contourlet transform has a large number of coefficients, which represent the direction information and texture information.Large coefficients contain more information, more important than small coefficients.With the decomposition of the scale, the Contourlet coefficient decays rapidly.By the decomposition, the fine scale contains a large number of small coefficients, these small coefficients around 0 floating.This paper uses a simple hard threshold processing to remove the small coefficient of the decomposition.While retaining the high frequency sub bands in the larger coefficient, so that the image quality can be guaranteed for the follow-up of the compression process.As shown below: threshold, the greater the β, the greater the compression ratio.
Finally, using the run-length coding of quantitative coefficients are encoded.

Algorithm of image compression
In order to ensure the compression quality and improve the compression ratio, this paper combines PCA and Contourlet transform, and the image is compressed by two levels.Specific algorithms are shown in figure 1.
The image data is divided into blocks, and each block is used as a sample vector, then select covariance matrix of k larger eigenvalues corresponding eigenvector to realize the first-stage compression of the image.Reconstruction of image uses contourlet transform.Contourlet transform coefficients are hard threshold processing.To achieve image compression using run length encoding in entropy coding.
Reconstruction of image data based on PCA and contourlet transform.Run length decoding of compressed results are run in contourlet inverse transformation.The image is reconstructed.

Experiments and discussions
In order to verify the effectiveness of the proposed method, 5 images of the compression experiments were carried out.All images are 512*512 gray-scale images.According to the literature, contourlet transform using '9-7' pyramid decomposition and 'pkva' direction filter 3 layer decomposition, several layers direction is [1,2,3].By changing the contribution of the singular value of the image signal and the contourlet coefficient quantization threshold, the reconstructed images are obtained under different compression ratios, and the PNSR and SSIM are calculated.1, Table 2 and Table 3, it can be found that the proposed algorithm is the best one of the three algorithms.(a) (c) Figure 2 shows that the PNSR value of the proposed algorithm is higher than the other algorithms, when the compression ratio become more higher, the proposed algorithm is better than the other two algorithms.
Figure 3 shows that image Goldhill is compressed by three methods in the compression ratio of 40:1.Overall, quantitative and qualitative results show that the proposed algorithm has better image quality and compression ratio.Because of the large eigenvectors contribution to the image signal, PCA has good image quality, so it can be combined with CT compression algorithm to improve the image quality and SSIM value in the same compression ratio.

(b) (d)
Contourlet transform are effectively combined.The compression ratio of proposed algorithm is the product of the compression ratio of PCA and the compression ratio of CT compression algorithm.The result of proposed algorithm is obviously better than JEPG2000 and CT compression algorithm, which has a certain application prospect.
y) indicates that the coefficients are processed by threshold, f(x, y) represents the change coefficient before processing, β represents setting the

Table 1
shows the comparison PNSR value of the proposed algorithm, JEPG2000 and CT compression algorithm in the 20:1 compression ratio.And the Table2and Table3respectively present the PNSR values which the compression ratios are 40:1 and 80:1.According to the Table