0% found this document useful (0 votes)
9 views

Image Compression_Unit 4

image compression techniques

Uploaded by

sriramkavi3
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
9 views

Image Compression_Unit 4

image compression techniques

Uploaded by

sriramkavi3
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 34

Image Compression

Unit IV

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Image Compression

• Image compression:
Reduce the number of bytes required to represent a digital image
– Redundant data reduction
– Remove patterns
– Uncorrelated data confirms redundant data elimination

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Image Compression
• Compressions is used in
– FAX
– RPV
– Teleconference
– REMOTE DEMO
– Etc
• Types of compression
– Lossless, lossy

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Image Compression
• Compressions is used in
– FAX
– RPV
– Teleconference
– REMOTE DEMO
– Etc
• Types of compression
– Lossless, lossy

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Image Compression

Data Processing Information

• We want to recover the information, with reduced data volumes.


• Reduce data redundancy.
• How to measure the data redundancy.

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Image Compression
The term data compression refers to the process of reducing the amount of data
required to represent a given quantity of information.
Because various amounts of data can be used to represent the same amount of
information, representations that contain irrelevant or repeated information are
said to contain redundant data.
If we let b and b′ denote the number of bits (or information carrying units) in two
representations of the same information, the relative data redundancy, R, of the
representation with b bits is

where C, commonly called the compression ratio, is defined as

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Types of data redundancy
• Coding redundancy
• Inter pixel redundancy (Spatial and temporal redundancy)
• Psychovisual redundancy

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Coding redundancy

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Coding redundancy

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Inter pixel redundancy
1. All 256 intensities are equally probable. As Fig. 8.2 shows, the histogram of the image is uniform.
2. Because the intensity of each line was selected randomly, its pixels are independent of one another in
the vertical direction.
3. Because the pixels along each line are identical, they are maximally correlated (completely dependent
on one another) in the horizontal direction.
• spatial redundancy that can be eliminated by representing the image as a sequence of run-length
pairs, where each run-length pair specifies the start of a new intensity and the number of consecutive
pixels that have that intensity.

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Inter pixel redundancy
Run Length Coding:

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Psychovisual redundancy
• Some visual characteristics are less important than others.
• In general observers seeks out certain characteristics – edges, textures, etc – and the
mentally combine them to recognize the scene.

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Psychovisual redundancy

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Psychovisual redundancy
FIDELITY CRITERIA
It was noted earlier that the removal of “irrelevant visual” information
involves a loss of real or quantitative image information. Because
information is lost, a means of quantifying the nature of the loss is needed.

Two types of criteria can be used for such an assessment:


(1) objective fidelity criteria, and
(2) subjective fidelity criteria.

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Psychovisual redundancy
objective fidelity criteria:
When information loss can be expressed as a mathematical function of the
input and output of a compression process, it is said to be based on an objective
fidelity criterion.
An example is the root-mean-squared (rms) error between two images.
Let f (x, y) be an input image, and fˆ(x, y) be an approximation of f (x, y) that
results from compressing and subsequently decompressing the input. For any
value of x and y, the error e(x, y) between f (x, y) and fˆ(x, y) is

Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Thursday, November 7, 2024
Psychovisual redundancy

objective
fidelity
criteria:

Thursday, November 7, 2024


Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Psychovisual redundancy
Subjective fidelity criteria:
measuring image quality by the subjective evaluations of people is often more
appropriate. This can be done by presenting a decompressed image to a cross
section of viewers and averaging their evaluations. The evaluations may be made
using an absolute rating scale, or by means of side-by-side comparisons of f (x, y)
and fˆ(x, y).

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Image Compression Models

Run length JPEG Huffman

Thursday, November 7, 2024


Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Image Compression Models

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Huffman Coding
One of the most popular techniques for removing coding redundancy is due to Huffman

For the binary code of Fig.


8.8, a left to-right scan of
the encoded string
010100111100 reveals that
the first valid code word is
01010, which is the code
for symbol a3. The next
valid code is 011, which
corresponds to symbol a1.
Continuing in this manner
reveals the completely
decoded message to be
a3 a1 a2 a2 a6.

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Golomb Coding
the coding of nonnegative integer inputs with exponentially decaying probability distributions. Inputs of this
type can be optimally encoded (in the sense of Shannon’s first theorem) using a family of codes that are
computationally simpler than Huffman codes.

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
arithmetic Coding
Unlike the variable-length codes of the previous two sections, arithmetic coding generates nonblock codes.

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Discuss the need for image compression. Perform Huffman
algorithm for the following intensity distribution, for a 64 X 64
image. Obtain the coding efficiency and compare with that of
uniform length code.

rk 0 1 2 3 4 5 6 7

nk 1008 320 456 686 803 105 417 301

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
LZW Coding
An error-free compression approach that also addresses spatial redundancies in an image. The technique, called
Lempel-Ziv-Welch (LZW) coding, assigns fixed-length code words to variable length sequences of source symbols.

Thursday, November 7, 2024


Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
bit-plane Coding
The run-length and symbol-based techniques of the previous sections can be applied to images with more
than two intensities by individually processing their bit planes. The technique, called bit-plane coding, is
based on the concept of decomposing a multilevel (monochrome or color) image into a series of binary
images and compressing each binary image via one of several well-known binary compression methods.

If a pixel of intensity 127 (01111111) is adjacent to a pixel of intensity 128 (10000000), for instance, every
bit plane will contain a corresponding 0 to 1 (or 1 to 0) transition.
An alternative decomposition approach (which reduces the effect of small intensity variations) is to first
represent the image by an m-bit Gray code. The m-bit Gray code gm−1 … g2g1g0 that corresponds to the
polynomial in Eq. (8-19) can be computed
from

Thursday, November 7, 2024


Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
bit-plane Coding

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
block transform Coding

Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Thursday, November 7, 2024
lossless predictive Coding

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
lossless predictive Coding

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
lossless predictive Coding

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
lossy predictive Coding

Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Thursday, November 7, 2024
lossy predictive Coding

Delta modulation (DM) is a simple but well-known form of lossy predictive coding in which the predictor and quantizer
are defined as

Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Thursday, November 7, 2024
lossy predictive Coding

Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE
Thursday, November 7, 2024
Thank You

Thursday, November 7, 2024 Digital Image Processing (Chapter 4) Dr. N.Radha, Associate Professor, Dept. of ECE

You might also like