JPEG2000: Wavelets in Image Compression
Total Page:16
File Type:pdf, Size:1020Kb
EE678 WAVELETS APPLICATION ASSIGNMENT 1 JPEG2000: Wavelets In Image Compression Group Members: Qutubuddin Saifee [email protected] 01d07009 Ankur Gupta [email protected] 01d070013 Nishant Singh [email protected] 01d07019 Abstract During the past decade, with the birth of wavelet theory and multiresolution analysis, image processing techniques based on wavelet transform have been extensively studied and tremendously improved. JPEG 2000 uses wavelet transform and provides an integrated toolbox to better address increasing needs for compression. In this report, we study the basic concepts of JPEG2000, the LeGall 5/3 and Daubechies 9/7 wavelets used in it and finally Embedded zerotree wavelet coding and Set Partitioning in Hierarchical Trees. Index Terms Wavelets, JPEG2000, Image Compression, LeGall, Daubechies, EZW, SPIHT. I. INTRODUCTION I NCE the mid 1980s, members from both the International Telecommunications Union (ITU) and the International SOrganization for Standardization (ISO) have been working together to establish a joint international standard for the compression of grayscale and color still images. This effort has been known as JPEG, the Joint Photographic Experts Group. The process was such that, after evaluating a number of coding schemes, the JPEG members selected a discrete cosine transform( DCT)-based method in 1988. From 1988 to 1990, the JPEG group continued its work by simulating, testing and documenting the algorithm. JPEG became Draft International Standard (DIS) in 1991 and International Standard (IS) in 1992. With the continual expansion of multimedia and Internet applications, the needs and requirements of the technologies used grew and evolved. In March 1997, a new call for contributions was launched for the development of a new standard for the compression of still images, the JPEG2000 standard. JPEG2000 standard makes use to Discrete Wavelet Transformation (DWT) with the block diagram as shown in fig. 1. Fig. 1. Block diagram for JPEG2000 Prior to the transformation, some sort of preprocessing is required which includes image tiling, DC level shifting and component transformation. Tiling refers to the partitioning of the original image into rectangular nonoverlap- ping blocks called tiles, which are compressed independently, as though they were entirely distinct images. Wavelet transform, quantization and entropy coding are performed independently on the image tiles. Tiling reduces memory EE678 Wavelets Application Assignment, March 2005 EE678 WAVELETS APPLICATION ASSIGNMENT 2 requirements, and since they are also reconstructed independently, they can be used for decoding specific parts of the image instead of the whole image. Also, Larger tiles perform visually better than smaller tiles. DC level shifting refer to the shifting of all samples of the image tile component by subtracting the same quantity 2P −1, 1, where P is the components precision. Level shifting does not affect variances. It actually converts an unsigned representation to a twos complement representation, or vice versa. If color transformation is used, dc level shifting is performed prior to the computation of the forforward component transform. At the decoder side, inverse dc level shifting is performed on reconstructed samples by adding to them the bias 2P −1 after the computation of the inverse component transform. The forward transform block is where the wavelet transform takes place. Wavelet transform is used for the anal- ysis of the tile components into different decomposition levels. To perform the forward DWT the standard uses a onedimensional (1-D) subband decomposition of a 1-D set of samples into low-pass and high-pass samples. Low- pass samples represent a down-sampled, low-resolution version of the original set. High-pass samples represent a downsampled residual version of the original set, needed for the perfect reconstruction of the original set from the low- pass set. TheDWTcan be irreversible or reversible. The default irreversible transform is implemented by means of the Daubechies 9-tap/7-tap filter. The default reversible transformation is implemented by means of the Le Gall 5-tap/3-tap filter. The standard can support two filtering modes: convolution based and lifting based. Convolution-based filtering consists in performing a series of dot products between the two filter masks and the extended 1-D signal. Lifting-based filtering consists of a sequence of very simple filtering operations for which alternately odd sample values of the signal are updated with a weighted sum of even sample values, and even sample values are updated with a weighted sum of odd sample values. After transformation, all coefficients are quantized. Quantization is the process by which the coefficients are reduced in precision. This operation is lossy, unless the quantization step is 1 and the coefficients are integers, as produced by the reversible integer 5/3 wavelet. Each of the transform coefficientsa ab(u, v) of the subband b is quantized to the value qb(u, v) according to the formula |ab(u, v)| qb(u, v) = sign(ab(u, v)) (1) ∆b Finally, Entropy coding is achieved by means of an arithmetic coding system that compresses binary symbols relative to an adaptive probability model. II. BACKGROUND THEORY The wavelet decomposition algorithm uses two analysis filters Hˆ (z) (lowpass) and Gˆ(z) (highpass). The reconstruc- tion algorithm applies the complementary synthesis filters H(z) (refinement filter) and G(z) (wavelet filter).These four filters constitute a perfect reconstruction filter bank.The wavelet transform has a continuous-time domain interpretation that involves the scaling functions ϕˆ(x) and ϕ(x) , which are solutions of two-scale relations with filters Hˆ (z) and H(z) , respectively. The scaling function ϕ(x) associated with the filter H(z) is the L2-solution (if it exists) of the two-scale relation 2 X ϕ(x) = h ϕ(2x − k) (2) H(1) k kZ While it is usually difficult to obtain an explicit characterization of ϕ(x) in the time domain, one can express its Fourier transform as a convergent infinite product ∞ j(ω/2 Y H(e ) ϕˆ(x) = (3) H(1) k=1 A simple way to generate a scaling function is to run the synthesis part of the wavelet transform algorithm starting with an impulsethis is often referred to as the cascade algorithm. Much of the early work in wavelet theory has been devoted to working out the mathematical properties (convergence, regularity, order, etc.,) of these scaling functions. Thewavelets themselves do usually not pose a problem because they are linear combination of the scaling functions, i.e., EE678 WAVELETS APPLICATION ASSIGNMENT 3 2 X ψ(x) = g ϕ(2x − k) (4) H(1) k kZ 2 X ψˆ(x) = gˆ ϕˆ(2x − k) (5) H(1) k kZ ˆ −i/2 ˆ i The corresponding analysis and synthesis wavelet basis functions are ψi,k = 2 ψ(x/2 − k) and ψi,k = 2−i/2ψ(x/2i − k) , respectively, where and are the translation and scale indices. A necessary condition for the conver- gence of (2) to an L2-stable function , is that the filter has a zero at z = 1 . More generally, the refinement filters will have a specified number of regularity factors, which determine their order of approximation, defined as the number of factors (1 + z−1) that divide H(z). Fig. 2. Synthesis LEGall JPEG filter of length 3 and corresponding scaling function. Another important characteristic of a scaling function is its smoothness in the sense of degree of differentiability. The Besov regularity essentially specifies the fractional degree of differentiability of the function in the Lp-sense. The most stringent measure corresponds to the case p = ∞ and coincides with the Holder regularity which is a classical measure of pointwise continuity. The other most commonly-used measure is the Sobolev regularity which corresponds to the intermediate Besov case p = 2 ; it is a more global indicator of smoothness that is entirely specified in the Fourier domain. Most researchers agree that a minimum of regularity (typically, continuity) is desirable for a good convergence behavior of the iterated filterbank. The next point concerns the stability of the wavelet representation and of its underlying multiresolution bases. The crucial mathematical property is that the translates of the scaling functions and wavelets form Riesz bases. Thus, one EE678 WAVELETS APPLICATION ASSIGNMENT 4 needs to characterize their Riesz bounds and other related quantities. The tightest upper and lower bounds, B < 1 2 and A > 0, of the autocorrelation filter of ϕ(x) are the Riesz bounds of ϕ(x) i.e. A = infω[0,2π]aϕ(ω) and 2 B = supω[0,2π]aϕ(ω), where aϕ(ω) is the auto-correlation filter. The existence of the Riesz bounds ensures that the underlying basis functions are in L2 and that they are linearly independent. JPEG2000 restricts the users choice to two wavelet transforms: Daubechies 9/7 for lossy compression, and the 5/3 LeGall wavelet, which has rational coefficients, for reversible or lossless compression. It also specifies that these should be implemented using the lifting scheme. The JPEG2000 LeGall 5/3 scaling filters are given by 1 H(z) = z(1 + z−1)2(−z − z−1 + 4) (6) 8 1 H(z) = z(1 + z−1)2 (7) 2 Tha analysis filter has approximation order of 2, Holder regularity of 0 and Riesz bounds of 1 < 1.944 and the synthesis filter has approximation order of 2, Holder regularity of 1 and Riesz bounds of 0.577 < 1. The synthesis function (Fig. 2) is the linear B-spline which is boundedly differentiable. The analysis function (Fig. 3) is also in but has no smoothness at all; it is merely bounded. The Riesz bounds are not very tight indicating that the functions are far from orthogonal. A less favorable aspect of this transform is the relative magnitude of the wavelet constant which comes as a consequence of the lack of tightness of the Riesz bounds.