Concepts of Multimedia Processing and Transmission IT 481, Lecture 5 Dennis McCaughey, Ph.D. 19 February, 2007.

Slides:



Advertisements
Similar presentations
JPEG Compresses real images Standard set by the Joint Photographic Experts Group in 1991.
Advertisements

FAX and TIFF Modified Huffman coding is used in fax machines.
Chapter 7 End-to-End Data
SWE 423: Multimedia Systems
School of Computing Science Simon Fraser University
Department of Computer Engineering University of California at Santa Cruz Data Compression (3) Hai Tao.
JPEG.
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.
CS :: Fall 2003 MPEG-1 Video (Part 1) Ketan Mayer-Patel.
CMPT 365 Multimedia Systems
T.Sharon-A.Frank 1 Multimedia Image Compression 2 T.Sharon-A.Frank Coding Techniques – Hybrid.
Lecture 3 Text and Image Compression. Compression Principles By compression the volume of information to be transmitted can be reduced. At the same time.
Multimedia Data The DCT and JPEG Image Compression Dr Mike Spann Electronic, Electrical and Computer.
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.
CSE679: MPEG r MPEG-1 r MPEG-2. MPEG r MPEG: Motion Pictures Experts Group r Standard for encoding videos/movies/motion pictures r Evolving set of standards.
Image Compression: JPEG Multimedia Systems (Module 4 Lesson 1)
Image and Video Compression
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   
CS559-Computer Graphics Copyright Stephen Chenney Image File Formats How big is the image? –All files in some way store width and height How is the image.
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.
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
Prof. Amr Goneid Department of Computer Science & Engineering
JPEG. The JPEG Standard JPEG is an image compression standard which was accepted as an international standard in  Developed by the Joint Photographic.
Multimedia Data DCT Image Compression
Indiana University Purdue University Fort Wayne Hongli Luo
CIS679: Multimedia Basics r Multimedia data type r Basic compression techniques.
JPEG CIS 658 Fall 2005.
Digital Image Processing Image Compression
1 Image Formats. 2 Color representation An image = a collection of picture elements (pixels) Each pixel has a “color” Different types of pixels Binary.
Compression There is need for compression: bandwidth constraints of multimedia applications exceed the capability of communication channels Ex. QCIF bit.
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.
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.
CS654: Digital Image Analysis
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.
Block-based coding Multimedia Systems and Standards S2 IF Telkom University.
STATISTIC & INFORMATION THEORY (CSNB134) MODULE 11 COMPRESSION.
Introduction to JPEG m Akram Ben Ahmed
Image Processing Architecture, © Oleh TretiakPage 1Lecture 7 ECEC 453 Image Processing Architecture Lecture 8, February 5, 2004 JPEG: A Standard.
JPEG. Introduction JPEG (Joint Photographic Experts Group) Basic Concept Data compression is performed in the frequency domain. Low frequency components.
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.
1 Chapter 3 Text and image compression Compression principles u Source encoders and destination decoders u Lossless and lossy compression u Entropy.
JPEG Compression What is JPEG? Motivation
Chapter 9 Image Compression Standards
Digital Image Processing Lecture 21: Lossy Compression May 18, 2005
JPEG Image Coding Standard
JPEG.
Image Compression Standards (JPEG)
Chapter 7.2: Layer 5: Compression
CMPT 365 Multimedia Systems
CIS679: JPEG (more) Review of JPEG More about JPEG Lab project.
UNIT IV.
The JPEG Standard.
Image Coding and Compression
Presentation transcript:

Concepts of Multimedia Processing and Transmission IT 481, Lecture 5 Dennis McCaughey, Ph.D. 19 February, 2007

02/12/2007 Dennis Mccaughey, IT 481, Spring GIF Compression Principles: Basic Operational Mode

02/12/2007 Dennis Mccaughey, IT 481, Spring GIF Compression Principles: Dynamic Mode Using LZW Encoding

02/12/2007 Dennis Mccaughey, IT 481, Spring GIF interlaced mode

