Sie sind auf Seite 1von 17

13-08-15

Lecture By

Harivinod N
Asst Professor
Dept. of Computer Science & Engg.
VCET Puttur

Outline
1.
2.
3.
4.
5.

Relationship Between pixels


Distance Measures
Topological Properties
Image Quality
Noise in Images

Harivinod N | 10CS/IS672 | Digital Image Processing

13-08-15

Basic Relationship b/w pixels


Neighbor of a Pixel
Four neighbor N4(p)
Diagonal neighbor ND(p)
Eight neighbor N8(p)

Adjacency
4-Adjacency
8-adjacency
M-adjacency (Mixed)

Harivinod N | 10CS/IS672 | Digital Image Processing

Adjacency
1. 4-adjacency: Two pixels p and q with values from V are
4-adjacent if q is in the set N4(p).
2. 8-adjacency: Two pixels p and q with values from V are
8-adjacent if q is in the set N8(p).
3. m-adjacency =(mixed)
Two pixels p and q with values from V are m-adjacent if
q is in N4(p) or
q is in ND(p) and the set N4(p) N4(q) has no pixel
whose values are from V (no intersection)

Harivinod N | 10CS/IS672 | Digital Image Processing

13-08-15

Basic Relationship b/w pixels

Harivinod N | 10CS/IS672 | Digital Image Processing

Basic Relationship b/w pixels


Connected Regions/Components
4 connected : Three Components
8 connected : One component

Matlab: bwlabel() function can be used to find the connected components


Harivinod N | 10CS/IS672 | Digital Image Processing

13-08-15

Distance Measures / Metrics

Harivinod N | 10CS/IS672 | Digital Image Processing

Distance Measures / Metrics


p = (x,y)
q = (s,t)
4 3 2 3 4
3 2 1 2 3
2 1 0 1 2
3 2 1 2 3
4 3 2 3 4

2 2 2 2 2
2 1 1 1 2
2 1 0 1 2
2 1 1 1 2
Harivinod N | 10CS/IS672 | Digital Image Processing

2 2 2 2 82

13-08-15

Neighborhood paradox

Harivinod N | 10CS/IS672 | Digital Image Processing

Few Definitions.
Border
Border R is the set of pixels within the region that
have one or more neighbors outside R
inner borders, outer borders exist.

Edge
is a local property of a pixel and its immediate
neighborhood
it is a vector given by a magnitude and direction.
Harivinod N | 10CS/IS672 | Digital Image Processing

10

13-08-15

Edge direction
Direction perpendicular to the gradient direction
which points in the direction of image function
growth.
Border and edge
Border is a global concept related to a region,
Edge expresses local properties of an image.
Crack edges
four crack edges are attached to each pixel, which
are defined by its relation to its 4-neighbors.

Harivinod N | 10CS/IS672 | Digital Image Processing

11

Topological properties
Topological properties of images are invariant to
rubber sheet transformations.
Stretching does not change contiguity of the object
parts and does not change the number of holes in
regions.
One such image property is the Euler-Poincare
characteristic
defined as the difference between the number of
regions and the number of holes in them.
Harivinod N | 10CS/IS672 | Digital Image Processing

12

13-08-15

Topological properties
Convex hull is used to describe topological properties of
objects.
The convex hull is the smallest region which contains the
object, such that any two points of the region can be
connected by a straight line, all points of which belong to
the region.

Harivinod N | 10CS/IS672 | Digital Image Processing

13

Histogram
Brightness histogram provides the frequency
of the brightness values in the image.

Harivinod N | 10CS/IS672 | Digital Image Processing

14

13-08-15

Help Me!!!
Write a fragment of code in any programming
language to compute the histogram of an image I.
Input :
I Image
M x N Size of the image
Output: H Histogram of the image
Method: ???

Harivinod N | 10CS/IS672 | Digital Image Processing

15

Image Quality
An image might be degraded during capture,
transmission, or processing,
Measures of image quality can be used to assess the
degree of degradation.
The quality required naturally depends on the
purpose for which an image is used.
Methods for assessing image quality can be divided
into two categories: subjective and objective.

Harivinod N | 10CS/IS672 | Digital Image Processing

16

13-08-15

Image Quality
Subjective methods
used in television technology,
the ultimate criterion is the perception of a selected
group of professional viewers.
They appraise an image according to a list of criteria
and give appropriate marks.
Objective quantitative Method
the quality of the image I(x, y) is usually estimated by
comparison with a known reference image g(x, y).
A synthesized image is often used for this purpose.
Harivinod N | 10CS/IS672 | Digital Image Processing

17

Noise in images
Images are often degraded by random noise.
Noise can occur during image capture, transmission
or processing,
May be dependent on or independent of image
content.
Noise is usually described by its probabilistic
characteristics.

