Top Banner
A. Campilho and M. Kamel (Eds.): ICIAR 2008, LNCS 5112, pp. 587–596, 2008. © Springer-Verlag Berlin Heidelberg 2008 Text Particles Multi-band Fusion for Robust Text Detection Pengfei Xu, Rongrong Ji, Hongxun Yao, Xiaoshuai Sun, Tianqiang Liu, and Xianming Liu School of Computer Science and Engineering Harbin Institute of Technology P.O. BOX 321, West Dazhi Street, Harbin, 150001, China {pfxu,rrji,yhx,xssun,tqliu,liuxianming}@vilab.hit.edu.cn Abstract. Texts in images and videos usually carry important information for visual content understanding and retrieval. Two main restrictions exist in the state-of-the-art text detection algorithms: weak contrast and text-background variance. This paper presents a robust text detection method based on text parti- cles (TP) multi-band fusion to solve there problems. Firstly, text particles are generated by their local binary pattern of pyramid Haar wavelet coefficients in YUV color space. It preserves and uniforms text-background contrasts while extracting multi-band information. Secondly, the candidate text regions are generated via density-based text particle multi-band fusion, and the LHBP his- togram analysis is utilized to remove non-text regions. Our TP-based detection framework can robustly locate text regions regardless of diversity sizes, colors, rotations, illuminations and text-background contrasts. Experiment results on ICDAR 03 over the existing methods demonstrate the robustness and effective- ness of the proposed method. Keywords: text detection, text particle, multi-band fusion, local binary pattern, LHBP. 1 Introduction Recent years, there is a hot topic about the multimedia content analysis, retrieval and annotation [1-9]. Comparing with other visual contents, text information extracted from images/videos is near to its high-level semantic cues. Text detection aims at localizing text regions within images/videos via visual content analysis. Generally speaking, there are three approaches: 1). edge based method [2, 3], in which edge detection is conducted and followed by text/non-text classifier such as SVM [2] or neural network [3]. 2). connected component (CC) based method [4-5], in which connected component of text regions are detected and extracted as descriptors, which are simple to implement for text localization. 3). texture based method [6-8], which usually involves wavelet decomposition and learning-based post classification. Texture based method has been demonstrated to be robust and effective whether in literature [6-8] or in ICDAR 03/05 text detection competition. In our former works [8], we extend Local Haar Binary Patterns (LHBP) based on the wavelet energy fea- ture. The method get well performance then wavelet method [7], but the threshold
10

Text Particles Multi-band Fusion for Robust Text Detection Particles Multi-Band... · Text Particles Multi-band Fusion for Robust Text Detection 589 fusion is used to enhance the

May 14, 2020

Download

Documents

dariahiddleston
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Text Particles Multi-band Fusion for Robust Text Detection Particles Multi-Band... · Text Particles Multi-band Fusion for Robust Text Detection 589 fusion is used to enhance the

A. Campilho and M. Kamel (Eds.): ICIAR 2008, LNCS 5112, pp. 587–596, 2008. © Springer-Verlag Berlin Heidelberg 2008

Text Particles Multi-band Fusion for Robust Text Detection

Pengfei Xu, Rongrong Ji, Hongxun Yao, Xiaoshuai Sun, Tianqiang Liu, and Xianming Liu

School of Computer Science and Engineering Harbin Institute of Technology P.O. BOX 321, West Dazhi Street, Harbin, 150001, China

{pfxu,rrji,yhx,xssun,tqliu,liuxianming}@vilab.hit.edu.cn

Abstract. Texts in images and videos usually carry important information for visual content understanding and retrieval. Two main restrictions exist in the state-of-the-art text detection algorithms: weak contrast and text-background variance. This paper presents a robust text detection method based on text parti-cles (TP) multi-band fusion to solve there problems. Firstly, text particles are generated by their local binary pattern of pyramid Haar wavelet coefficients in YUV color space. It preserves and uniforms text-background contrasts while extracting multi-band information. Secondly, the candidate text regions are generated via density-based text particle multi-band fusion, and the LHBP his-togram analysis is utilized to remove non-text regions. Our TP-based detection framework can robustly locate text regions regardless of diversity sizes, colors, rotations, illuminations and text-background contrasts. Experiment results on ICDAR 03 over the existing methods demonstrate the robustness and effective-ness of the proposed method.

