0% found this document useful (0 votes)
15 views43 pages

Lecture 4S

This document discusses point processing techniques for image enhancement, including negative images, thresholding, logarithmic transformations, and power law transforms. Point processing involves applying a transformation function to each pixel independently to map input pixel values to output values. Examples are provided to demonstrate how these techniques can enhance images by increasing contrast or emphasizing certain intensity levels.

Uploaded by

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

Lecture 4S

This document discusses point processing techniques for image enhancement, including negative images, thresholding, logarithmic transformations, and power law transforms. Point processing involves applying a transformation function to each pixel independently to map input pixel values to output values. Examples are provided to demonstrate how these techniques can enhance images by increasing contrast or emphasizing certain intensity levels.

Uploaded by

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

Digital Image

Processing
Image Enhancement
Point Processing
Instructor Name
Dr. Abida Sharif
Material Reference

Images and Material


From
Rafael C. Gonzalez and Richard E. Wood,
Digital Image Processing, 2nd Edition.& Internet Resources
2
Contents
In this lecture we will look at image enhancement point
processing techniques:
 Recap
 What is point processing?
 Negative images
 Thresholding
 Logarithmic transformation
 Power law transforms
 Grey level slicing
 Bit plane slicing 3
Basic Spatial Domain Image Enhancement

Most spatial domain enhancement operations can be reduced


to the form
 g (x, y) = T[ f (x, y)] Origin x

 where f (x, y) is the


input image, g (x, y) is
the processed image
and T is some (x, y)
operator defined over
some neighbourhood
of (x, y)
y Image f (x, y)
4
Point Processing
 The simplest spatial domain operations occur when the
neighbourhood is simply the pixel itself
 In this case T is referred to as a grey level transformation
function or a point processing operation
 Point processing operations take the form
s=T(r)
 where s refers to the processed image pixel value and r
refers to the original image pixel value

5
Point Processing Example: Negative Images
 Negative images are useful for enhancing white or grey
detail embedded in dark regions of an image
 Note how much clearer the tisue is in the negative image

6
Point Processing Example: Negative Images (cont.…)

Original Image x Enhanced Image x


110112125 82 97 47 120
17
16 10 12 89 75 96 74
49 41 48 89 52 74 12
85 87 25 32 85 96 12
87 65 85 54 25 26 23
74 58 54 87 75 26 85
89 65 85 32 85 96 57
y Image f (x, y)
y Image f (x, y)

s = intensitymax - r
7
Point Processing Example:
Thresholding
 Thresholding transformations are particularly useful
for segmentation in which we want to isolate an object
of interest from a background

1.0 r > threshold


s=
0.0 r <= threshold

8
Point Processing Example: Thresholding (cont.…)

Original Image x Enhanced Image x


225 125 255 178 65 85 120 1 1 1 0 0 1
216 250 208 168 25 100 114 1 1
155 225 112 204 96 69 78
165 216 168 56 165 65 25
125 245 85 85 84 25 75
24 63 25 65 58 74 69
54 125 85 47 74 98 60
y Image f (x, y) y Image f (x, y)

1.0 r > threshold


s=
0.0 r <= threshold
9
Basic Grey Level Transformations
There are many different kinds of grey level
transformations
Three of the most common
are shown here
 Linear
Negative/Identity
 Logarithmic
Log/Inverse log
 Power law
nth power/nth root
10
Logarithmic Transformations
 The general form of the log transformation is
s = c * log(1 + r)
 The log transformation maps a narrow range of low input
grey level values into a wider range of output values
 The inverse log transformation performs the opposite
transformation

11
Logarithmic Transformations (cont.…)
 Log functions are particularly useful when the input grey
level values may have an extremely large range of values
 In the following example the Fourier transform of an
image is put through a log transform to reveal more detail

s = log(1 + r)

12
Logarithmic Transformations (cont.…)
Original Image Enhanced Image x
x
110 120 92
91 94 98
90 91 99

y Image f (x, y) y Image f (x, y)

