VIDEO COMPRESSION USING DWT AND HUFFMAN ENCODING TECHNIQUE

Page 1

International Engineering Journal For Research & Development

E-ISSN NO:-2349-0721

Vol.4 Issue 1

Impact factor : 3.35

VIDEO COMPRESSION USING DWT AND HUFFMAN ENCODING TECHNIQUE 1

1

Prof. Soniya Hokam, 2Anamika Dabli, 3Reena Narad, 4Mitali Dudhe

Professor ,

2,3,4

B.E. Student, ETC Department, SRMCEW, RTMNU University, Nagpur

________________________________________________________________________________________ ABSTRACT Digital image and video in raw form desire large amount of storage capacity. Image compression is basically mean reducing the size of graphics file, without compromising on its quality. Depending on the reconstructed image, to be exactly same as the original or some unidentified loss may be incurred, two techniques for compression exist. Two techniques are: lossy techniques and lossless techniques. Digital imaging and video play an important role in image processing hence it is necessary to develop a system that produces high degree of compression while preserving critical image/video. In this paper we present hybrid model which is the combination of several compression techniques. This paper presents DWT and DCT implementation because these are the lossy techniques and also introduce Huffman encoding technique which is lossless. On several medical, endoscopic, Lena and Barbra images simulation has been carried out. At last implement lossless technique so our PSNR and MSE will go better than the old algorithms and due to DWT and DCT we will get good level of compression. The results show that the proposed hybrid algorithm performs much better in term of peak-signal-to-noise ratio with a higher compression ratio compared to standalone DCT and DWT algorithms. Keywords — DCT (discrete cosine transform), DWT (discrete wavelet transform), MSE (mean square error), PSNR (peak signal to noise ratio)

INTRODUCTION Compression means to reducing the quantity of data required to represent a file, image or video content without excessively reducing the quality of the original data. It also decreases the number of bits in need to store and/or transmit digital media. To compress something means that you have a piece of data as well as you decrease its size. The objective of image compression is to reduce irrelevance as well as redundancy of the image data in order to be able to store and/or transmit data in an efficient form. Image compression may be lossy or lossless. Lossless compression is used for archival purposes and often for medical imaging, technical drawings, clip art, or comics. Lossy compression methods, especially when used at low bit rates, introduce compression artifacts. Lossy methods are especially apt for natural images such as photographs in applications where minor (sometimes imperceptible) loss of fidelity is acceptable to

www.iejrd.in

1


International Engineering Journal For Research & Development

Vol.4 Issue 1

achieve a substantial reduction in bit rate. Lossy compression which produces negligible differences may be called visually lossless. Video compression is the process of encoding in such a way that consumes less space than the original file and is easier to transmit over the network/internet.“Compressed” just means that the information is packed into a smaller space. Eliminates redundant and non functional data from the original video file. Video compression uses modern coding techniques to reduce redundancy in video data. Most video compression algorithms and codecs combine spatial image compression as well as temporal motion compensation. Video compression is a practical implementation of source coding in information theory. In practice, most video codecs also use audio compression techniques in parallel to compress the separate, but combined data streams as one package. The majority of video compression algorithms use lossy compression. Uncompressed video requires a very high data rate. Although lossless video compression codecs perform at a compression factor of 5-12, a typical MPEG-4 lossy compression video has a compression factor between 20 and 200. As in all lossy compression, there is a trade-off between video quality, cost of processing the compression and decompression, and system requirements. Highly compressed video may present visible or distracting artifacts. Transmission and storage of uncompressed video would be extremely costly and impractical therefore it is necessary to produce such a system that will give compressed video without changing its original quality of video. Objectives of project are as follows: 

Improved low bit-rate compression performance

Improved lossless as well as lossy compression

Improved continuous-tone and bi-level compression

Be able to compress large images

Use single decompression architecture

Transmission in noisy environments

Also robustness to bit-errors

Progressive transmission by pixel accuracy and resolution

Protective image security

www.iejrd.in

2


International Engineering Journal For Research & Development

Vol.4 Issue 1

BLOCK DIAGRAM

In fig.1, shows the block diagram of video compression using DWT technique.

Discrete Wavelet Transform Technique: Take the image. The original image/frame of size 256x256. Firstly original image/frame divided into blocks of 16x16. By using the 2-D DWT decomposed the each 16x16 blocks. The low frequency coefficients are LL and high-frequency coefficients are HL, LH and HH. When LL passed to the next stage where the high frequency coefficients (HL, LH and HH) are discarded. The passed LL components are further decomposed using another 2-D DWT and the detail coefficients (HL, LH and HH) are discarded. . 4x4 DCT has been applied to the reaming approximate DWT coefficients (LL) and can be achieved high CR. Then Huffman codes are performed on 4x4 and assign the codes to low-frequency coefficients and high-frequency coefficients. . In this lossless compression shorter codes are assigned to the most frequently used symbols, and longer codes to the symbols which appear less frequently in the string. Then the images are compressed and finally, the image is reconstructed followed by inverse procedure. During the inverse DWT, zero values are padded in place of the detail coefficients.

