EZW and SPIHT Algorithms for Image Compression and Denoising
1Bhagyashree I. Kochi, 2B.B.S.Kumar
1,2ECE Dept, RRCE Bengaluru, India
Abstract — In this paper, the analysis of EZW and SPIHT
compression and denoising algorithms is implemented.
Result is examined using X-ray medical jpg image on different wavelets. The quality of image is measure by PSNR and comparison is done on compression ratio.
SPIHT based compression having better compression ratios compared to EZW for all wavelets. Denoising is calculated by adding Speckle noise for both soft and hard threshold. Thus for soft threshold Haar wavelet gives better results and for hard threshold db6 will gives the results which are better.
Keywords - EZW (Embedded Zerotree wavelet), SPIHT (Set Partitioning Hierarchical Trees), DWT (Discrete Wavelet Transform), PSNR (Peak Signal to Noise Ratio), MSE (Mean Square Error), BPP (Bits per Pixel).
I. INTRODUCTION
Compression is an application of data compression that encodes the original image with fewer bits. It also deals with techniques for reducing the redundancy of image and to store or transmit data in an efficient form.
Redundancy refers to the existence of data that is additional to actual data and transmits correction of errors in stored or transmitted data. To reduce the increasing demand of storage space and transmission time, compression techniques are the need of the day. In the specific area of still image compression, many efficient compression techniques, with considerably different features, have been developed by using discrete wavelet transform (DWT) based EZW & SPIHT.
JPEG is an Indian Standard Organization (ISO) group of experts that develops and maintains standards for suit of compression algorithms for computer image files. It is also a lossy image compression mechanism for colour images. JPEG was established by first Joint Photographic expert Group in 1992. Now a day, most of the research works in image coding have been focused mainly on the Discrete Wavelet Transform (DWT).
DWT is one of the technique to transfer the image pixels into wavelets which are later used for wavelet based compression and coding. DWT provides adaptive spatial-frequency resolution (better spatial resolution at high frequencies and better frequency resolution at low frequencies) which is mainly well suited to the properties of human visual system (HVS) particularly at higher compression ratio. Set Partitioning in Hierarchical Trees (SPIHT) which is the modified EZW wavelet coding algorithm was introduced by the scientists Sayed and Pearlman is a very efficient technique for wavelet image compression. Set partitioning in hierarchical trees (SPIHT) is a wavelet based computationally very fast and among the best
image compression based transmission algorithm that offers good compression ratios, fast execution time and good image quality.SPIHT is improved and extended version of Embedded Zero tree Wavelet (EZW).The EZW coding algorithm which was introduced by J. M.
Shapiro and is one of the best wavelet coders available to date. EZW uses “parent-child” dependencies between sub band coefficients at the same spatial location.
In this paper, we are interested to evaluate the two mentioned techniques such as EZW and SPIHT algorithms using X-ray medical jpg image. The quality of the picture is measured by Peak Signal to Noise Ratio (PSNR) and simulation results are obtained by using MATLAB tool. The obtained results are compared which gives the performance comparison of these two techniques for various compression ratios.
II. RESEARCH REVIEW
In this paper, a novel method for the adaptation of SPIHT algorithm (Set Partitioning in Hierarchical Trees)
& EZW (Embedded Zerotree Wavelet) to the gray images is proposed by using different wavelets.
The SPIHT process was mainly based on the wavelet transform. Set Partitioning in Hierarchical Trees (SPIHT) algorithm is based on embedded zero tree wavelet (EZW) coding method which employs spatial orientation trees and uses set partitioning sorting algorithm. The Coefficients corresponding to the same spatial location in different sub bands in the pyramid structure display self-similarity characteristics. SPIHT defines parent children relationships between these self- similar sub bands to establish spatial orientation trees.
Amongst the techniques of compression using the wavelet transform proposed in the literature, the coding method called EZW which was introduced by the scientist J.Shapiro. This technique gives the dual benefit of being very effective and enormously quick. EZW is a universal lossless data compression method which is achieved via adaptive arithmetic coding. An EZW encoder is an encoder especially designed to use with wavelet transforms, that explains why it has the word wavelet in its name. The EZW encoder was originally designed to operate on images (2D-signals) but it can also be used on other dimensional signals. The EZW encoder was mainly based on progressive encoding to compress an image into a bit stream with increasing accuracy. Thus, Shapiro predicts why in a hierarchical system in sub-bands, each coefficient at a given scale, was connected to a set of coefficients being on a subsequent finer scale and defines a tree structure precise by its "parent-child" relationship.
An enhancement of the EZW algorithm, recognized as SPIHT algorithm was proposed by Sayed and Pearlman.
This improved version, using a different tree structure, processes all the non significant descendants of a wavelet coefficient like a set and uses only one symbol to represent it. Considering the efficiency and the performances brought by the SPIHT algorithm on images at the point of gray.
III. COMPRESSION PERFORMANCE
Compression is mainly achieved by different compression performance parameters such as, compression ratio (CR), Peak Signal to Noise Ratio (PSNR), Mean Square Error (MSE) and the Bit-Per- Pixel (BPP) ratio. The compression ratio CR refers that the compressed image is stored using only CR% of the initial storage size.
The Bit-Per-Pixel ratio (BPP) gives the number of bits used to store one pixel of the image and refers to the sum of bits in all the three colour channels and represents the total colour available at the each pixel.
For a gray scale image, the initial BPP is 8 while for a true colour image the initial BPP is 24 because 8 bits are used to encode each of the three colours (RGB colour space).
The dispute of compression method is to locate the best negotiation between a weak compression ratio and a good perceptual result.
A. CR
CR= (Original image File size)/ (compressed Image File size) As the compression ratio increases, reconstructed image is more compressed and the quality of image will be degrades.
B. PSNR
The Peak Signal to Noise Ratio (PSNR) represents a measure of the peak error and is expressed in terms of decibels. It is represented as:
PSNR = 10 log102552/MSE
As the PSNR value increases, the quality of compressed or reconstructed image is better.
C. MSE
The Mean Square Error (MSE) represents the mean squared error between the compressed and the original image and is given by:
MSE = ∑M,N [I1(m,n)- I2(m,n)]2/M*N
The lower value of MSE will result in lower the errors.
IV. WAVELETS
The wavelet is a wavelike oscillation with amplitude which begins at zero then increases and later decreases back to zero. It is a mathematical function useful in digital signal processing and image compression.The fundamental idea behind wavelets is to analyze the
signal at different scales or resolutions, which is called multiresolution. The most important feature of wavelet transform is it allows multiresolution decomposition. An image that is decomposed by wavelet transform can be reconstructed with desired resolution. The procedure for this is a low pass filter and a high pass filter is chosen, such that they exactly halve the frequency range between themselves and this filter pair is called the Analysis Filter pair. The Multiresolution concept of wavelet allows us to understand an image as a sum of details that appear at different resolutions. Although wavelet theory was first introduced as a mathematical tool in the mid-1980s, it has been widely used in image processing, especially in compression. The study of wavelet analysis begins with a mathematical function which is called “Mother Wavelet” or “Wavelet Kernel.”
In Fourier analysis a signal is breaking into sine waves of different frequencies. But in case of wavelet analysis the signal is breaking into scaled and translated (shifted) versions of the selected mother wavelet.
The Wavelets are useful for compressing signals but they also have far more extensive uses. They can be used to process and improve signals, in fields such as medical imaging where image degradation is not tolerated they are of particulars, used in pattern recognition and edge detection.
The different properties of Discrete Wavelet Transform (DWT) are scalability, translatability, multi resolution compatibility and orthogonality. Discrete Wavelet Transform (DWT) decomposes a signal into a set of mutually orthogonal wavelet basis functions. These functions differ from sinusoidal basis functions in that they are spatially localized that is, nonzero over only part of the total signal length.Wavelet provides better resolution where resolution refers to the number of pixels in an image for pre processing and post processing technique. It also provides enough information both for analysis and synthesis and reduces the computation time sufficiently, easier to implement analyzing the signal at different frequency bands with different resolutions.
V. EXPERIMENTAL RESULTS
A. EZW & SPIHT
Fig.1. Original boneleg gray scale image 256x256.
Fig.2. Haar a) EZW b) SPIHT
Fig.3. db6 a) EZW b) SPIHT
Fig.4. sym4 a) EZW b) SPIHT Table 1. EZW Compression Ratio (CR) Wavelet
Name
Parameters (EZW)
CR% BPP PSNR MSE Haar 14.98 1.20 41.5016 4.6017 Daubechies
(db6)
13.58 1.09 42.6663 3.5192 Symlets(sym4) 12.99 1.04 42.7705 3.4358
Table 2. SPIHT Compression Ratio (CR) Wavelet
Name
Parameters (SPIHT) CR% BPP PSNR MSE Haar 9.90 0.79 40.3810 5.9864 Daubechies
(db6)
8.33 0.67 41.3407 4.7754 Symlets(sym4) 8.10 0.65 41.4828 4.6217 The compression ratio provides image clarity of different formats, in this paper we have identified the different of image retrieved by using the algorithms such as EZW and SPIHT. Both provide better compression ratio and bit per pixel of an image which have been Examined on different wavelets such as Haar, Daubechies(db6), and Symlets(sym4) using both algorithms. In the medical images compression requires no loss of data for processing to achieve especially in terms of clarity. The research work has been carried out by using X-ray medical jpg image.
The experiments has been carried out on matlab simulation for both algorithms to find out good Compression Ratio (CR) and observed the quality of image by PSNR & MSE. Fig.1 As shown from the Fig.2 to 4 are both EZW and SHIPT using different wavelets.
Image retrieving in both cases is good but varies for parameters as shown in the Table 1 & 2.
EZW having reasonable compression ratio from Table1, the Haar wavelet having higher compression percentage but image degrading is more and bit per pixel, MSE is higher and PSNR is lower hence image quality is reasonable in retrieving. The Symlets had given less CR than other wavelets and higher PSNR value with lower MSE gives the better results.
SPIHT is a modified EZW coding technique which provides better and efficient image compression ratio and minimizing the loss of data. From the Table 2, for all the wavelets CR is improved and image clarity is good. The Symlets wavelet is having better compression ratio than all the wavelet and also having a good image retrieving than all the wavelets of higher PSNR and lower MSE value.
B.DWT
Fig.5. 2-D DWT Decomposition: a) Original image, b) One level decomposition, c) Two levels decomposition,
d) Three levels decomposition
Fig.6. 2-D DWT Decomposition Level-1
Fig.7. 2-D DWT Decomposition Level-2
Fig.8 .Haar a) CR b) Residuals
Fig.9 .db6 a) CR b) Residuals
Fig.10.sym4 a) CR b) Residuals
Table 3. Wavelets Compression Wavelet
Name
Parameters
Retained Energy% Number of Zeros
Haar 99.99 78.91
Daubechies (db6)
99.99 81.30
Symlets (sym4)
99.99 82.09
Wavelets having more advantage than the Fourier transforms, where we can represent image in the spatial domain, multi-resolutions and energy retaining and compatibility. In this paper result is tested by using algorithms EZW & SPIHT and using wavelets image processing. From the images Fig.8 to 10 shown images retrieving is good, but differs in energy retaining and number of zeros with observations of residuals.
The discrete wavelet transform is a filter bank with number of decomposition level1, 2, 3 and so on, as shown in the Fig.5. During the wavelet decomposition the image is divided into four distinct bands they are Low-Low (approximation), Low-High (vertical), High- Low (horizontal) and High-High (diagonal). Out of these sub bands only Low-Low sub band is processed further since if consists of low frequency and the maximum data is in the LL band. In this paper work is carried at global thresholding and two dimension (2-D) decomposition level. As shown in the Table.3 for all the wavelet is having good energy retaining percentage and number of zeros.
C. SOFT THRESHOLD FOR SPECKLE NOISE
Fig.11. Haar i) Noisy Image ii) Denoised Image
Fig.12. db6 i) Noisy Image ii) Denoised Image
Fig.13. sym4 i) Noisy Image ii) Denoised Image Table.4. Results Obtained for Speckle Noise in Soft Wavelet Name Parameters (Speckle Noise)
PSNR MSE
Haar 38.04 10.19
Daubechies (db6) 37.99 10.32
Symlets (sym4) 37.98 10.35
Thresholding
From Fig.11 to Fig.13 it shows the results obtained for different wavelets such as, Haar, db6 and sym4 for Soft thresholding. Thus when we add Speckle noise by using soft thresholding method Haar wavelet gives high PSNR value of 38.04 and MSE of 10.19. Therefore compare to all the wavelet, Haar wavelet gives high PSNR value and low MSE hence the quality of image is good and gives low error hence Haar gives better results compare to all wavelets.
C. HARD THRESHOLD FOR SPECKLE NOISE
Fig.14. Haar i) Noisy Image ii) Denoised Image
Fig.15. db6 i) Noisy Image ii) Denoised Image
Fig.16. sym4 i) Noisy Image ii) Denoised Image
Table.5. Results Obtained for Speckle Noise in Hard Thresholding
Wavelet Name Parameters (Speckle Noise)
PSNR MSE
Haar 47.53 1.14
Daubechies (db6) 47.57 1.13
Symlets (sym4) 47.27 1.21
From Fig.14 to Fig.16 it shows the results obtained for different wavelets such as, Haar, db6 and sym4 for hard thresholding. Thus when we add Speckle noise by using hard thresholding method, db6 wavelet gives high PSNR value of 47.57 and MSE of 10.13. Therefore compare to all the wavelet, db6 wavelet gives high PSNR value and low MSE hence the quality of image is good and gives low error hence db6 gives better results compare to all wavelets.
VI. CONCLUSION
In the medical image processing data retrieving is very significant. The percentage of loss of data provides improper diagnosing the patient. In this paper work is examined for algorithms EZW & SPIHT and different wavelets. It is found that EZW having reasonable CR percentage and moderate PSNR & MSE value. But SPIHT gives better CR percentage, BPP, PSNR and MSE value without using EZW & SPIHT algorithms the wavelets attains the good energy retaining and number of zeros reasonable higher compression. The SHIPT provides better compression ratios and higher retrieving images at less minimizing the percentage of loss of data.
Similarly for soft threshold when we add speckle noise Haar gives better results, and for Hard threshold db6 gives better results.
REFERENCES
[1] LiBin and Meng Qinggang, “An Improved SPIRT Wavelet Transform in the Underwater Acoustic Image Compression”, 2nd International Conference on Measurement, Information and Control, IEEE, Harbin, China, page 1315-1318, 2013.
[2] Tobias Lindstrom Jensen, Jan Ostergaard, Joachim Dahl, and Soren Holdt Jensen, “Multiple Description l1-Compression”, IEEE Transactions on Signal Processing, VOL. 59, NO. 8, August 2011.
[3] Bhawna Rani, R K Bansal and Dr Savina Bansal,
“Comparison of JPEG and SPIHT Image Compression Algorithms using Objective Quality Measures”, IMPACT, IEEE, page no.90-93, 2009.
[4] F. Khelifi, N. Doghmane and T.Bouden,
“Compression Of The Color Images By SPIHT Technique”, IEEE, page no.365-366, 2004.
[5] Sanjay H. Dabhole, Virajit A. Gundale and Johan Potgieter, “Performance Evaluation of traditional and Adaptive Lifting based Wavelets with SPIHT
for Lossy Image Compression”, International Conference on Signal Processing, Image Processing and Pattern Recognition [ICSIPRI], IEEE, page no.1-5, 2013.
[6] Ahmed Ahu-Hajar and Ravi Sankar, “Enhanced Partial-SPIHT for Lossless and Lossy Image Compression”, ICASSP, IEEE, page no.253-256, 2003.
[7] Frederick W. Wheeler arid William A. Pearlman,
“SPIHT Image Compression without Lists”, IEEE, page no.2047-2050, 2000.
[8] Yen-Yu Chen and Shen-Chuan Tai, “Embedded Medical Image Compression Using DCT Based Sub band Decomposition and Modified SPIHT Data Organization”, Proceedings of the Fourth IEEE Symposium on Bioinformatics and Bioengineering (BIBE’04), IEEE Computer Society, page no. 1-8, 2004.
[9] Mridula Purohit and Nitesh Kumar, “Analysis of Fingerprint Compression using SPIHT Technique for Significant Threshold Level”, International Journal of Advanced Research in Computer Science and Software Engineering, Volume 4, Issue 3, March 2014
[10] B.B.S.Kumar, Dr.P.S.Satyanarayana & Rohini G.V, “Brain Tumor Image Edge & Watershed
Segmentation and Denoising Using DWT”, International Journal of Scientific & Engineering Research (IJSER), ISSN 2229-5518, Volume 5, Issue 11, page no.612-620, (November-2014).
[11] B.B.S.Kumar, & Dr.P.S.Satyanarayana and Shivakumaraiah, “Image Compression and De- noising using Discrete Meyer Wavelet Technique”, International Journal of Ethics in Engineering & Management Education (IJEEE), ISSN: 2348-4748, Vol-1, Issue-7, (July 2014).
[12] B. B. S. Kumar & Dr. P. S. Satyanarayana,
“Compression and Denoising Analysis from Still Images Using Symlets Wavelet Technique”, International Journal of Applied Research and Studies (iJARS), ISSN: 2278-9480, Volume 2, Issue 8, (Aug – 2013).
[13] B.B.S. Kumar & Dr. P. S. Satyanarayana, “Image Analysis Using Biorthogonal Wavelet”, International Journal of Innovative Research &
Development (IJIRD), ISSN: 2278 – 0211, Volume 2, Issue 6, (June 2013).
[14] B.B.S Kumar & P.S Satyanarayana
“Compression and de-noising – Comparative analysis from still image using Wavelet Techniques”, ISSN (PRINT): 2320 – 8945, Vol.
1, Issue -6, (2013).