Title: Text Extraction from Name Cards Using Neural Network Lin Lin and Chew Lim Tan School of Computing, N
1Text Extraction from Name Cards Using Neural
NetworkLin Lin and Chew Lim TanSchool of
Computing, National University of Singapore
- Proposal
- Name card scanners use OCR technology to
build name card database. They can not achieve
the best recognition rates because the following
difficulties coming from the fancy designed name
cards - Large variation of text sizes
- Graphical foregrounds mixing with texts
- Fanciful color designs for different text lines.
- This paper is trying to use a Neural
Network based method to extract text from those
name card images with the difficulties addressed
above. Figure 1 shows an example of the name card
image.
- Edge detection Canny edge detector is
used with a percentage threshold 0.8 to identify
the conventional high and low threshold. In this
way, the threshold varies dynamically based on
the text and background color. - Local contour characteristics analysis
Analyze the pixels besides a Canny edge contour.
Use the histogram of the pixel values to compute
the color averages and variances of inner pixels,
outer pixels, and all pixels respectively. Three
images in Figure 2 show contours of clear object
small object or object on graphical background
graphical object. Width and height of the contour
will be collected as local characteristics as
well. - Figure 2. Typical types of contour histograms
- Relative contours alignment analysis
Calculate the alignment information base on the
neighboring contours' color information. - 1. Define similarity function based on a feature
F of two contours - 2. Define the relative similarity information of
two contours in X direction as - Since only similar sized and well
aligned neighboring contours are meanful to C1,
RSIM(X) will only have value when C2 satisfied
following - 1/2 lt sizeX(C1) / sizeX(C2) lt 2
- top(C1) lt (top(C2)bottom(C2))/2 lt bottom(C2).
- RSIM(Y) is defined similarly. Then the
total relative alignment information of C1 on a
feature F be the sum of relative similarities of
all other contours in both X and Y direction.
There are 6 relative aligned color parameters
corresponding to 6 local color parameters.
Contour classification using Neural
Network 14 parameters are collected for Neural
Network analysis including the local and relative
parameters. Back-propagation Neural Network is
ideal to handle this nonelinear relationship
between large number of features. 14 input notes,
20 hidden notes and one output notes form the
three layer of the Neural Network, which is shown
in Figure 3 Figure 3. Neural Network
Layout Text area binarization Based on
the classification result from previous step and
the color information from first step, we can
binarize the text area without any difficulty.
Figure 4 show the classification result and
binarized image. Figure 4. Classification
and binarization result Results and
Conclusion Totally 250 name card images, 20 for
Neural Network training, 80 for testing. Based
on the number of correct binarized text lines,
the recall rate is 89 and the precision rate is
84. Contours make feature extraction straight
and easy. Neural Network makes this method robust
for other types of images rather than just name
card images. Although we work on gray-scale
images, this method adapts to color images as
well. Further work can be done in improving the
edge detection method to extract more proper
contours. More work can be done on applying the
method on other types of images such as book
covers, pamphlets and posters to investigate its
adaptabilities.