Keywords: text detection, text particle, multi-band fusion, local binary pattern, LHBP.

1 Introduction

Recent years, there is a hot topic about the multimedia content analysis, retrieval and annotation [1-9]. Comparing with other visual contents, text information extracted from images/videos is near to its high-level semantic cues. Text detection aims at localizing text regions within images/videos via visual content analysis. Generally speaking, there are three approaches: 1). edge based method [2, 3], in which edge detection is conducted and followed by text/non-text classifier such as SVM [2] or neural network [3]. 2). connected component (CC) based method [4-5], in which connected component of text regions are detected and extracted as descriptors, which are simple to implement for text localization. 3). texture based method [6-8], which usually involves wavelet decomposition and learning-based post classification.

Texture based method has been demonstrated to be robust and effective whether in literature [6-8] or in ICDAR 03/05 text detection competition. In our former works [8], we extend Local Haar Binary Patterns (LHBP) based on the wavelet energy fea-ture. The method get well performance then wavelet method [7], but the threshold

Page 2: Text Particles Multi-band Fusion for Robust Text Detection Particles Multi-Band... · Text Particles Multi-band Fusion for Robust Text Detection 589 fusion is used to enhance the

588 P. Xu et al.

strategy cannot get well always. It doesn’t consider the color information while only extracting the texture feature from the gray-band. When the luminance of foreground is similar to background but different colors, its performance is very poor.

In the state-of-the-art methods [2-8], two problems are not well solved, which strictly restrict text detection performance of the text detection algorithms in real-world applications:

1. Problem of the weak contrast: Although localized thresholds can uniform differ-ent texture changes [7], its performance is poor when the text-background contrast is low. When the text region is similar to background (Fig. 1 (a)), it is difficult to get high performance using either color or texture threshold based methods [4-8] due to the low contrast.

2. Problem of the text-background variance: In text regions, the background varia-tion strongly affects the feature extraction and text region detection. Former methods [2-3, 6-8] extract features according to the gray-level information of each image, which are strongly affected by the background variation, especially when the scene image is over exposed (Fig. 1 (b)).

(a) (b)

Fig. 1. (a) Weak contrast between text and background. (b) Text-background variance.

This paper addresses the above-mentioned problems by a unified solution. We pro-pose a Text Particle (TP) descriptor to represent local texture features, which are extracted from the local binary pattern in Haar coefficients. The descriptor can detect text regions while ignoring their variations in scale, illumination uniformity, rotation and the contrast degree between the foreground and the background. Then, multi-band

Fig. 2. Text particles multi-band fusion framework

Page 3: Text Particles Multi-band Fusion for Robust Text Detection Particles Multi-Band... · Text Particles Multi-band Fusion for Robust Text Detection 589 fusion is used to enhance the

Text Particles Multi-band Fusion for Robust Text Detection 589

fusion is used to enhance the performance in detection, and post-processing, with LHBP histogram analysis, removes some non-text regions which are similar to text-region. Fig. 2 presents the proposed text detection framework.

The rest of this paper is organized as follows: In section 2, we give a description about the TP text descriptor. Section 3 presents our multi-band fusion strategy based on TP density evaluation and LHBP histogram analysis. Section 4 shows the experi-ment comparisons between the proposed method and some state-of-the-art text detec-tion methods. Finally, this paper concludes and discusses our future research direction.

2 Text Particles Based on Local Haar Binary Patterns

We first describe the two key elements in proposed method, the local Haar binary patterns (LHBP) (subsection 2.1) and direction analyze of text region (subsection 2.2). Then, we explain how to utilize there elements to obtain the Text Particle detec-tor in subsection 2.3.

2.1 Local Haar Binary Patterns (LHBP)

Proposed by Ojala [10-11], local binary patterns (LBP) is a robust texture descriptor, which is used in video surveillance and face recognition [12-13]. LBP extracted the changes from local neighbors of each pixel and itself, thus, LBP holds not only trans-lation and rotation invariant, but also illumination invariant.

