Upload
pothipogu-rajasekhar
View
214
Download
0
Embed Size (px)
Citation preview
8/8/2019 28378019 Digital Image Processing 2
1/37
Chapter Two
Digital Image Fundamentals
8/8/2019 28378019 Digital Image Processing 2
2/37
Agenda:
Light and Electromagnetic SpectrumImage Sensing & Acquisition
Image Sampling & quantization
Relationship Between Pixels
8/8/2019 28378019 Digital Image Processing 2
3/37
Electromagnetic Spectrum
Wavelength = c/ (frequency )
Energy = h* frequency
8/8/2019 28378019 Digital Image Processing 2
4/37
Definitions
Monochromatic (achromatic) light: Light that isvoid of color- Attribute: Intensity (amount) .
- Gray level is used to describe monochromatic intensity.
Chromatic light: To describe it, three quantitiesare used:- Radiance: The total amount of energy that flows from the light
source (measured in Watts).
- Luminance: The amount of energy an observer perceives from
a light source (measured in lumens).
- Brightness: A subjective descriptor of light perception that is
impossible to measure (key factor in describing color sensation)
8/8/2019 28378019 Digital Image Processing 2
5/37
Image Sensing & Acquisition
How to transform
illumination energy
into digital images
using sensing
devices
8/8/2019 28378019 Digital Image Processing 2
6/37
Image Sensing & Acquisition
Image Acquisition using single sensor
8/8/2019 28378019 Digital Image Processing 2
7/37
8/8/2019 28378019 Digital Image Processing 2
8/37
8/8/2019 28378019 Digital Image Processing 2
9/37
Image Sampling & quantization
Image Sampling
Continues image
f(x,y) needs to be
in digital form.
Digitizing the
coordinate values
called sampling.
Sampling shouldbe in both
coordinates and
in amplitude.
8/8/2019 28378019 Digital Image Processing 2
10/37
Image Sampling & quantization
Digitizing the Amplitude
values called image
quantization.
Sampling limits
established by no. of
sensors, but quantizationlimits by color levels.
Image Quantization
8/8/2019 28378019 Digital Image Processing 2
11/37
Image Sampling & quantization
Digital Image Representation
Each element called image element, picture
element, or pixel
8/8/2019 28378019 Digital Image Processing 2
12/37
Image Sampling & quantization
8/8/2019 28378019 Digital Image Processing 2
13/37
Image Sampling & quantization
Consider an image which has :
M * N : size of the image
L : Number of discrete gray levels in this image
L= 2k Where k is any positive integer
The total number of bits needed to store this image b :
b = M * N * K,
If M = N, then b= N2 * K
8/8/2019 28378019 Digital Image Processing 2
14/37
Image Sampling & quantization
The dynamic range of an image can be described as:
High dynamic range:
Gray levels span a significant portion of the grayscale.
Low dynamic range:
Dull, washed out gray look.
8/8/2019 28378019 Digital Image Processing 2
15/37
Image Sampling & quantization
Spatial resolution:
- # of samples per unit length or area.
- Lines and distance: Line pairs per unit distance.
Gray level resolution:
- Number of bits per pixel.
- Usually 8 bits.
- Color image has 3 image planes to yield 8 x 3 = 24bits/pixel.
- Too few levels may cause false contour.
8/8/2019 28378019 Digital Image Processing 2
16/37
Image Sampling & quantization
Spatial Image Resolutions
No. of gray levels (K) is constant(8-bits images).
No. of samples (N) is reduced (No. of sensors)
8/8/2019 28378019 Digital Image Processing 2
17/37
Image Sampling & quantization
Comparison between all image sizes
8/8/2019 28378019 Digital Image Processing 2
18/37
Image Sampling & quantization
Gray Level Image Resolutions
No. of samples (N) is constant, but gray levels (K) decreases.
(false contouring)
8/8/2019 28378019 Digital Image Processing 2
19/37
Image Sampling & quantization
Little, Intermediate, and Large amount of details
What is the effect of changing N and K..?
8/8/2019 28378019 Digital Image Processing 2
20/37
Image Sampling & quantization
Isopreference Curve
8/8/2019 28378019 Digital Image Processing 2
21/37
Image Sampling & quantization
Zooming (digital image) can be viewed by
oversampling (continuous image).
1- Creation of new pixel locations
2- Assign a gray level value to this new location
using :
Nearest neighbor interpolation (Pixel replication )
Bilinear interpolation
8/8/2019 28378019 Digital Image Processing 2
22/37
Shrinking (digital image) can be viewed by
undersampling (continuous image).
1- Deletion of row column pixels.
2- Assign a gray level value using :
Nearest neighbor interpolation
Bilinear interpolation
Image Sampling & quantization
8/8/2019 28378019 Digital Image Processing 2
23/37
Image Sampling & quantization
Image Zoomed by 8, 16, 32 usingnearest neighbor interpolation
8/8/2019 28378019 Digital Image Processing 2
24/37
Image Sampling & quantization
Image Zoomed by 8, 16, 32 usingbilinear interpolation
8/8/2019 28378019 Digital Image Processing 2
25/37
Relationship Between Pixels
1- Neighbors of a Pixel:
The 4- neighbors of pixel p are:
N4(p)
The 4- diagonal neighbors are:
ND(p)
The 8-neighbors are :
N8(p)
P
P
P
8/8/2019 28378019 Digital Image Processing 2
26/37
2- Adjacency of Pixel: Two pixels are adjacent if
their values are in the same (binary image).
4-Adjacency:Two pixels p and q with values from V
are 4-adjacent if q is in the setN4(p).
8- Adjacency:Two pixels p and q with values from V
are 8-adjacent if q is in the set N8(p).
Relationship Between Pixels
8/8/2019 28378019 Digital Image Processing 2
27/37
m- Adjacency:Two pixels p and q with values from V arem-adjacent if
- q is in the set N4(p) or
- q is in ND(p) and the set N4(p) N4(q) has no pixels
whose values are from V.
Relationship Between Pixels
8-adjacent, m-adjacent
8/8/2019 28378019 Digital Image Processing 2
28/37
Relationship Between Pixels
Two image area subsets S1 and S2 are
adjacent if some pixel in S1 is adjacent
to some pixel in S2.
8/8/2019 28378019 Digital Image Processing 2
29/37
Relationship Between Pixels
Digitalpath (orcurve):a path from pixel p with
coordinates (x,y) to pixel q with coordinates (s,t) is a
sequence of distinct pixels with coordinates
(x0,y0),(x1,y1),(xn,yn)where (x0,y0) = (x,y) , (xn,yn) = (s,t) and
(xi,yi) is adjacent to (xi-1,yi-1)
n is the length of the path
8/8/2019 28378019 Digital Image Processing 2
30/37
Relationship Between Pixels
we can define 4-,8-, or m-paths depending
on type of adjacency specified.
8-adjacent, m-adjacent
8/8/2019 28378019 Digital Image Processing 2
31/37
Distance Measures
for pixel p, q and z with coordinates
(x,y), (s,t) and (u,v) respectively, D is a distance function or metric if
(a) D(p,q) 0 ; D(p,q) = 0 iff D=q
(b) D(p,q) = D(q,p)
(c) D(p,z) D(p,q) + D(q,z)
Relationship Between Pixels
8/8/2019 28378019 Digital Image Processing 2
32/37
Distance Measures:
1- The Euclidean distance between p and q is
defined as:
Relationship Between Pixels
8/8/2019 28378019 Digital Image Processing 2
33/37
Distance Measures:
2- TheD4distance (city-block distance) between p
and q is defined as:
Relationship Between Pixels
8/8/2019 28378019 Digital Image Processing 2
34/37
Distance Measures:
3- TheD8distance (chessboard distance) between p
and q is defined as
Relationship Between Pixels
8/8/2019 28378019 Digital Image Processing 2
35/37
Distance Measures:
4- TheDmdistance: the shortest m-path between the
points.
Relationship Between Pixels
8/8/2019 28378019 Digital Image Processing 2
36/37
Image Operations on a Pixel Basis
used extensively in most branches of image processing.
Addition : p+q used in image average to reduce noise.
Subtraction : p-q basic tool in medical imaging. Multiplication : pxq
Division : pq
Arithmetic Operation entire images are carried out pixel by pixel.
AND : p AND q (pq)
OR : p OR q (p+q)
COMPLEMENT : NOT q ( ) logic operations apply only to binary images.
arithmetic operations apply to multivalued pixels. logic operations used for tasks such as masking, feature detection, and shape
analysis. logic operations perform pixel by pixel.
8/8/2019 28378019 Digital Image Processing 2
37/37
Linear and Nonlinear Operations
H is a Linear operator if:
H(af + bg) = aH(f) + bH(g)
where a and b are two scalars
f and g are two images