T.Sharon-A.Frank 1 Multimedia Image Compression 2 T.Sharon-A.Frank Coding Techniques – Hybrid.

Slides:



Advertisements
Similar presentations
T.Sharon-A.Frank 1 Multimedia Compression Basics.
Advertisements

Chapter 7 End-to-End Data
SWE 423: Multimedia Systems
Department of Computer Engineering University of California at Santa Cruz Data Compression (3) Hai Tao.
JPEG.
SWE 423: Multimedia Systems Chapter 7: Data Compression (4)
Data Compression Basics
Image (and Video) Coding and Processing Lecture: DCT Compression and JPEG Wade Trappe Again: Thanks to Min Wu for allowing me to borrow many of her slides.
JPEG Still Image Data Compression Standard
Hao Jiang Computer Science Department Sept. 27, 2007
CMPT 365 Multimedia Systems
Multimedia Compression
CS430 © 2006 Ray S. Babcock Lossy Compression Examples JPEG MPEG JPEG MPEG.
5. 1 JPEG “ JPEG ” is Joint Photographic Experts Group. compresses pictures which don't have sharp changes e.g. landscape pictures. May lose some of the.
Why Compress? To reduce the volume of data to be transmitted (text, fax, images) To reduce the bandwidth required for transmission and to reduce storage.
Roger Cheng (JPEG slides courtesy of Brian Bailey) Spring 2007
1 JPEG Compression CSC361/661 Burg/Wong. 2 Fact about JPEG Compression JPEG stands for Joint Photographic Experts Group JPEG compression is used with.jpg.
Image Compression JPEG. Fact about JPEG Compression JPEG stands for Joint Photographic Experts Group JPEG compression is used with.jpg and can be embedded.
Image Compression: JPEG Multimedia Systems (Module 4 Lesson 1)
Image and Video Compression
Image Compression - JPEG. Video Compression MPEG –Audio compression Lossy / perceptually lossless / lossless 3 layers Models based on speech generation.
Trevor McCasland Arch Kelley.  Goal: reduce the size of stored files and data while retaining all necessary perceptual information  Used to create an.
CM613 Multimedia storage and retrieval Lecture: Lossy Compression Slide 1 CM613 Multimedia storage and retrieval Lossy Compression D.Miller.
Lossy Compression Based on spatial redundancy Measure of spatial redundancy: 2D covariance Cov X (i,j)=  2 e -  (i*i+j*j) Vertical correlation   
Compression is the reduction in size of data in order to save space or transmission time. And its used just about everywhere. All the images you get on.
Introduction to JPEG Alireza Shafaei ( ) Fall 2005.
CS Spring 2012 CS 414 – Multimedia Systems Design Lecture 8 – JPEG Compression (Part 3) Klara Nahrstedt Spring 2012.
JPEG Motivations: Motivations: 1.Uncompressed video and audio data are huge. In HDTV, the bit rate easily exceeds 1 Gbps. --> big problems for.
ECE472/572 - Lecture 12 Image Compression – Lossy Compression Techniques 11/10/11.
1 Image Compression. 2 GIF: Graphics Interchange Format Basic mode Dynamic mode A LZW method.
Klara Nahrstedt Spring 2011
Concepts of Multimedia Processing and Transmission IT 481, Lecture 5 Dennis McCaughey, Ph.D. 19 February, 2007.
JPEG. The JPEG Standard JPEG is an image compression standard which was accepted as an international standard in  Developed by the Joint Photographic.
Indiana University Purdue University Fort Wayne Hongli Luo
CIS679: Multimedia Basics r Multimedia data type r Basic compression techniques.
JPEG CIS 658 Fall 2005.
Image Compression Supervised By: Mr.Nael Alian Student: Anwaar Ahmed Abu-AlQomboz ID: IT College “Multimedia”
1 Image Formats. 2 Color representation An image = a collection of picture elements (pixels) Each pixel has a “color” Different types of pixels Binary.
Outline Kinds of Coding Need for Compression Basic Types Taxonomy Performance Metrics.
Chapter 9 Image Compression Standards 9.1 The JPEG Standard 9.2 The JPEG2000 Standard 9.3 The JPEG-LS Standard 9.5 Further Exploration Li & Drew1.
Compression There is need for compression: bandwidth constraints of multimedia applications exceed the capability of communication channels Ex. QCIF bit.
An introduction to audio/video compression Dr. Malcolm Wilson.
CS Spring 2014 CS 414 – Multimedia Systems Design Lecture 10 – Compression Basics and JPEG Compression (Part 4) Klara Nahrstedt Spring 2014.
The JPEG Standard J. D. Huang Graduate Institute of Communication Engineering National Taiwan University, Taipei, Taiwan, ROC.
Multimedia- and Web-based Information Systems Lecture 6.
The task of compression consists of two components, an encoding algorithm that takes a file and generates a “compressed” representation (hopefully with.
JPEG (Joint Photographic Expert Group)
JPEG Image Compression Standard Introduction Lossless and Lossy Coding Schemes JPEG Standard Details Summary.
JPEG.
Page 11/28/2016 CSE 40373/60373: Multimedia Systems Quantization  F(u, v) represents a DCT coefficient, Q(u, v) is a “quantization matrix” entry, and.
STATISTIC & INFORMATION THEORY (CSNB134) MODULE 11 COMPRESSION.
Introduction to JPEG m Akram Ben Ahmed
JPEG. Introduction JPEG (Joint Photographic Experts Group) Basic Concept Data compression is performed in the frequency domain. Low frequency components.
1 Chapter 4: Compression (Part 2) Image Compression.
By Dr. Hadi AL Saadi Lossy Compression. Source coding is based on changing of the original image content. Also called semantic-based coding High compression.
An introduction to audio/video compression Prepared by :: Bhatt shivani ( )
IS502:M ULTIMEDIA D ESIGN FOR I NFORMATION S YSTEM M ULTIMEDIA OF D ATA C OMPRESSION Presenter Name: Mahmood A.Moneim Supervised By: Prof. Hesham A.Hefny.
MP3 and AAC Trac D. Tran ECE Department The Johns Hopkins University Baltimore MD
JPEG Compression What is JPEG? Motivation
IMAGE COMPRESSION.
JPEG Image Coding Standard
Discrete Cosine Transform
JPEG.
CMPT 365 Multimedia Systems
Judith Molka-Danielsen, Oct. 02, 2000
JPEG Still Image Data Compression Standard
The JPEG Standard.
Image Coding and Compression
Presentation transcript:

T.Sharon-A.Frank 1 Multimedia Image Compression

2 T.Sharon-A.Frank Coding Techniques – Hybrid

3 T.Sharon-A.Frank Hybrid coding Images: –JPEG Video/Audio –MJPEG –MPEG (1, 2, 4) –Other codings –H.26x

4 Image files may be too big for network transmission, even at low resolutions. Use more sophisticated data representation or discard information to reduce data size. Effectiveness of compression will depend on actual image data. For any compression scheme, there will always be some data for which 'compressed' version is actually bigger than the original. Image Compression

5 T.Sharon-A.Frank Compression Steps 1. Preparation: analog to digital conversion. 2. Processing: transform data into a domain easier to compress. 3. Quantization: reduce precision at which the output is stored. 4. Entropy encoding: remove redundant information in the resulting data stream. Picture Preparation Picture Processing Quanti- zation Entropy Encoding Image Uncompressed Image Compressed

6 T.Sharon-A.Frank JPEG Goals: Support still images True color/grayscale Continuous-tone pictures Usually lossy Subjects: Quality Steps Modes Joint Photographic Experts Group

7 T.Sharon-A.Frank JPEG Picture Quality 0.25 – 0.5 bits/pixel Moderate to good quality. 0.5 – 0.75 bits/pixel Good to very good quality – 1.5 bits/pixel Excellent quality. 1.5 – 2.0 bits/pixel Usually indistinguishable from the original.

8 Lossy technique, well suited to photographs, images with fine detail and continuous tones. Consider image as a spatially varying signal that can be analysed in the frequency domain. Experimental fact: people do not perceive the effect of high frequencies in images very accurately. Hence, high frequency information can be discarded without perceptible loss of quality. JPEG Compression

9 T.Sharon-A.Frank Stage 1: Image Preparation C1C1 C2C2 CnCn * * * YjYj XiXi Sample s Left Right Line 1<= n <=255, usually 3 Top Bottom Components

10 T.Sharon-A.Frank 3 components having the same resolution A1A1 A2A2 AnAn Y X B1B1 B2B2 BnBn Y X C1C1 C2C2 CnCn Y X

11 T.Sharon-A.Frank A1A1 A2A2 AnAn Y X B1B1 B2B2 B n/2 Y X/2 C1C1 C2C2 C n/2 Y X/2 3 components having different resolution

12 If image resolution < output device resolution, must interpolate extra pixels –Always leads to loss of quality. If image resolution > output device resolution, must downsample (discard pixels): –Quality will often be better than that of an image at device resolution (uses more information). – Image sampled at a higher resolution than that of intended output device is over sampled. Changing Resolution

13 T.Sharon-A.Frank Block Preparation (a) RGB input data. (b) After block preparation.

14 T.Sharon-A.Frank Non Interleaved Order of Data Units Left Right Top ******** ******** ******** ******** ******** Bottom MCU = Minimum Coded Unit

15 T.Sharon-A.Frank Interleaved Data Units * * * **** **** **** **** **** **** 0101 *** ***

16 T.Sharon-A.Frank Stage 2: Image Processing Using DCT (Discrete Cosine Transform) Convert from Spatial to Frequency Domain Input : 8x8 matrix of 64 values Output: –1 DC value (basic color of block = average color) –63 AC values low frequency coefficients, have high values high frequency coefficients – represent sharp edges, have low values

17 T.Sharon-A.Frank Discrete Cosine Transform (DCT) A Fourier-related transform similar to the Discrete Fourier Transform (DFT), but using only real numbers. Often used in signal and image processing. Maps values from spatial domain to frequency domain – image areas with low frequency (large blocks of single color) are compressed more efficiently. Used in JPEG, MJPEG, MPEG, and DV Compression.

18 Analyses a signal into its frequency components. Takes array of pixel values, produces an array of coefficients of frequency components in the image. Computationally expensive process – time proportional to square of number of pixels. Usually applied to 8x8 blocks of pixels. DCT Dynamics

19 T.Sharon-A.Frank JPEG: DCT-Based Encoder 8x8 blocks Compressed Image Data Quantizer Entropy Encoder FDCT Table Specification Source Image Data

20 T.Sharon-A.Frank Block i-1 Block i DC i DC i-1 DIFF=DC i -DC i-1 Preparation of DC Coefficients

21 T.Sharon-A.Frank (a) One block of the Y matrix. (b) The DCT coefficients. DCT Transformation

22 T.Sharon-A.Frank Preparation of AC Coefficients AC 07 AC 01 DC AC 77 AC 70 Zig-Zag Sequence

23 T.Sharon-A.Frank Probability Distribution of DCT Coefficients Probability of being nonzero Zigzag index

24 T.Sharon-A.Frank Next Stages Stage 3: Quantization Based on quantization table: –Quantization table: values from 1 to 255 –DCT coefficient/Table value –If value > 0, keep DCT coefficient else, don’t keep DCT coefficient Stage 4: Entropy Encoding

25 Applying DCT does not reduce data size –Array of coefficients is same size as array of pixels. Allows information about high frequency components to be identified and discarded. Use fewer bits (distinguish fewer different values) for higher frequency components. Number of levels for each frequency coefficient may be specified separately in a quantization matrix. JPEG Quantization

26 T.Sharon-A.Frank Computation of the quantized DCT coefficients

27 T.Sharon-A.Frank Order in which the quantized values are transmitted

28 After quantization, there will be many zero coefficients. –Use RLE on zig-zag sequence (maximizes runs). Use Huffman coding of other coefficients (best use of available bits). JPEG Entropy Encoding

29 T.Sharon-A.Frank Steps of JPEG Compression Picture Preparation Pixel Block, MCU Picture Processing Predictor FDCT Quantization Entropy Encoding Run-Length Huffman Arithmetic Steps taking into account the different JPEG modes

30 Expand runs of zeros and decompress Huffman- encoded coefficients to reconstruct array of frequency coefficients. Use Inverse Discrete Cosine Transform to take data back from frequency to spatial domain. Data discarded in quantization step of compression procedure cannot be recovered. Reconstructed image is an approximation (usually very good) to the original image. JPEG Decompression

31 T.Sharon-A.Frank JPEG: DCT-Based Decoder Dequantizer Entropy Encoder IDCT Table Specification Reconstructe d Image Data Compressed Image Data

32 T.Sharon-A.Frank JPEG Modes of Operation Lossless Encoding: the image is encoded to guarantee exact recovery of every source image sample value (low compression ratio). Sequential Encoding: each image is encoded in a single left-to-right, top-to-bottom scan. Progressive Encoding: the image is encoded in multiple scans for applications in which transmission time is long. Hierarchical Encoding: the image is encoded at multiple resolutions.

33 T.Sharon-A.Frank Sequential Presentation

34 T.Sharon-A.Frank Progressive Presentation

35 T.Sharon-A.Frank Types of image processing in DCT Image display Bits per sample Entropy coding Sequential 8 Huffman coding Sequential 8 Arithmetic coding Sequential 12 Huffman coding Sequential 12 Arithmetic coding Progressive successive 8 Huffman coding Progressive spectral 8 Huffman coding Progressive successive 8 Arithmetic coding Progressive spectral 8 Arithmetic coding Progressive successive 12 Huffman coding Progressive spectral 12 Huffman coding Progressive successive 12 Arithmetic coding Progressive spectral 12 Arithmetic coding

36 T.Sharon-A.Frank Hybrid Coding Examples JPEG –image compression using a discrete cosine transform, then quantization, then Huffman coding. JPEG 2000 –image compression using wavelets, then quantization, then entropy coding. MP3 –A part of the MPEG-1 standard for sound and music compression, using subbanding and MDCT, perceptual modeling, quantization, and Huffman coding.