You are on page 1of 6

Automatic Texture Segmentation for Texture-based Image Retrieval

Ying Liu, Xiaofang Zhou


School of ITEE, The University of Queensland, Queensland, 4072, Australia
liuy@itee.uq.edu.au, zxf@itee.uq.edu.au

Abstract color regions, such as direct clustering methods in color


space [10]. But natural scenes are rich in both color and
Texture-segmentation is the crucial initial step for texture. Most texture segmentation algorithms [1][3]
texture-based image retrieval. Texture is the main requires the estimation of texture model parameters,
difficulty faced to a segmentation method. Many image which is proved to be difficult [11]. To solve this
segmentation algorithms either can’t handle texture problem, a region growing method based on image color
properly or can’t obtain texture features directly during space quantization, named JSEG, is presented in [12].
segmentation which can be used for retrieval purpose. Experiments show that JSEG provides good segmentation
This paper describes an automatic texture segmentation results on a variety of images. In [11], a method based on
algorithm based on a set of features derived from wavelet local homogeneity analysis is presented. This method is
domain, which are effective in texture description for similar to JSEG but with simpler criterion used.
retrieval purpose. Simulation results show that the The above algorithms though can catch textured
proposed algorithm can efficiently capture the textured regions, the segmentation is not based on texture features.
regions in arbitrary images, with the features of each Instead, they make use of other information such as color
region extracted as well. The features of each textured and spatial arrangement to handle texture. For texture-
region can be directly used to index image database with based image retrieval purpose, we need texture features
applications as texture-based image retrieval. which can be used for image retrieval. For this, one way
is to use the above mentioned segmentation algorithm,
and extract texture feature of the segmented regions after
1. Introduction segmentation. Alternatively, we can implement texture
segmentation in such a way that the features used for
Region-based image retrieval (RBIR) systems retrieve segmentation can be directly used for retrieval purpose.
images on the basis of automatically-derived features The latter is simpler as feature extraction after
such as color, texture and shape from interested regions in segmentation is not necessary, and more efficient as
an image. Automatic image segmentation is a crucial segmentation using salient texture features could handle
initial step before performing RBIR. A variety of texture more properly.
techniques have been proposed in the past, including In this paper, we proposed an automatic texture
stochastic model based approaches [1], curve evolution segmentation method based on Discrete Wavelet
[2], energy diffusion[3], region growing[4], and graph Transform (DWT). This method can well catch textured
partitioning[5]. Quantitative evaluation methods have also regions of arbitrary images. In addition, feature of each
been suggested [6]. segmented region are obtained during segmentation and
Among contents based features, texture is a can be used directly for the purpose of texture-based
fundamental feature which provides significant image retrieval. The remainder of this paper is organized
information for scene interpretation and image as follows. Section 2 describes the related work. Section 3
classification [7], hence texture-based image retrieval is introduces the proposed algorithm. Section 4 gives the
an important topic. Textures can be defined as experimental results. Finally, section 5 concludes this
‘homogeneous patterns or spatial arrangements of pixels paper.
that regional intensity or color alone does not sufficiently
describe’ [8].
Texture is the main difficulty faced to a segmentation 2. Related work
method [9]. There are many existing techniques for the
segmentation of images that contains only homogeneous
A wide range of natural images can be considered as a Moreover, the features of each region can be directly used
mosaic of different textured regions, each textured region to index image database for retrieval purpose.
of the images in the database can be characterized and
added to a texture-based index of the database for 3. The proposed algorithm
retrieval purpose. To efficiently handle texture, salient
texture features can be used in texture segmentation. In the proposed system, an image is first partitioned
Gabor filters are designed to respond to different spatial into blocks of 4*4 pixels, then a 2-level wavelet transform
frequencies and have been applied to texture using 4-tap Daubechies filter is applied to each block.
segmentation [13]. However, it is computationally This produces 7 sub-bands as shown in Figure 1.
expensive as a large combination of parameters are used. Features in wavelet domain have been shown to be
Wavelet has been proved to be a promising alternative of effective in texture representation for retrieval purpose
Gabor filters for texture segmentation purpose [14]. In [17]. In our experiments, mean, and variance of each of
[15], a quad-tree decomposition based on wavelet features the 7 sub-bands are extracted to form feature vector of 14
is proposed. The approach is ‘top-down’ in a way that it terms.
starts from the whole image, which is the root node of the Let Sw and Sh be the width and height of a certain sub-
decomposition tree. Using a quad-tree decomposition, the band in wavelet domain, mean (m) and variance (var) of
algorithm extracts texture feature from spatial blocks at a the coefficients in this sub-band can be calculated as:
hierarchy of scales in each image. Finally, homogeneous ( S −1) ( S −1 )