We utilize LBP to work out illumination variance in text regions. For each pixel (xc, yc) in a given image, we conduct the binary conversion between (xc, yc) and its 8-neighborhood pixels as following:

1 ( , ) - ( , ) 0( )

0 ( , ) - ( , ) 0c c p p

c c p p

f x y f x yS x

f x y f x y

≥⎧= ⎨ <⎩

. (1)

where f(xp, yp) is the value of pth 8-neighborhood pixel (p=0…7); and f(xc, yc) is the value of the center pixel.

Subsequently, a mask template (Fig.3 (b)) valued 2p is adopted to calculate the LBP value of this center pixel (xc, yc) as below:

( )( ) ( ) ( )( )7

0

, , - , 2 pc c p p c c

p

LBP f x y S f x y f x y=

=∑ . (2)

where 1 0( )

0 0

xS x

x

≥⎧= ⎨ <⎩

(a) (b) (c) (d)

Fig. 3. (a) the neighbor sequence; (b) a weighted mask; (c) an example; (d) the LBP pattern of (c), its value is 193

Page 4: Text Particles Multi-band Fusion for Robust Text Detection Particles Multi-Band... · Text Particles Multi-band Fusion for Robust Text Detection 589 fusion is used to enhance the

590 P. Xu et al.

We developed the local binary patterns (LBP) on the energy of high-frequency co-efficients in pyramid Haar wavelet transformation domain to represent the multi-scale feature of images. The 8-neighborhood LBP code is employed at LH, HL and HH bands, named local Haar binary patterns (LHBP). Especially, a threshold criterion is adopted to filter gradual illumination variance:

( )( ) ( ) ( )( )7

0

, , - , 2 pc c Haar p p Haar c c

p

LHBP f x y S f x y f x y=

=∑ . (3)

where 1 ( )

0

x ThresholdS x

x Threshold

≥⎧= ⎨ <⎩

Compared with traditional texture descriptor based on wavelet energy, LHBP is a threshold-restricted directional coding of pyramid Haar in regardless of direction variation values, and it can normalize the illumination variance to text and back-ground in scene images. This is a noticeable advantage of LHBP.

2.2 Direction Analyze of Text Region

Compared with non-text regions, text regions have more significant texture distribu-tion at there directions: horizontal, vertical, diagonal and anti-diagonal. The strokes of letters usually have two or more above-mentioned directions. The directional distribu-tion of common letters can be calculated, including capital letters, small letters and Arabic numbers as depicted in Table.1. The results in Table.1 demonstrate directional relativity of two or more direction of letters’ strokes.

Table 1. Directional relativity of letters’ strokes

relativity of strokes’ direction Common letters

horizontal, vertical B C D E F G H J L O P Q R S T U a b c d e f g h j m n o p q r s t u 0 2 3 4 5 6 8 9

horizontal, diagonal A Z z 7 horizontal, anti-diagonal A vertical, diagonal K M N Y k 4 vertical, anti-diagonal K M N R Y diagonal, anti-diagonal A K M V W X Y k v w x y

The relationships between LHBP coding and the directions of texture are depicted

as Directional Texture Coding Table (DTCT) in Table.2. For example, the LHBP coding in Fig.3 (d) is corresponding to the texture pattern in Fig.3(c).

Table 2. Directional Texture Coding Table of LHBP (DTCT)

Direction of texture LBP code Horizontal 7, 112, 119 vertical 28, 193, 221 diagonal 4, 14, 64, 224 anti-diagonal 1, 16, 56, 131

Page 5: Text Particles Multi-band Fusion for Robust Text Detection Particles Multi-Band... · Text Particles Multi-band Fusion for Robust Text Detection 589 fusion is used to enhance the

Text Particles Multi-band Fusion for Robust Text Detection 591

2.3 Text Particles Based on Directional LHBP

As mentioned in section 2.2, text regions have significant texture at some directions, and the value of LHBP can show their texture patterns. We will propose a novel text region descriptor in this section, which combines both the directional texture distrib-uting of text regions and the directional character of LHBP coding.

First, a window-constrained detection template (size n×n) is convoluted over each band and scale of LHBP image. The special texture value is calculated using Eq.4.

( , )n/2-1 n/2-1