s = c*log(1 + r)
 We usually set c to 1
 Grey levels must be in the range [0.0, 1.0]
13
Power Law Transformations
 Power law transformations have the following form
s=c*rγ
 Map a narrow range
of dark input values
into a wider range of
output values or vice
versa
 Varying γ gives a whole
family of curves

14
Power Law Transformations (cont.…)
Original Image x Enhanced Image x

y Image f (x, y)
y Image f (x, y)

s = c.r γ
 We usually set c to 1
 Grey levels must be in the range [0.0, 1.0]
15
Power Law Example

16
Power Law Example (cont.…)

γ = 0.6
1
0.9
0.8
Transformed Intensities

0.7
0.6
0.5
0.4
0.3
0.2
0.1
0
0 0.2 0.4 0.6 0.8 1
Old Intensities

17
Power Law Example (cont.…)

γ = 0.4
1
0.9
Transformed Intensities

0.8
0.7
0.6
0.5
0.4
0.3
0.2
0.1
0
0 0.2 0.4 0.6 0.8 1
Original Intensities

18
Power Law Example (cont.…)

γ = 0.3
1
0.9
Transformed Intensities

0.8
0.7
0.6
0.5
0.4
0.3
0.2
0.1
0
0 0.2 0.4 0.6 0.8 1
Original Intensities

19
Power Law Example (cont.…)

 The images to the


right show a s = r 0.6
magnetic resonance
(MR) image of a
fractured human
spine s=

s = r 0.4
r 0 .3
 Different curves
highlight different
detail

20
Power Law Example

21
Power Law Example (cont.…)

γ = 5.0
1
0.9
Transformed Intensities

0.8
0.7
0.6
0.5
0.4
0.3
0.2
0.1
0
0 0.2 0.4 0.6 0.8 1
Original Intensities

22
Power Law Transformations (cont.…)
 An aerial photo
of a runway is
shown
 This time s = r 3.0
power law
transforms are
used to darken s=

s = r 4.0
r
the image 5 .0

 Different curves
highlight
different detail

23
Gamma Correction
 Many of you might be familiar with gamma correction
of computer monitors
 Problem is that
display devices do
not respond linearly
to different
intensities
 Can be corrected
using a log
transform

24
More Contrast Issues

25
Piecewise Linear Transformation Functions
 Rather than using a well defined mathematical function
we can use arbitrary user-defined transforms
 The images below show a contrast stretching linear
transform to add contrast to a poor quality image

26
Gary Level Slicing
 Highlights a specific range of grey levels
 Similar to thresholding
 Other levels can be
suppressed or maintained
 Useful for highlighting features
in an image

27
Bit Plane Slicing
Often by isolating particular bits of the pixel values in an
image we can highlight interesting aspects of that image
 Higher-order bits usually contain most of the significant
visual information
 Lower-order bits contain
subtle details

28
Bit Plane Slicing (cont.…)

[10000000] [01000000]

[00100000] [00001000]

[00000100] [00000001]

29
Bit Plane Slicing (cont.…)

30
Bit Plane Slicing (cont.…)

31
Bit Plane Slicing (cont.…)

32
Bit Plane Slicing (cont.…)

33
Bit Plane Slicing (cont.…)

34
Bit Plane Slicing (cont.…)

35
Bit Plane Slicing (cont.…)

36
Bit Plane Slicing (cont.…)

37
Bit Plane Slicing (cont.…)

38
Bit Plane Slicing (cont.…)

39
Bit Plane Slicing (cont.…)
Reconstructed image
using only bit planes 8
and 7

Reconstructed image
using only bit planes 8, 7
and 6

Reconstructed image
using only bit planes 7, 6
and 5
40
Summary
 We have looked at different kinds of point processing
image enhancement
 Next time we will start to look at neighbourhood
operations – in particular filtering and convolution

41
Next Lecture
 Neighbourhood operations
 What is spatial filtering?
 Smoothing operations
 What happens at the edges?
 Correlation and convolution

42
THANK YOU

43

You might also like