Harivinod N | 10CS/IS672 | Digital Image Processing

18

13-08-15

Image Noise
Noise happening during image transmission, is
usually independent of the image signal
occurs.
Noise is usually described by its probabilistic
characteristics.

Harivinod N | 10CS/IS672 | Digital Image Processing

19

Noise may be...


Additive, noise v and image signal g are
independent
Multiplicative, noise is a function of signal
magnitude
Impulse noise (saturated = salt and pepper
noise)
Harivinod N | 10CS/IS672 | Digital Image Processing

20

10

13-08-15

Noise in images
Gaussian noise
a very good approximation of noise that occurs in
many practical cases
probability density of the random variable is given
by the Gaussian curve;
1D Gaussian noise - is the mean and is the
standard deviation of the random variable.

Harivinod N | 10CS/IS672 | Digital Image Processing

21

Additive Guassian Noise

Harivinod N | 10CS/IS672 | Digital Image Processing

22

11

13-08-15

Generating Additive, Zero Mean Gaussian Noise

23

Numerical Example
128
128
128
128
128
128
128
128

128
128
128
128
128
128
128
128

128
128
128
128
128
128
128
128

128
128
128
128
128
128
128
128

128
128
128
128
128
128
128
128

128
128
128
128
128
128
128
128

128
128
128
128
128
128
128
128

128
128
128
128
128
128
128
128

2 =1

128
126
128
128
127
129
129
128

128
128
128
129
127
130
128
128

129
128
128
127
128
127
129
130

127
129
129
126
127
129
128
129

129
129
129
129
129
127
128
128

126
128
127
129
127
129
128
127

126
128
127
129
129
130
129
127

128
127
128
128
128
128
129
126

EE465: Introduction to Digital Image


Processing

24

12

13-08-15

Noise in Images
White noise
constant power spectrum (its intensity does not
decrease with increasing frequency);
very crude approximation of image noise

Harivinod N | 10CS/IS672 | Digital Image Processing

25

White noise in 1D Signal


The background noise that is continuously present
on electrical circuits or radio circuits due to the
thermal agitation of electrons.
White noise has a flat power spectral density, which
is to say that it has equal power at any frequency in
any given frequency band.
The term white noise comes from the fact that it is
analogous to white light, which is a combination of
all frequencies or wavelengths in the visible light
spectrum.
Harivinod N | 10CS/IS672 | Digital Image Processing

26

13

13-08-15

Noise in Images
Impulse Noise
saturated (salt and pepper noise)

27

Harivinod N | 10CS/IS672 | Digital Image Processing

Impulse Noise (salt-pepper Noise)


Definition
Each pixel in an image has the probability of p/2 (0<p<1) being
contaminated by either a white dot (salt) or a black dot (pepper)
with probability of p/2

255

Y (i, j ) = 0
X (i, j )

noisy pixels
with probability of p/2
with probability of 1-p

1 i H ,1 j W

clean pixels

X: noise-free image, Y: noisy image

Note: in some applications, noisy pixels are not simply black or white,
which makes the impulse noise removal problem more difficult
EE465: Introduction to Digital Image
Processing

28

14

13-08-15

Numerical Example

P=0.1
128
128
128
128
128
128
128
128
128
128

128
128
128
128
128
128
128
128
128
128

128
128
128
128
128
128
128
128
128
128

128
128
128
128
128
128
128
128
128
128

128
128
128
128
128
128
128
128
128
128

128
128
128
128
128
128
128
128
128
128

128
128
128
128
128
128
128
128
128
128

128
128
128
128
128
128
128
128
128
128

128
128
128
128
128
128
128
128
128
128

128
128
128
128
128
128
128
128
128
128

128
128
128
128
128
128
128
0
128
128

128
128
128
128
128
128
128
128
128
128

255 0 128 128 128 128 128 128


128 128 0 128 128 128 128 0
128 128 128 128 128 128 128 128
0 128 128 128 128 128 128 128
128 128 128 128 128 128 128 128
128 128 128 128 128 128 128 128
128 128 128 128 128 128 128 128
128 128 128 255 128 128 128 128
128 128 128 128 128 128 128 255
128 128 128 128 128 255 128 128

Noise level p=0.1 means that approximately 10% of pixels are contaminated by
salt or pepper noise (highlighted by red color)
EE465: Introduction to Digital Image
Processing

29

Original "Lena" image

Harivinod N | 10CS/IS672 | Digital Image Processing

30

15

13-08-15

Additive Gaussian Noise

Harivinod N | 10CS/IS672 | Digital Image Processing

31

Multiplicative Speckle Noise

Harivinod N | 10CS/IS672 | Digital Image Processing

32

16

13-08-15

Thank You

Harivinod N | 10CS/IS672 | Digital Image Processing

33

17

Das könnte Ihnen auch gefallen