d d(i, j) (i, j)

k=-n/2 l=-n/2

DirThreshold = DirTexture k l∑ ∑ . (4)

where ( , )

1, ( , )

0, ( , )

ddi j d

LHBP i k j l DTCTDirTexture

LHBP i k j l DTCT

⎧ + + ∈= ⎨

+ + ∉⎩

In Eq.4, d is from 1 to 4 which map to the four directions: horizontal, vertical, di-agonal and anti-diagonal, DirTextured

(i,j) describes the direction in DTCT of pixel (i, j) and its neighborhoods within the detection window template (n×n), and LHBP(x, y) is the value of LHBP image.

We adopt the threshold criterions Td at dth direction in Eq.5 and Eq.6.

3

0

( )d

DirFlag Flag d=

=∑ . (5)

where 1,( )

0,

d DirThreshold TFlag d

other

⎧ ≥= ⎨⎩

, 2

,

True DirFlagDirFiler

Flase other

≥⎧= ⎨⎩

. (6)

In Eq.6, if the DirFiler is True, the region is marked as candidate text region (size (n×n), this processing is called Text Particles (TP)).TP makes full use of LHBP and texture direction of text regions. We adopt the LHBP to present the texture in multi-band of YUV color space, and it is effective when illumination, contrast and size are diverse (Fig.4).

3 Fusion Candidate Text Region

3.1 Fusion Strategy

At this section, we describe our TP multi-band fusion strategy to refine candidate text regions based on TP density. With the TPs on every band and scale, the fusion based on TP density aims at combining all of them to obtain more expressive features of text regions.

Page 6: Text Particles Multi-band Fusion for Robust Text Detection Particles Multi-Band... · Text Particles Multi-band Fusion for Robust Text Detection 589 fusion is used to enhance the

592 P. Xu et al.

Firstly, we propose the TP density to evaluate the tightness distribution of TP in the area. We calculate the value by density estimation of each TP point as a discrete approximation. The TP density of a detection area T in ith scale on jth band is defined as:

2( )

0

1( ) k

nd x x

ijk

D T en

− −

=

= ∑ . (7)

where n is the total number of TPs in the detection area T, x is the center of T, xk is the kth point in T, d(x-xk) is the original L2 distance between xk and x, and wk is the weight which is proportional to kth TP’s area.

In order to full consideration about the results at different scales on different bands, we weighted merge densities, in which the density value is calculated as Eq.8:

3

1

( ) ( )M

ij iji m j

F T w D T= =

= ×∑∑ . (8)

where the weight wij represents the confidence rate to ith scale of jth band, m and M are the minimum and maximum scales of the wavelet transform on every band.

However, compared with all bands, it is more expressive to use only one band when other ones have weak performance, such as the V band performance is low when the text color is similar as background color (Fig. 1(a)). We define the TP den-sity at jth band as:

( ) ( )M

j i iji m

F T w D T=

= ×∑

. (9)

where 1 M

j iji m

w wM m =

=− ∑

Then we employ the density criterion Ts on the same region T at all scales of all bands, and density criterion Td at the same scale of all bands. At last, we mark the area T as candidate text region, if it satisfies the Ts at all scales of all bands or Td at same scale of all bands.

s i dTure if F(T) T or F(T) TR(T )

Flase else

≥ ≥⎧= ⎨⎩

. (10)

Generally speaking, the fusion strategy fuses the TPs from all bands and scales to achieve effective location on candidate text regions. As a result, it can perform more accurate on text region detection (Fig. 4).

3.2 Post-processing Based on LHBP Histogram

We discover that the accumulation histograms of non-text regions are much different from text regions. We divide the detected regions (including text regions and non-text regions) into four blocks and calculate the accumulation histogram of LHBP which has 256 bins on every block for texture analysis. Then, we calculate the texture through their 4-blocks’ weighted histogram difference to remove the non-text regions.

Page 7: Text Particles Multi-band Fusion for Robust Text Detection Particles Multi-Band... · Text Particles Multi-band Fusion for Robust Text Detection 589 fusion is used to enhance the

Text Particles Multi-band Fusion for Robust Text Detection 593

(a) (b) (c) (d)

