CSC566-Tutorial Histogram Equalization
CSC566-Tutorial Histogram Equalization
Week 2
Chapter 4 (Image Enhancement)
QUESTION
Given an image of 8 gray levels (0-7) and of size 8 X 8 is shown below. Perform
histogram equalization on the image.
6 2 7 2 1 7 3 0
2 3 1 1 1 5 5 2
7 6 3 3 3 6 6 7
0 4 4 4 1 3 1 0
4 5 5 5 2 2 2 4
0 7 7 7 5 5 5 0
1 1 3 3 2 2 3 1
7 6 3 3 3 6 6 7
Answers:
Note: You may attach a screen shot (image) of your working solutions or type the
solutions in the blank space provided here.
CSC566/Image Processing
Prepared by: Nur Nabilah Abu Mangshor
Oct 2020
ANSWER:
6 2 7 2 1 7 3 0
2 3 1 1 1 5 5 2
7 6 3 3 3 6 6 7
0 4 4 4 1 3 1 0
4 5 5 5 2 2 2 4
0 7 7 7 5 5 5 0
1 1 3 3 2 2 3 1
7 6 3 3 3 6 6 7
STEP 1
Graylevel 0 1 2 3 4 5 6 7
Histrogram 5 9 9 12 5 8 7 9
STEP 2
Graylevel 0 1 2 3 4 5 6 7
Histrogram 5 9 9 12 5 8 7 9
Normalized 0.08 0.14 0.14 0.19 0.08 0.13 0.11 0.14
STEP 3
Graylevel 0 1 2 3 4 5 6 7
Histrogram 5 9 9 12 5 8 7 9
Normalized 0.08 0.14 0.14 0.19 0.08 0.13 0.11 0.14
Cummulative 0.08 0.22 0.36 0.55 0.63 0.76 0.87 1
STEP 4
Gray level 0 1 2 3 4 5 6 7
Histrogram 5 9 9 12 5 8 7 9
Normalized 0.08 0.14 0.14 0.19 0.08 0.13 0.11 0.14
Cummulative 0.08 0.22 0.36 0.55 0.63 0.76 0.87 1
New gray 20 56 92 140 160 194 221 255
level
CSC566/Image Processing
Prepared by: Nur Nabilah Abu Mangshor
Oct 2020
221 92 255 92 56 255 140 20
92 140 56 56 56 194 194 92
255 221 140 140 140 221 221 255
20 160 160 160 56 140 56 20
160 194 194 194 92 92 92 160
20 255 255 255 194 194 194 20
56 56 140 140 92 92 140 56
255 221 140 140 140 221 221 255
CSC566/Image Processing
Prepared by: Nur Nabilah Abu Mangshor
Oct 2020