Text Detection From Images
Text Detection From Images
Character Recognition
from Images
1
Contents
1 Introduction
2 Literature review
3 Method Used
5 Future works
2
Aims and objectives
Student 2
Recognition -
Segmentation - Recognize each
Separate the of the character
text region into in the detected
its individual text region
characters. using a suitable
algorithm
4
Problem statement
5
Literature review
Segmentation
1. Klouver in research on recognition text in PayPal HIP [1] proposed the use
of vertical projection to segment the characters in images. There are
several reasons vertical segmentation been proposed by Klouver :
• PayPal HIP image is computer generated only minor preprocessing
needed.
• There are obvious separation between each character
• Character size in PayPal HIP is fixed
6
Literature review
Recognition
7
Literature review
Recognition
8
Literature review
Recognition
Jared Hopkins and Tim Anderson in [9], used Fourier Descriptor to recognize
text in image. In most of the researches, Fourier descriptor been used to
recognize more complex shape such as for logo classification by Folkers and
Samet [10] and for Sinhala Script by Rohana, Ruvan and Kevin [11].
Basically there are no research on LPR using Fourier descriptor(FD), hence, this
research will also test the usage of FD to recognize text in Malaysian License
Plate.
Check
Template.mat
Make template
Noise Removal
Preprocess
Erode
Profiler
Select
Segmentation
Single row plate
segment2 Segment
Classify
Recognition
Corrector
End
10
Make template
…
…
Matrix size 24 X 42 X 36
Saved as template.mat
36 images of characters
Size = 42 X 24
11
Preprocess
Raw image
Noise filter
Binarize
Complimenting
Baunding
Resizing
Preprocessed
image
12
Segmentation – Vertical Projections
Preprocessed Image
Vertical projection analysis
Segmented Image
Vertical Projection
13
Segmentation – Vertical Projections
Weaknesses
14
Segmentation – Connected Components
The segmentation character involves the
following steps:
15
Recognition - Pixel Counting
tempSum = sum(sum(templates(:,:,j)));
inSum = sum(sum(chars(:,:,i)));
allCorrs(j) = abs(tempSum - inSum);
allCorrs(j) = 1 - (allCorrs(j)/1008);
16
Corr2
Where is the mean of the input matrix i and is the
mean of the input matrix j.
0<r<1
1 mean i and j is exactly same while 0 mean the
i and j not same at all.
17
Recognition - Vertical projections
tempVP = sum(templates(:,:,j));
inVP = sum(chars(:,:,i));
allCorrs(j) = corr2(tempVP, inVP);
Vertical
Projection
18
Recognition - Horizontal projections
tempHP = sum(templates(:,:,j)');
inHP = sum(chars(:,:,i)');
allCorrs(j) = corr2(tempHP, inHP);
Horizontal
Projection
19
Recognition - Template Correlations
temp = templates(:,:,j);
in = chars(:,:,i);
allCorrs(j) = corr2(temp, in);
image
20
Recognition – Fourier Descriptor
𝑥0 𝑦0
( )
𝑥1 𝑦1
~ .
U=
.
.
𝑥𝑛 𝑦𝑛
21
Recognition – Fourier Descriptor
2. Extracting FD – 1 D Discrete Fourier Transform
(DFT) been done to the complex vector to get the
frequency domain of the boundaries using the
following equation:
𝑁 −1
~ ~ ~ 2π
( )
F =𝐹𝐹𝑇 [ 𝑈 ]= ∑ U k − 𝑘 𝜇
𝑘 =0 N
22
Recognition – Fourier Descriptor
3. Normalize FD :
Translation invariant
Scale invariant
Rotation invariant
23
Recognition – Fourier Descriptor
CompareFD(I,T)
D ←ø
for each Templates T
do diff = -1
if length = length (I)
do diff ← sum ()
return k such that
25
Recognition – Heuristic Filter
Context Approach
26
Recognition – Heuristic Filter
Euler number - Euler number is equal to the number of connected
elements (always equal to one) minus the number of holes.
27
Recognition – Heuristic Filter
28
Experiment 1: Comparison between Different Segmentation Method and
Different Templates Matching Classifier
29
Experiment 1: Comparison between Different Segmentation Method
and Different Templates Matching Classifier
Where is average recognition time, total running time to recognize all sample images
and is number of sample images.
30
Experiment 1: Comparison between Different Segmentation Method
and Different Templates Matching Classifier
31
Result
Comparison on segmentation by Vertical Projection and Connected Components
125
125 125
125
76 125
76 125
60.80% 100%
60.80% 100%
32
Experiment 2: Comparison between Template Correlation and Fourier
Descriptor
33
Result
0.4704 6.0175
78.35% 52.32%
34
Experiment 3: Improvement on LPR Using Context Approach
Result
Comparison on recognition by Templates Correlation after context been introduced
0.4704
0.4704 0.4419
0.4419
78.35% 90.08%
78.35% 90.08%
35
Experiment 4: Improvement on LPR Using Hybrid method
Result
Comparison on recognition by Templates Correlation after hybrid been introduced
0.4704
0.4704 0.4419
0.4419 0.8494
0.8494
36
Discussion
Image that failed to be segmented using connected components
Image
Original image
Preprocessed
image
Segmented image
37
Why heuristic filters failed ?
38
Why Fourier Descriptors failed ?
39
Conclusion
40
References
[1] Kurt Alfred Kluever. (2008) Digital Media Library : RIT Scholars. [Online]. https://
ritdml.rit.edu/bitstream/handle/1850/7813/KKlueverTechPaper05-20-2008.pdf
[3] Sheroz Khan, Rafiqul Islam Othman khalifa, "Malaysian Vehicle License Plate
Recognition," The International Arab Journal of Information Technology , pp. 359-364,
2007.
[4] Velappa Ganapathy and Wen Lik Dennis Lui, "A Malaysian Vehicle License Plate
Localization and Recognition System," Monash University Malaysia,.
[5] Office of Safety and Traffic, Operations Research and Development, USA. (2010,
February) Literature Review : Artificial Neural Network. [Online]. http://
www.tfhrc.gov/safety/98133/ch02/body_ch02_05.html
41
References
[7] K. Saleh Ali Al-Omari, Putra Sumari, A. Sadik Al-Taweel, and J.A. Anas Hussain, "Digital
Recognition using Neural Network," Journal of Computer Science, vol. 5, no. 6, pp. 427-434, 2009.
[8] Velappa Ganapathy and Leong Liew Kok, "Handwritten Character Recognition Using
Multiscale Neural Network Training Technique," World Academy of Science, Engineering and
Technology, vol. 39, 2008.
[9] Jared Hopskins and Tim Anderson, "A Fourier Descriptor Based Character Recognition Engine
Implemented under the GameraOpen-Source Document Processing Framework," No Date.
[10] Andre Folkers and Samet Hanan, "Content-based Image Retrieval Using Fourier Descriptors
on a Logo Database," in Proc of the 16th Int. Conf. on Pattern Recognition, vol. III, Quebec City,
Canada, 2002, pp. 521-524.
[11] Rajapakse K Rohana, Ruvan A Weerasinghe, and Kevin E Seneviratne, "A Neural Network
Based Character Recognition System For Sinhala Script," Department of Statistics and Computer
Science, University of Colombo, Colombo, No Date.
[12] Wisam Al Faqheri and Syamsiah Mashohor, "A Real-Time Malaysian Automatic License Plate
Recognition (M-ALPR) using Hybrid Fuzzy," IJCSNS International Journal of Computer Science
and Network Security, vol. VOL.9, no. No.2, pp. 333-340, February 2009.
42
43