Fig. 4. The results of wavelet based method [7] (a, c) and TP multi-band fusion based method (b, d)

4 Experiment

4.1 Datasets and Evaluation

We evaluate our proposed method on the Location Detection Database of ICDAR 03 Robust Reading Competition Set [14]. The dataset contains 258 training images and 249 validation images which contain 1107 text regions. We use the validation dataset for testing. Each test image contains one or more text lines. The detection task re-quires to automatically locating text lines in every test image.

The results of the different methods are evaluated with the recall, precision and f, which are the same to ICDAR2003 competition [14]. The recall(r) and the precision (p) are defined as follows:

( , )

| |p ere E

m r Tp

E∈= ∑ . (11)

( , )

| |p trt E

m r Er

T∈= ∑ . (12)

where ( , ) max ( , ') | 'pm r R m r r r R= ∈ , mp is the match between two rectangles as

the area of intersection divided by the area of the minimum bounding box containing both rectangles, E is the set of detection results and T is the set of correct text regions.

The standard measure f is a single measure of quality combining r and p. It defined as:

1

/ (1 ) /f

p rα α=

+ −. (13)

The parameter α gives the relative weights to p and r. It is set to 0.5 to give equal weight in our experiment.

4.2 Experiments

In this section, three experiments are designed to evaluate the performance of the proposed method.

Page 8: Text Particles Multi-band Fusion for Robust Text Detection Particles Multi-Band... · Text Particles Multi-band Fusion for Robust Text Detection 589 fusion is used to enhance the

594 P. Xu et al.

Experiment 1 (TP based on LHBP): To evaluate the efficiency of LHBP descriptors in proposed method, we compare our detection method with 1).the method based on wavelet energy features [7] and 2).edge based method [5].

The wavelet energy method uses solely Haar wavelet texture feature without the color feature. We get the P-R curve through changing the thresholds of the methods (Fig 5). And at the peak of f, comparing with wavelet energy method [7], our method’s performance enhancements are over 12% in p, over 23% in r, and over 16% in f. Comparing with the experiment result of edge method in [5] (Fig. 6.Ezaki-Edge), the precision of [5] is almost the same as our method, but its recall and f are lower than our method.

Analysis: Take a deep insight into this result, the wavelet energy (or edge) based method extract the feature only from the I-band image of original image, and the feature extraction is effected by text-background contrast (illumination) variance. Using the TP based on LHBP, our method can normalize the illumination variance of text-background contrast to effective describe the texture

Fig. 5. P-R Curve of methods comparing Fig. 6. P&R comparison in ICDAR 03 trail-test set

Experiment 2 (Multi-band Fusion Strategy): To demonstrate the efficiency of the combination of TP descriptor with different color bands, the proposed method is compared with the method (solely the color features) in [5]. As presented in Fig.6, comparing with color based detection method, performance enhancements are over 4% in p, over 38% in r, and over 20% in f.

Analysis: The method in [4] solely extracts the color features from source images and the features can’t effective distinguish the text from background when the text color is similar to background (Fig.1 (a)). The proposed method extracts the TP from the YUV color space and fuses the results of every band. It can get the intrinsic features of text to enhance the detection performance (Fig. 8).

Experiment 3 (Results of ICDAR 03): Our method is compared with 1. Representa-tive text detection methods [4, 5] based on color and edge features and 2. The compe-tition results of ICDAR 03 [14]. As presented in Fig.7, comparing to those methods, performance enhancements are roughly equivalent in p, but over 10% in r, and over 7% in f. It demonstrates the effectiveness of the proposed Text Particles Multi-Band Fusion method.

Page 9: Text Particles Multi-band Fusion for Robust Text Detection Particles Multi-Band... · Text Particles Multi-band Fusion for Robust Text Detection 589 fusion is used to enhance the

Text Particles Multi-band Fusion for Robust Text Detection 595

Fig. 7. P&R comparison in ICDAR 03 trail-Test Set

(a) (b) (c)

(d) (e) (f)

Fig. 8. Text detection Results Compared with Other Method. (a, d) the proposed method’s results. (b, e) Yi-Edge+Color’ results. (c, f ) Ye-Wavelet’ results.

5 Conclusion

