Eee 427 - 4
Eee 427 - 4
EEE 427
Introduction
• Data compression refers to reducing the number of bits that need to
be transmitted for exchanging a given volume of information.
• Data compression techniques are also used for reducing the data
storage requirements.
• Data compression is the process of encoding information using fewer
bits than the original representation. It aims to reduce the size of data
files, enhancing storage efficiency and speeding up data transmission.
• Virtually all forms of data contain redundancy, i.e. information
content is less than what the data representation is capable of.
• Compression can be either lossless or lossy.
Lossy Compression
• Lossy compression reduces bits by removing unnecessary or
less important information, which can result in some loss of
data.
• It is commonly used for multimedia data such as images,
audio, and video.
• Techniques include:
✓ Discrete Cosine Transform (DCT): Used in JPEG for
images and MPEG for video
✓ Psychoacoustic Models: Used in audio compression
formats like MP3 and AAC to remove inaudible components
Lossless Compression
• Lossless compression algorithms exploit statistical redundancy to
represent data without losing any information, making the process
reversible.
• Common techniques include:
➢ Run-Length Encoding (RLE): Encodes sequences of the same data value
as a single data value and count.
➢ Lempel-Ziv (LZ) Methods: Use a table-based compression model where
table entries are substituted for repeated strings of data. Examples
include LZW, used in GIF images, and DEFLATE, used in PNG files1.
➢ Huffman Coding: Uses variable-length codes for encoding symbols
based on their frequencies.
Information theory
• Typically one thinks of information as having to do with knowledge.
Gaining information signifies acquiring knowledge that was not there
earlier.
• Gaining information is equivalent to reducing uncertainty.
• If outcome of an event is known with certainty (say with probability
equal to unity), it does not add to the knowledge.
• On the other hand, if the outcome is uncertain, its occurrence adds to
the knowledge.
• Therefore, amount of information I(x) is inverse to probability P(x) of
occurrence of event x.
• we define I(x) = 1/P(x),
Logarithmic Measure of Information
1
• 𝐼 𝑥𝑖 = log 𝑏 = − log 𝑏 𝑃(𝑥𝑖 )
𝑃(𝑥𝑖 )