02/12/2007 Dennis Mccaughey, IT 481, Spring ITU-T Facsimile Standards T2 (Group1) – no longer used T3 (Group 2) – no longer used T4 (Group 3) –Intended for use with modems on analog PSTN lines T6 (Group 4) –All digital for use with digital networks such as ISDN Compression ratios of 10:1 are common

02/12/2007 Dennis Mccaughey, IT 481, Spring Termination and Make-up Codes Termination Codes –White or black run-lengths from 0 to 63 pixels Make-up Codes –For run lengths that are multiples of 64 pixels Overscanning –All lines start with a minimum of one white pixel –Receiver knows the first codeword relates to white pixels and the alternates between black and white Since two code tables are used they are denoted Modified Huffman Codes Examples: –Run-length of 12 black pixels is encoded –A Run-length of 140 black pixels = is encoded as

02/12/2007 Dennis Mccaughey, IT 481, Spring Group 3 (T4) Group 3 provides no error correction –If one or more pixels is corrupted, receiver will lose synchronization –Each line is terminated with a known EOL code –If synch is lost receiver searches for the EOL code and if not found within a preset number of lines, it aborts the reception process and informs the sending machine the sending machine to terminate One dimensional process –Works well for documents contain significant areas of black and white pixels such as letter documents –For documents containing half-tones it can result in a negative compression ratio

02/12/2007 Dennis Mccaughey, IT 481, Spring Group 4 (T6) T6 is an optional feature in Group 3, but is compulsory in Group 4 2-D scheme –Identified black and white run-lengths by comparing adjacent scan lines –Known as Modified Relative Element Address Designate (READ) (MMR) coding MMR encoding exploits the fact that most scan lines differ from the previous ones by only a few pixels –Always assume the first reference line is an imaginary “all white” line

02/12/2007 Dennis Mccaughey, IT 481, Spring Modified READ Coding Procedure

02/12/2007 Dennis Mccaughey, IT 481, Spring Two-Dimensional Code Table Additional Codes necessary to identify mode Extension Mode –Aborts the encoding prematurely before the end of the page –Allows a portion of the page to e sent in its uncompressed form or with a different encoding scheme Mode Run- Length AbbreviationsCodeword Passb1b2b1b2 P0001+b 1 b 2 Horizontala 0 a 1,a 1 a 2 H001+a 0 a 1 +a 1 a 2 Vertical a 1 b 1 = 0 a 1 b 1 = -1 a 1 b 1 = -2 a 1 b 1 = -3 a 1 b 1 = +1 a 1 b 1 = +2 a 1 b 1 = +3 V(0) V R (1) V R (2) V R (3) V L (1) V L (2) V L (3) Extensions

02/12/2007 Dennis Mccaughey, IT 481, Spring Figure 3.11

02/12/2007 Dennis Mccaughey, IT 481, Spring Some example run-length possibilities: pass mode This is the case when the run-length in the reference line (b 1,b 2 ) is to the left of the next run-length in the coding line ( a 1,a 2 ), that is b 2 is to the left of a 1. The run-length b 1 b 2 is coded using the code words given in Figure 3.11 If the next pixel on the coding line, a 1, is directly below b 2 this is not pass mode

02/12/2007 Dennis Mccaughey, IT 481, Spring Some example run-length possibilities: vertical mode This is the case when the run-length in the reference line (b 1,b 2 ) overlaps the next run-length in the coding line (a 1,a 2 ) by a maximum of + 3 pixels that is b 2 is to the left of a 1. Two examples are shown, and for this mode just the difference run length a 1 b 2 is coded Most codewords are in this category

02/12/2007 Dennis Mccaughey, IT 481, Spring Some example run-length possibilities: horizontal mode This is the case when the run-length in the reference line (b 1,b 2 ) overlaps the next run-length in the coding line (a 1,a 2 ) by more than + 3 pixels that is b 2 is to the left of a 1. Two examples are shown, and for this mode the two run-lengths a 0 a 1 and a 1 a 2 are coded using the code words given in Figure 3.11

