Image and Video Compression

Slides:



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

Basics of MPEG Picture sizes: up to 4095 x 4095 Most algorithms are for the CCIR 601 format for video frames Y-Cb-Cr color space NTSC: 525 lines per frame.
Source Coding for Video Application
Chapter 7 End-to-End Data
Department of Computer Engineering University of California at Santa Cruz Data Compression (3) Hai Tao.
Department of Computer Engineering University of California at Santa Cruz Video Compression Hai Tao.
JPEG.
CS :: Fall 2003 MPEG Video (Part 2) Ketan Mayer-Patel.
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.
JPEG Still Image Data Compression Standard
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.
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.
©Brooks/Cole, 2003 Chapter 15 Data Compression. ©Brooks/Cole, 2003 Realize the need for data compression. Differentiate between lossless and lossy compression.
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. 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.
Lossy Compression Based on spatial redundancy Measure of spatial redundancy: 2D covariance Cov X (i,j)=  2 e -  (i*i+j*j) Vertical correlation   
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.
Video Coding. Introduction Video Coding The objective of video coding is to compress moving images. The MPEG (Moving Picture Experts Group) and H.26X.
Introduction to JPEG and MPEG Ingemar J. Cox University College London.
MPEG-1 and MPEG-2 Digital Video Coding Standards Author: Thomas Sikora Presenter: Chaojun Liang.
MPEG: (Moving Pictures Expert Group) A Video Compression Standard for Multimedia Applications Seo Yeong Geon Dept. of Computer Science in GNU.
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
JPEG CIS 658 Fall 2005.
MPEG MPEG : Motion Pictures Experts Group MPEG : ISO Committee Widely Used Video Compression Standard.
June, 1999 An Introduction to MPEG School of Computer Science, University of Central Florida, VLSI and M-5 Research Group Tao.
Image Compression Supervised By: Mr.Nael Alian Student: Anwaar Ahmed Abu-AlQomboz ID: IT College “Multimedia”
Compression There is need for compression: bandwidth constraints of multimedia applications exceed the capability of communication channels Ex. QCIF bit.
Compression video overview 演講者:林崇元. Outline Introduction Fundamentals of video compression Picture type Signal quality measure Video encoder and decoder.
CS Spring 2014 CS 414 – Multimedia Systems Design Lecture 10 – Compression Basics and JPEG Compression (Part 4) Klara Nahrstedt Spring 2014.
Advances in digital image compression techniques Guojun Lu, Computer Communications, Vol. 16, No. 4, Apr, 1993, pp
The JPEG Standard J. D. Huang Graduate Institute of Communication Engineering National Taiwan University, Taipei, Taiwan, ROC.
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.
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.
MPEG CODING PROCESS. Contents  What is MPEG Encoding?  Why MPEG Encoding?  Types of frames in MPEG 1  Layer of MPEG1 Video  MPEG 1 Intra frame Encoding.
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.
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.
1 Chapter 3 Text and image compression Compression principles u Source encoders and destination decoders u Lossless and lossy compression u Entropy.
Video Compression Video : Sequence of frames Each Frame : 2-D Array of Pixels Video: 3-D data – 2-D Spatial, 1-D Temporal Video has both : – Spatial Redundancy.
H. 261 Video Compression Techniques 1. H.261  H.261: An earlier digital video compression standard, its principle of MC-based compression is retained.
JPEG Compression What is JPEG? Motivation
Chapter 9 Image Compression Standards
JPEG Image Coding Standard
JPEG.
CMPT 365 Multimedia Systems
CIS679: MPEG MPEG.
ENEE 631 Project Video Codec and Shot Segmentation
JPEG Still Image Data Compression Standard
Presentation transcript:

Image and Video Compression Two dimensional array of pixel values Spatial redundancy and temporal redundancy Human eye is less sensitive to chrominance signal than to luminance signal (U and V can be coarsely coded) Human eye is less sensitive to the higher spatial frequency components Human eye is less sensitive to quantizing distortion at high luminance levels

JPEG Encoder International standards body -- Joint Photographic Experts Group JPEG encoder schematic Image/block preparation DCT computation Quantization Entropy coding -- vectoring, differential encoding, run-length encoding, Huffman encoding Frame building