∑ ∑
h w

blocks of texture are extracted which can be used in a m =[ C ( i , j )] /( S * S ) (1)


f w h
i=0 j=0
database index.
( S h −1 ) ( S w −1 )
In the algorithm in [15], at each level of the tree,
texture content of the parent block is compared with the
var = ( ∑ ∑ [C
i=0 j=0
f (i, j ) − m ] 2 (2)

children block, to judge if it is a texture. The problem is where C f ( i , j ) is the transform coefficient.
that before the algorithm stops, the parent block is not a
texture, and the children blocks might not be texture With features of each block available, we can classify
either. As we know, description of non-textured images all blocks into different classes. The block at the top-left
is more difficult than that of textured images. Hence, to corner belongs to the 1st class, and its feature is the initial
properly measure the similarity between the parent block feature of this class. We then scan all blocks one by one.
and the children blocks, more complicated feature For block Bc, suppose the blocks previously scanned
extraction algorithm is required. In addition, this belong to m different classes, if Bc belongs to any of the
algorithm stops at low resolution textures, and can’t m classes, we update the feature of this class (each term
obtain high-resolution textures which users might be of the updated feature is simply calculated as the average
interested in. For example, it can catch an arrangement of of the corresponding term of all feature vectors in the
oranges which is a texture. But what if we are interested class so far); if not, add a new class as the (m+1)th class,
in the skin of an orange? and feature of Bc is the initial feature of the new class.
To solve these problems, in this paper, we proposed a In order to determine which class Bc belongs to, we
‘bottom-up’ texture segmentation algorithm, which starts compute its Euclidean distance d i ( i = 1, 2 ,..., m ) to each
from small homogeneous blocks and grow up gradually to of the m classes obtained so far. Euclidean distance
find textured regions. between two l-dimensional vectors X and Y is defined as:
‘Bottom-up’ texture segmentation can be pixel-wise l −1

or block-wise. Pixel-wise segmentation schemes evaluate d = ∑i= 0


(x i − yi) 2 (3)
the texture features in a neighbourhood surrounding each
pixel of the image. The advantage of pixel-wise If the smallest distance d j falls below the given
segmentation lies in the removal of blockyness at region threshold Thr, then Bc belongs to class j. If all distances
boundaries. However, the computation load is heavier. As are above Thr, Bc belongs to a new class. Note that
image retrieval system does not require exact boundary of heavier weight is assigned to var when we compute
the segmented regions [15], block-wised segmentation is Euclidean distance of two feature vectors. Experiments
often chosen since it is much faster [16]. show that a weights ratio of 9:1(for var and m) is proper.
The proposed block-wise texture segmentation Finally we obtain N classes each containing Mi (i=1,…,N)
algorithm is based on a set of features derived from blocks, and we have the features of each classes obtained.
wavelet domain. This set of features has been proved to Note that one class might contain more than one regions
be efficient for texture description. The algorithm can which are disconnected.
well capture textured regions of arbitrary images.
Results show that this texture segmentation algorithm edges and boundaries. Sub-bands 4, 5, 6 in Figure 1 are
is effective in capturing the textured regions of an image. the three high frequency sub-bands. We define a
Examples are given in Figure 2. parameter Eng_High, which is the percentage of energy
There are some tiny isolated regions existing after of coefficients in sub-bands 4,5,6, relative to the total
segmentation. In most cases, these regions are coefficient energy across all 7 sub-bands.
meaningless. We have not implemented post-processing To study the relationship between Eng_High and the
of these regions yet since these errors are often not texture property of images, we randomly chose 100
significant. They can be merged with larger visually textured images and 100 non-textured images of different
close regions if any, or ignored. sizes, and calculated their Eng_High values. Figure 4
shows the histograms of Eng_High for the two types of
images.
0 1 It is shown that the two histograms separate around
the decision threshold 0.03. For ‘flat’ images which
4
contain very little high frequency information, their
2 3 Eng_High values are very small. We found that a
threshold around 0.005 is proper to separate ‘flat’ images
from textured and non-textured images. Figure 5 shows
a few images with their Eng_High values given. We
5 6 found that the above property is invariant to image sizes,
and the decision threshold varies with the DWT
decomposition level we chose.
Previous work proved that larger threshold should be
Figure 1. 7 sub-bands in a 2-level DWT set for blocks with larger variance during the
segmentation procedure [15]. Textured regions contain
4. Adjusting parameters more intensity changes than non-textured regions and
hence higher Thr should be used. In our algorithm,
4.1. Thr experimentally, different Thr are set to blocks with
different Eng_High as below:
Obviously, the higher the Thr, the smaller the number
of classes we can get. If Thr is too low, one textured if (Eng_High<0.005) Thr=Thr0; //flat regions
region we are interested in might be segmented into else if(Eng_High<0.03) Thr=Thr0*1.7;
different parts. On the other hand, if Thr is too high, //non-textured regions
different textured regions might be classified into same else Thr=Thr0*2.5; //textured regions
part.
Experiments show that Thr between 10 and 20 is
20
proper for many images.
Number of Images

16

4.2 Eng_High 12

With segmentation above, we found that regions with 8

higher variance are easy to be segmented into different


4
parts, as in Figure 3(a). Increasing Thr can to certain
degree relieve this problem. But if Thr is too high, some 0

different regions might be classified into same class, as 0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45

shown in Figure 3(b). Hence, we consider using various Eng_High


Thr instead of uniform Thr for different blocks.
t extured non-textured
According to their texture property, regions of an
image can be roughly classified as ‘flat’ regions which
contain little intensity changes, ‘textured’ regions which Figure 4. The histogram of Eng_High over 100
are composed of repetitive patterns, and ‘non-textured’ textured and 100 non-textured images
regions.
High frequency coefficients in wavelet domain With higher threshold for blocks with more high
correspond to sharp intensity changes in the image, like frequency information, textured regions which were
segmented into different parts before can be recognized as
one region. In addition, the number of classes is reduced [2] H.Feng, D.A. Castanon, and W.C. Karl, “A curve evolution
and hence computational load is less. Figure 3(c) shows approach for image segmentation using adaptive flows”, Proc.
an example. of ICCV, 2001.
[3] W.Y.Ma and B.S. majunath, “Edge flow: a framework of
boundary detection and image segmentation”, Proc. of CVPR,
5. Image retrieval based on texture content 1997, pp744-749.
With the proposed texture segmentation algorithm, we [4] R.Adams and L.Bischof, “Seeded region growing”, IEEE
Trans. On Pattern Analysis and Machine Intelligence (PAMI),
can capture the textured regions of arbitrary images. In 16(6), 1994, pp641-647.
addition, texture features of the segmented regions are
[5] J. Shi and J. Malik, “Normalized cuts and image
obtained. These features can be used directly to index the
segmentation”, IEEE Trans. On Pattern Analysis and
image database with applications as texture-based image Machine Intelligence (PAMI), 22(8), Aug. 2000, pp888-905.
retrieval.
[6] M. Borsotti, P.Campadelli, and R. Schettini, “Quantitative
Our testing database is a collection of 250 arbitrary
evaluation of color image segmentation results”, Pattern
images with different sizes and contents. Texture Recognition letters, vol.19, no.8, 1998, pp741-748.
segmentation is applied to each image in the database,
[7] Yong Man Ro, “Matching pursuit: contents featuring and
and features of each region are stored. The feature of the image indexing”, SPIE, Vol. 3527, pp89-92, 1998.
query region is calculated using the same way as
[8] J. R. Smith, “Integrated Spatial Feature Image Systems:
described in Section 2. The images containing region(s)
Retrieval, Analysis and Compression”, Ph.D. thesis, Graduate
similar to the query region are selected as retrieval results. School of Arts and Sciences, Columbia University, 1997.
Figure 6 shows a retrieval example with the top 8 selected
[9] Yining Deng, B.S. Manjunath, “Unsupervised segmentation
images listed.
of color-texture regions in images and video”, Unsupervised
segmentation of color-texture regions in images and video
6. Conclusions (PAMI), vol 23, No.8, Aug., 2001, pp800-810.
[10] D. Comaniciu and P.Meer, “Robust analysis of feature
This paper presents a block-wise texture segmentation spaces:color image segmentation”, Proc. of IEEE Conf. on
algorithm, which automatically segment an image into Computer Vision and Pattern Recognition,1997, pp750-755.
textured regions. Meanwhile, texture features of each [11] Feng Jing, Mingling Li, Hongjiang Zhang, Bo Zhang,
region are extracted which can be used as indexing of “ Unsupervised image segmentation using local homogeneity
image databases. We expect the proposed algorithm to analysis”, Proc. IEEE Inter. Symposium on Circuits and
allow efficient image retrieval on the bases of texture Systems, 2003.
content. [12] Yining Deng, B.S.Manjunath and Hyundoo Shin, “Color
In our algorithm, the feature of the segmented region is Image Segmentation”, Proc. of IEEE Computer Society Conf.
calculated as the average of the features of all the blocks on Computer Vision and Pattern Recognition, CVPR’99, Fort
it contains. To describe a region more efficiently, Collins, CO, vol.2, June 1999, pp446-451.
information of the entire region could be used. We will [13] Dunn, D. and Higgins, W.E., “Optimal Gabor filters for
work on this later. In addition, we will extend the system texture segmentation”, IEEE Trans. on Image Processing,
to large real-world image database and apply index to Vol4., No.7,1995, pp947-964.
facilitate fast retrieval in our future work. [14] Mausumi Acharyya and Malay K. Kundu, “Adaptive basis
selection for multi texture segmentation by M-band wavelet
packet frames”, Inter. Conf. on Image Processing, 2001.
Acknowledgement pp.622-625.
[15] J.R.Smith and Shih-Fu Chang, “Quad-tree segmentation for
This work is partly completed when the first author was texture-based image query”, Proc. of the 2nd Annual ACM
attached to the School of Computing, National University Multimedia Conference, San Francisco, Ca., Oct. 1994.
of Singapore, under project R-252-000-015-112/303.
[16] Jia Li, James Ze Wang, and Gio Wiederhold,
“Classification of textured and non-textured images using
7. References region segmentation”, Inter. Conf. on Image Processing,
Sep.2001, pp 754-757.
[1] S.Belongie, C. Carson, H. Greenspan, and J. Malik, “Color- [17] J.R.Smith, S.-F. Chang, “Transform features for texture
and texture-based image segmentation using EM and its classification and discrimination in large image databases”,
application to content-based image retrieval”, Proc. of ICCV, Inter. Conference on Image Processing, vol.3, 1994, pp407-
1998, pp675-682. 411.
Figure 2. Examples of texture segmentation
(Left: Original images, Right: Segmentation results)

Uniform, Thr=10, N=54 Uniform Thr=20, N=9 Various Thr (Thr0=10), N=6

(a) (b) (c)


Figure 3. Segmentation results with uniform Thr and various Thr
Eng_High=0.260 Eng_High=0.025 Eng_High=0.001
Figure 5. Textured and non-textured images with Eng_High

Query region query image

Figure 6. Texture-based image retrieval

You might also like