02/12/2007 Dennis Mccaughey, IT 481, Spring JPEG Joint Photographic Experts Group Standard- ISO/IEC10918 Lossy algorithm Focus attention on the Baseline Mode Five main stages 1.Image/Block Preparation 2.Forward DCT 3.Quantization 4.Entropy Encoding 5.Frame Building

02/12/2007 Dennis Mccaughey, IT 481, Spring JPEG Encoder Schematic

02/12/2007 Dennis Mccaughey, IT 481, Spring Image/block preparation: image preparation Block Image planes into 8x8 Blocks Can use either: R,G,B or Y,Cb,Cr

02/12/2007 Dennis Mccaughey, IT 481, Spring Image/block preparation: block preparation

02/12/2007 Dennis Mccaughey, IT 481, Spring Forward DCT

02/12/2007 Dennis Mccaughey, IT 481, Spring DCT Computation Features

02/12/2007 Dennis Mccaughey, IT 481, Spring Quantization Eye responds primarily to the DC and lower frequency components –If the magnitude of the higher frequency components is less than a certain threshold the eye will not perceive it –Within the quantization process frequencies below a threshold are zeroed Quantization process reduces the magnitude of the DC and the AC coefficients so that less bandwidth is required for transmission This is achieved by dividing the coefficients by a normalization matrix which will zero the smaller coefficients

02/12/2007 Dennis Mccaughey, IT 481, Spring Example computation of a set of quantized DCT coefficients

02/12/2007 Dennis Mccaughey, IT 481, Spring Observations The computation of the quantized coefficients involves divideing the coefficients by a normalization factor and rounding the coefficients to the nearest integer value The normalization values used, in general, increase in magnitude with increasing spatial frequency The DC coefficient in the matrix is the largest Many of the higher frequency coefficients are zero

02/12/2007 Dennis Mccaughey, IT 481, Spring Example 3.4

4. Entropy Coding

02/12/2007 Dennis Mccaughey, IT 481, Spring Vectoring Using a Zigzag Scan: (a) Principle; (b) for previous example AC ={(0,6) (0,7) (0,3) (0,3) (0,3) (0,2) (0,2) (0,2) (0,2) (0,0)}

02/12/2007 Dennis Mccaughey, IT 481, Spring AC Coefficient Encoding AC coefficients are encoded within a block using run-length coding Most coefficients are zeros due to normalization Codes indicate the length of the zero run- length and the coefficient value terminating it. i.e. –(Skip, Value) (Skip, Value) are mapped to (SSS, Value) –SSS is Huffman Encoded, Value is encoded in 1’s complement binary code words of length specified by SSS

02/12/2007 Dennis Mccaughey, IT 481, Spring SSS vs. Value Null 0,1 00,01,10,11 000,001,010,011,100,101,110, ,1 -3,2,2, , …-8,8…15 -31…,-16,16… ….-32,32… ……-64,64…… … ,128…… …… ,256……… ….…..-512,512……… ….....,-1023,1023…..… Encoded ValueSSSDifference Value

02/12/2007 Dennis Mccaughey, IT 481, Spring Process

02/12/2007 Dennis Mccaughey, IT 481, Spring Default Huffman Code Words for SSS (DC Coefficients)

02/12/2007 Dennis Mccaughey, IT 481, Spring DC Coefficients DC coefficients are differentially encoded across the blocks –Takes advantage of the local correlation in the average value among local blocks –{12,13,11,11,10} -> {12,1,-2,0,-1}

02/12/2007 Dennis Mccaughey, IT 481, Spring Frame Building Frame Header –Overall width and height of the image in pixels –The number and type of components that are used to represent the image (CLUT, RGB, YC b C r ) –Digitization format used: (4:2:2,4;2;0, etc) Scan Header –Identity of the components (RGB etc) –The number of bits used to digitize each component; –The quantizatio table of values used to encode each component

02/12/2007 Dennis Mccaughey, IT 481, Spring JPEG Encoder Output Bit Stream Format

02/12/2007 Dennis Mccaughey, IT 481, Spring JPEG decoder schematic