Image/block Preparation Source image as 2-D matrix of pixel values R, G, B format requires three matrices, one each for R, G, B quantized values In Y, U, V representation, the U and V matrices can be half as small as the Y matrix Source image matrix is divided into blocks of 8X8 submatrices Smaller block size helps DCT computation and individual blocks are sequentially fed to the DCT which transforms each block separately

DCT Computation Each pixel value in the 2-D matrix is quantized using 8 bits which produces a value in the range of 0 to 255 for the intensity/luminance values and the range of -128 to + 127 for the chrominance values. All values are shifted to the range of -128 to + 127 before computing DCT All 64 values in the input matrix contribute to each entry in the transformed matrix The value in the location F[0,0] of the transformed matrix is called the DC coefficient and is the average of all 64 values in the matrix The other 63 values are called the AC coefficients and have a frequency coefficient associated with them Spatial frequency coefficients increase as we move from left to right (horizontally) or from top to bottom (vertically). Low spatial frequencies are clustered in the left top corner.

Quantization The human eye responds to the DC coefficient and the lower spatial frequency coefficients If the magnitude of a higher frequency coefficient is below a certain threshold, the eye will not detect it Set the frequency coefficients in the transformed matrix whose amplitudes are less than a defined threshold to zero (these coefficients cannot be recovered during decoding) During quantization, the size of the DC and AC coefficients are reduced A division operation is performed using the predefined threshold value as the divisor

Quantization Table Threshold values vary for each of the 64 DCT coefficients and are held in a 2-D matrix Trade off between the level of compression required and the information loss that is acceptable JPEG standard includes two default quantization tables -- one for the luminance coefficients and the other for use with the two sets of chrominance coefficients. Customized tables may be used

Entropy Coding Vectoring -- 2-D matrix of quantized DCT coefficients are represented in the form of a single-dimensional vector After quantization, most of the high frequency coefficients(lower right corner) are zero. To exploit the number of zeros, a zig-zag scan of the matrix is used Zig-zag scan allows all the DC coefficients and lower frequency AC coefficients to be scanned first DC are encoded using differential encoding and AC coefficients are encoded using run-length encoding. Huffman coding is used to encode both after that.

Differential Encoding DC coefficient is the largest in the transformed matrix. DC coefficient varies slowly from one block to the next. Only the difference in value of the DC coefficients is encoded. Number of bits required to encode is reduced. The difference values are encoded in the form (SSS, value) where SSS field indicates the number of bits needed to encode the value and the value field indicates the binary form.

Run-length Encoding 63 values of the AC coefficients Long strings of zeros because of the zig-zag scan Each AC coefficient encoded as a pair of values -- (skip, value), skip indicates the number of zeros in the run and value is the next non-zero coefficient

Huffman Encoding Long strings of binary digits replaced by shorter codewords Prefix property of the huffman codewords enable decoding the encoded bitstream unambiguously

Frame Building Encapsulates the information relating to an encoded image

Video Compression Video as a sequence of pictures (or frames) JPEG algorithm applied to each frame -- moving JPEG (MJPEG). Exploits only spatial redundancy. High correlation between successive frames. Only small portion of each frame is involved with any motion that is taking place. A combination of actual frame contents and predicted frame contents are used. Motion estimation and motion compensation

Frame/Picture Types Interframe and intraframe coding. High compression ratios can be achieved by using both. Random access requirement of image retrieval is satisfied by pure intraframe coding. I-frames are coded without reference to other frames. Serve as reference pictures for predictive-coded frames. P-frames are coded using motion compensated prediction from a past I-frame or P-frame. B-frames are bidirectionally predictive-coded. Highest degree of compression, but require both past and future reference pictures for motion compensation. D-frames are DC-coded. Of the DCT coefficients only the DC coefficients are present. Used in interactive applications like VoD for rewind and fast-forward operations.

Picture Sequence I B B P B B P B B I (display order) Bitstream order -- I P B B P B B P B B I Prediction span, Group of Pictures (GOP)

MPEG-video Encoding Input frames are preprocessed (color space conversion and spatial resolution adjustment). Frame types are decided for each frame/picture Each picture is divided into macroblocks of 16 X 16 pixels. Macroblocks are intracoded for I frames and predictive coded or intracoded for P and B frames Macroblocks are divided into six blocks of 8 X 8 pixels (4 luminance and 2 chrominance) and DCT is applied to each block and transform coefficients are quantized and zig-zag scanned and variable-length coded.