Professional Documents
Culture Documents
Why Transform?
Purpose of transform
Remove correlation between input samples Transform most energy of an input block into a few coefficients Small coefficients can be discarded by quantization without too much impact to reconstruction quality
Block Transform
Divide input data into blocks Encode each block separately (sometimes with information from neighboring blocks) Most DCT-based image/video/audio coding standards Reduce delay and the complexity (e.g. memory requirement)
Orthogonal Transform: T1 = TT
T*TT= I
Optimum Transform
If Ax = x,
: Eigenvalues of A x: Eigenvectors of A
DCT is the approximation of the KLT of AR(1) signal when its correlation coefficient is close to 1 (e.g. 0.95) DCT Definition
JPEG
Joint Photographic Experts Group
ISO/IEC JTC1 SC29 WG1 Formed in 1986 by ISO and CCITT (ITU-T) Became International Standard (IS) in 1991 ISO/IEC IS 10918-1 (ITU-T T.81): Requirements and guidelines ISO/IEC IS 10918-2 (ITU-T T.83): Compliance testing ISO/IEC IS 10918-3 (ITU-T T.84): Extensions
Baseline JPEG
8x8
DCT
DCT
JPEG Quantization
Uniform mid-tread quantizer Larger step sizes for chroma components Different coefficients have different step sizes
Smaller sizes for low frequency coefficients (more bits) Larger sizes for low frequency coefficients (less bits) Human visual system is not sensitive to error in high frequency.
Entropy Coding
Zig-Zag Scanning
Entropy Coding
DCT
DC Prediction
DC Coefficients: Average of a block DC of neighboring blocks are still similar to each others: redundancy The redundancy can be removed by differential coding:
e(n) = DC(n) DC(n-1)
Quality Factor
Actual step size: Scale the basic table by a quality factor. Actual Q table = scaling x Basic Q table:
Q: quality factor 50: scaling = 50 / quality; quality factor > 50: scaling = 2 - quality / 50;
Rate Control
Controlling Quality
Q: Quality Factor (0<Q<100) Higher Q Better Quality
Controlling Bit-rate
Use a lookup-table and trade-off Lower Q for more complex picture Higher Q for simple picture
JPEG Example
JPEG Quantization
JPEG Example
JPEG Implementation
JPEG Implementation
JPEG 2000
Image Coding System (JTC 1.29.14, ISO 15444)
Goals
Low bit-rate compression e.g., below 0.25 bpp for highly detailed gray-level images Lossless and lossy compression in a single bitstream Large images (More than 64K by 64K) Single decompression architecture Transmission in noisy environments Computer generated imagery Compound documents: bi-level and gray-scale
JPEG Implementation
JPEG Implementation
JPEG Implementation
JPEG Implementation
JPEG Types
Baseline JPEG Sequential JPEG Progressive JPEG
Lossless Lossy
Progressive JPEG
Baseline JPEG encodes the image block by block:
Decoder has to wait till the end to decode and display the entire image.
Successive approximation:
* Send MSB of all coefficients first. * Send lower significant bits in subsequent scans.
JPEG 2000
Image Coding System (JTC 1.29.14, ISO 15444)
Goals
Low bit-rate compression e.g., below 0.25 bpp for highly detailed gray-level images Lossless and lossy compression in a single bitstream Large images (More than 64K by 64K) Single decompression architecture Transmission in noisy environments Computer generated imagery Compound documents: bi-level and gray-scale