This paper proposes a text particle detection method by LHBP-based multi-band fu-sion. We not only address the variances in both illumination and text-background variance, but also fuse color & texture features to reinforce each other. Experiment results on ICDAR 03 over three state-of-the-art methods demonstrate the efficiency of the proposed method.

In our future works, we would further investigate the problem of rigid and non-rigid text region transformation, to implement our system to arbitrary viewpoints in the real-world.

Acknowledgement. This research is supported by State 863 High Technology R&D Project of China (No. 2006AA01Z197), Program for China New Century Excellent Talents in University (NCET-05-03 34), Natural Science Foundation of China (No. 60472043) and Natural Science Foundation of Heilongjiang Province (No.E2005-29).

Page 10: Text Particles Multi-band Fusion for Robust Text Detection Particles Multi-Band... · Text Particles Multi-band Fusion for Robust Text Detection 589 fusion is used to enhance the

596 P. Xu et al.

References

1. El Rube, I., Ahmed, M., Kamel, M.: Wavelet approximation-based affine invariant shape representation functions. IEEE Transactions on Pattern Analysis and Machine Intelli-gence 28(2), 323–327 (2006)

2. Chen, D.T., Bourland, H., Thiran, J.P.: Text identification in complex background using SVM. In: International Conference on Computer Vision and Pattern Recognition, pp. 621–626 (2001)

3. Lienhart, R., Wernicke, A.: Localizing and segmenting text in images and videos. IEEE Transactions on Circuits and Systems for Video Technology 12, 256–268 (2002)

4. Ezaki, N., Bulacu, M., Schomaker, L.: Text Detection from Natural Scene Images: To-wards a System for Visually Impaired Persons. In: International Conference on Pattern Recognition, vol. 2, pp. 683–686 (2004)

5. Yi, J., Peng, Y., Xiao, J.: Color-based Clustering for Text Detection and Extraction in Im-age. In: ACM Conference on Multimedia, pp. 847–850 (2007)

6. Gllavata, J., Ewerth, R., Freisleben, B.: Text detection in images based on unsupervised classification of high frequency wavelet coefficients. In: International Conference on Pat-tern Recognition, pp. 425–428 (2004)

7. Ye, Q.X., Huang, Q.M.: A New Text Detection Algorithm in Image/Video Frames. In: Advances in Multimedia Information Processing 5th Pacific Rim Conference on Multime-dia, Tokyo, Japan, November 30-December 3, 2004, pp. 858–865 (2004)

8. Ji, R.R., Xu, P.F., Yao, H.X., Sun, X.S., Liu, T.Q.: Directional Correlation Analysis of Lo-cal Haar Binary Pattern for Text Detection. In: IEEE International Conference on Multi-media & Expo (accept, 2008)

9. Xi, D., Kamel, M.: Extraction of filled in strokes from cheque image using pseudo 2D wavelet with adjustable support. In: IEEE International Conference on Image Processing, vol. 2, pp. 11–14 (2005)

10. Ojala, T., Pietikäinen, M., Harwood, D.: A Comparative Study of Texture Measures with Classification Based on Feature Distributions. Pattern Recognition 29(1), 51–59 (1996)

11. Ojala, T., Pietikäinen, M., Mäenpäa, T.: Multi-resolution Gray-Scale and Rotation Invari-ant Texture Classification with Local Binary Patterns. IEEE Transactions on Pattern Analysis and Machine Intelligence 24(7), 971–987 (2002)

12. Li, S., Chu, R., Liao, S., Zhang, L.: Illumination Invariant Face Recognition Using Near-Infrared Images. IEEE Transactions on Pattern Analysis and Machine Intelligence 29(4), 627–639 (2007)

13. Zhao, G., Pietikäinen, M.: Dynamic Texture Recognition Using Local Binary Patterns with an Application to Facial Expressions. IEEE Transactions on Pattern Analysis and Machine Intelligence 29(6), 915–928 (2007)

14. Lucas, S.M., Panaretos, A., Sosa, L., Tang, A., Wong, S., Young, R.: ICDAR 2003 robust reading competitions. In: Proceedings of International Conference on Document Analysis and Recognition, pp. 682–687 (2003)