Fig.2 DWT & Huffman coding

Two error metrics are used to compare the various image compression techniques are:- 1.The Mean Square Error (MSE) and 2.The probalistic Signal to Noise Ratio (PSNR). The MSE is the cumulative

www.iejrd.in

3


International Engineering Journal For Research & Development

Vol.4 Issue 1

squared error between the compressed and the original image, whereas PSNR is a measure of the peak error. The mathematical formulae for the two are

Where I (x,y) is the original image, I'(x,y) is the approximated version (which is actually the decompressed image) and M, N are the dimensions of the images.

Fig.3 DWT Output

RESULT ANALYSIS: We have applied DWT & Huffman encoding technique for video compression. Followings are output images involved in video compression: 1.Converting Video into Frames: It converts input video in numbers of frames shown below(fig.)

Fig. 4 Individual Frames

2.Motion Estimation & Compensation: Motion Estimation: Motion estimation based on the input image and the reconstruction image to generate the motion vectors for each macro block. Motion estimation is carried which would give a tentative estimation on how many frames or macro blocks that can be compensated using block matching algorithm.

www.iejrd.in

4


International Engineering Journal For Research & Development

Vol.4 Issue 1

Motion Compensation: Motion compensation is an algorithm technique which describe a picture in terms of reference picture to the current picture. In motion compensation we compare current image with the reference image. Fig. shows the output of motion estimation & compensation:

Fig.5 Motion Estimation & Compensation

3.DWT & Huffman coding Output: It gives the output by compressing the data of original video without changing the quality of video:

Fig.6 Original & Recovered Video

CONCLUSION: In this paper we present a DWT and Huffman algorithm for video compression. The basic need of video compression is that for transmission and storage of uncompressed video would be extremely costly & impractical therefore it is necessary to develop a system that produces high degree of compression while preserving the original quality of video.

www.iejrd.in

5


International Engineering Journal For Research & Development

Vol.4 Issue 1

REFERENCES 1. “A New Video Compression Method using DCT/DWT and SPIHT based on Accordion Representation” Jaya Krishna Sunkara, E Navaneethasagari, D Pradeep, E Naga Chaithanya, D Pavani, D V SaiSudheer, Assistant Professor, PDCE, Sullurpet, India (I.J. Image, Graphics and Signal Processing, 2012, 4, 28-34 ) 2. “Video Compression Using Hybrid DWT-DCT Algorithm” L. Escalin Tresa1, Dr. M. Sundararajan2 1Research Scholar, Sathyabama University, Chennai 2Principal, Alpha College of Engineering & Technology, Puducherry (International Journal of Emerging Technology and Advanced Engineering Website: www.ijetae.com (ISSN 2250-2459, Volume 2, Issue 10, October 2012) 3. “A Combined DWT-DCT approach to perform Video compression base of Frame Redundancy” Jasmeetkaur and Ms.Rohini Sharma, International Journal of Advanced Research in Computer Science and Software Engineering (Volume 2, Issue 9, September 2012 ) 4. “Hybrid Image Compression Using DWT, DCT &Huffman Encoding Techniques” Harjeetpalsingh&Sakhi Sharma M.Tech Student, Lecturer, ECE Department, C.G.C Landra, Punjab Technical University, Punjab.(ISSN 22502459, Volume 2, Issue 10, October 2012) . 5. J.M.Shapiro, “Embedded image coding using zerotrees of wavelet Coefficients,” in Special Issue on Wavelet And Signal Processing,vol. 41, no. 12. IEEE Trans. Signal Processing, Dec 1993. 6. Said and W. A. Pearlman, “An image multiresolution representation for lossless and lossy compression,” in IEEE TransactionsOn Image Processing, vol. 5, no. 9, September 1996 7. X. Li, Y. Shen, and J. Ma, “An efficient medical image compression,,”in Engineering In Medicine And Biology 27th Annual Conference, Shangai, China, September 1-4 2005 IEEE 8. Ali Al-Fayadh, AbirJaafarHussain, Paulo Lisboa, and Dhiya Al- Jumeily “An Adaptive Hybrid Classified Vector Quantisation and Its Application to Image Compression” 2008 IEEE 9. Zhang Shi-qiang,ZhangShu-fang, Wang Xin-nian, Wang Yan “ The Image Compression Method Based on Adaptive Segment and Adaptive Quantified” 2008 IEEE 10. SuchitraShrestha and Khan Wahid,”Hybrid DWT-DCT algorithem for biomedical image and video compression application.” 2010 10th International conference.

www.iejrd.in

6


Turn static files into dynamic content formats.

Create a flipbook
Issuu converts static files into: digital portfolios, online yearbooks, online catalogs, digital photo albums and more. Sign up and create your flipbook.