Image and Vision Computing 21 (2003) 517–525 www.elsevier.com/locate/imavis
Dominant point detection using adaptive bending value Wen-Yen Wu* Department of Industrial Engineering and Management, I-Shou University, Kaohsiung 84008, Taiwan, ROC Received 12 February 2003; received in revised form 15 February 2003; accepted 19 February 2003
Abstract An efficient method for dominant point detection is proposed in this paper. The region of support for each point on curve is determined using bending value. The points with local maximum smoothing bending value can be located as the dominant points on the curve. The proposed algorithm needs no input parameter. The experimental results show that the new method is efficient and effective in detecting dominant points. q 2003 Elsevier Science B.V. All rights reserved. Keywords: Bending value; Region of support; Dominant point; Corner; Polygonal approximation
1. Introduction Detecting dominant points is an important step for many machine vision applications. It has been suggested that information on a curve is concentrated at the points with curvature extreme [3]. In image processing and pattern recognition, dominant points are used to reserve the shape of planar curves as well as to reduce the amount of data. There are many algorithms developed to detect dominant points. Most of them can be classified into two categories: (1) polygonal approximation approaches and (2) corner detection approaches. For polygonal approximation algorithms, Sklansky and Gonzalez [15] proposed a cone-intersection method to partition the curve sequentially. Wall and Danielsson [18] partitioned the curve at the point which area deviation per length unit exceeds a preset value, sequentially. Ramer [10] iteratively split the curve into two smaller curves at the point with maximum deviation until the maximum deviation is less than a preset threshold. Ansari and Delp [1] located the points with maximal curvature by Gaussian smoothing method as starting points, and followed a split-and-merge procedure to find the dominant points. Kankanhalli [9] presented a method that specifies four dominant points and their support regions to extract the other dominant points, iteratively. Dunham [5] applied the dynamic programming * Tel.: þ886-7-6577711x5512; fax: þ 886-7-6578536. E-mail address:
[email protected] (W.-Y. Wu).
technique to detect the optimal approximated polygon. Rosin and West [14] first analyzed lists of connected edge points to find a polygonal description, and then grouped them into lines or arcs. Aoyama and Kawagoe [2] proposed a two-stage approach that consists the uniform process and the recovering process to approximate curves. Huang and Sun [7] proposed a genetic algorithm with three operators namely selection, crossover, and mutation, to find the polygonal approximation. Yin [22] used the tabu search approach to find the optimal or near-optimal solution for polygonal approximation. Xiao et al. [21] approximated curves using a split-and merge method with an adaptive tolerance value. Zhu [23] found the optimal polygonal approximation with the minimum number of points for a uniform error norm. Hu and Yan [8] proposed a three-stage method based on the principles of perceptual organization to solve the problem of polygonal approximation. The purpose of corner detection is to detect significant points with curvature extreme. The family of corner detection algorithms consists of two common stages: (1) estimate curvature and (2) locate the local maximum curvature. Rosenfeld and Johnston [12] extracted the vertices with local maximum and minimum cosine values as corners. Rosenfeld and Weszka [13] improved the above method by averaging the cosine values as the estimated curvatures. Bell and Pau [4] identified the pixels for which two averages of chain codes differ most as the corners. Wu and Wang [20] detected the dominant points by the curvature-based polygonal approximation method. Wang
0262-8856/03/$ - see front matter q 2003 Elsevier Science B.V. All rights reserved. doi:10.1016/S0262-8856(03)00031-3
518
W.-Y. Wu / Image and Vision Computing 21 (2003) 517–525
et al. [19]used the bending value to detect corners. Tsai [17] proposed a neural network approach to detect corners. Most of the corner detection algorithms need one or more input parameters to define the length of region of support or the smoothing factor in estimating curvatures. The region of support is set to the same for all of the points on the curve. Teh and Chin [16] concentrated on the determination of region of support. A large region of support will smooth out fine features and a small one will generate too many dummy dominant points. They pointed out that the detection of dominant points relies not only on the accuracy of curvature measures, but primary on the precise determinant of region of support. The chord length and distance was used to determine the region of support for each point. Instead of using chord length and distance, Ray and Ray [11] introduced a new measurement of significant namely kcosine to determine region of support. It is parallel and requires no input parameters. However, both of the above two methods suffer to large computation effort. In this paper, we proposed a new measurement based on bending value to develop a simple method to determine the region of support. The break point detection procedure is applied to find the candidates of dominant points on the curve. It will reduce the computation time both in determination of region of support and curvature estimation. The proposed method is fast and it needs no input parameter. The experimental results show that the method is efficient and effective in detecting dominant points. In Section 2, we will illustrate the proposed algorithm. The experimental results are demonstrated in Section 3. Some concluding remarks are then given in Section 4.
2. Dominant point detection Dominant points are considered as representative features for the object contours, because they reserve the features of the digitized curve of the images. They are commonly identified as the points with local maximum curvature. Curvature of a point is defined as the rate of change of slope as a function of arc length for a continuous curve. That is, the curvature k ¼ du=ds: Unfortunately, the above definition does not hold for a digital curve, due to that there exist no mathematical definition for the digital curve. Therefore, most of the existing algorithms focus on curvature estimation by use of the information of the neighbors. The set of n consecutive points is denoted as a digital curve C. That is, C ¼ {pi ðx; yi Þli ¼ 1; 2; …n};
ð1Þ
where n is the number of points, pi is the ith point with coordinate ðx; yi Þ: Alternatively, a digital curve can also be expressed as the n Freeman’s chain codes [6] and is denoted as c1 c2 …cn ; where ci ¼ ci^n and all indices are modulo n. Each of the vectors is assigned to an integer ci varying from 0 to 7,
Fig. 1. Freeman’s chain codes.
where ð1=4Þp ci is the angle between the x-axis and the vector, for i ¼ 1; 2; …; n (see Fig. 1). It is reasonable to assume that the points on straight line cannot be considered as the dominant points. The linear points can be removed by tracking the chain codes. If ci21 ¼ ci ; then the point pi is a linear point. Otherwise, it is a break point. The break points are the candidates of dominant points. It will reduce the computation time both in determination of support region and curvature estimation, if only the set of break points are considered as the possible dominant points. Teh and Chin [16] used the ratio of distance and chord length to determine the region of support for each point adaptively. The distance to chord length ratio is defined as (see Fig. 2(a)) rik ¼
dik ; lik
ð2Þ
where lik is the length of chord pi2k piþk ; and dik is the distance from point pi to the chord pi2k piþk : Ray and Ray [11] used the k-cosine to determine the region of support. The k-cosine is defined as (see Fig. 2(b))
uik ¼
akik ·bkik ; lak ik l lbkik l
ð3Þ
where akik ¼ ðxi2k 2 xi ; yi2k 2 yi Þ and bkik ¼ ðxiþk 2 xi ; yiþk 2 yi Þ: Wang et al. [19] proposed a simple measure to detect corners. In this paper, we use the adaptive bending value to determine the region of support for each point on the curve. The bending value is define as (see Fig. 2(c)) bik ¼ maxðlðxi2k 2xi Þþðxiþk 2xi Þl;lðyi2k 2yi Þþðyiþk 2yi ÞlÞ: ð4Þ Suppose that there are m break points on the curve. The length of regions of support for the ith break point, vi ; can be determined by the following rule:
W.-Y. Wu / Image and Vision Computing 21 (2003) 517–525
519
The next step is to identify the dominant points. It is necessary to suppress those break points with bending values less than a preset threshold 1: In addition, a dominant point should have local maximum bending value. For two neighboring break points, the point with smaller length region of support is removed. Further, if two consecutive points has the same curvature and the same length of support region, discard the later one. Five conditions of suppressing the break points from the set of candidates of dominant points are summarized as follows. Condition A: bvi , 1
ð7Þ
Condition B: bvi , bvj ; for j ¼ i 2 1 or i þ 1
ð8Þ
Condition C: bvi ¼ bvi21 and ki , ki21
ð9Þ
Condition D: bvi ¼ bviþ1 and ki , kiþ1
ð10Þ
Condition E: bvi ¼ bviþ1 and ki ¼ kiþ1
ð11Þ
The survived break points with local maximum over its region of support are denoted as the dominant points. Therefore, we can locate of dominant points by the following rule. Rule 2. If one of the Conditions A to E is satisfied, then the break point is removed from the set of candidates of dominant points. Overall, the proposed method for dominant point detection is summarized as follows: Step 1. Extract break points from Freeman’s chain codes. Step 2. Determine region of support for each break point by Rule 1. Step 3. Compute the smoothing bending values for all of the break points by Eq. (6). Step 4. Identify the dominant points by Rule 2. Fig. 2. Curvature estimation methods: (a) ratio of the deviation and the chord length, (b) k-cosine value, and (c) bending value.
Rule 1. Start with k ¼ 1: Compute the bending value bik giving increment to k: If bik , bi;kþ1 then k is the length of regions of support for vi ; else if bik ¼ bi;kþ1 then the greatest k satisfies this condition is the length of regions of support for vi : Let ki be the length of regions of support for the ith break point, vi : The region of support for vi is the set of points defined by RSðvi Þ ¼ {pi2ki ; …; piþki }:
ð5Þ
Once the region of support for each break point has been determined, the estimated curvature can be obtained by the following smoothing bending value. bvi ¼
ki 1 X b ki j¼1 ij
ð6Þ
3. Experimental results The proposed method has been applied to four commonly used curves in many studies. They are the chromosome curve (Fig. 3(a)), infinity curve (Fig. 4(a)), leaf curve (Fig. 5(a)), and semicircle curve (Fig. 6(a)). Their chain codes can be found in Ref. [11]. In the experiment, the curvature threshold 1 is set to 0.25. By tracking the chain codes, the break points can be determined. In order to assess the performance of the proposed method, six performance evaluation criteria were used in the experiment. They are the number of the dominant points, compression ratio, sum of square error, maximum error, weighted sum of square error, and weighted maximum error. (1) Number of the dominant points ðnd Þ: It is desirable to have the number of dominant points as small as possible.
520
W.-Y. Wu / Image and Vision Computing 21 (2003) 517–525
Fig. 3. Dominant points of the chromosome curve: (a) original, (b) Teh and Chin, (c) Ray and Ray, and (d) our method.
Fig. 4. Dominant points of the infinity curve: (a) original, (b) Teh and Chin, (c) Ray and Ray, and (d) our method.
W.-Y. Wu / Image and Vision Computing 21 (2003) 517–525
521
Fig. 5. Dominant points of the leaf curve: (a) original, (b) Teh and Chin, (c) Ray and Ray, and (d) our method.
(2) Compression ratio ðn=nd Þ: One of the objectives for dominant point detection is to reduce the amount of data. The larger the compression ratio is, the more effective in data reduction the method is. (3) Sum of square error ðE2 Þ: This criterion assesses the distortions caused by the approximated curve. The smaller the sum of square error is, the better descriptive ability the method is. It is defined as E2 ¼
n X
e2i ;
ð12Þ
i¼1
WE2 ¼
ð13Þ
nd £ E2 n
ð14Þ
(6) Weighted maximum error ðWE1 Þ : The weighted maximum error is to compromise the compression ratio and the maximum error. It is defined as WE1 ¼
where ei is the distance from pi to the approximated segment. (4) Maximum error ðE1 Þ: This criterion assesses the approximated errors. The smaller the maximum error is, the better fitness the method is. It is defined as E1 ¼ max{ei ; i ¼ 1; 2; …; n}:
(5) Weighted sum of square error ðWE2 Þ: The weighted sum of square error is to compromise the compression ratio and the sum of square error. It is defined as
nd £ E1 n
ð15Þ
The objective of this paper is not to propose an optimal solution to dominant point detection. Alternatively, it attends to show that the new method is very simple and it can improve the performance of the family
522
W.-Y. Wu / Image and Vision Computing 21 (2003) 517–525
Fig. 6. Dominant points of the semicircle curve: (a) original, (b) Teh and Chin, (c) Ray and Ray, and (d) our method.
of region of support determining algorithms. From Eqs. (2) – (4), it is seen that the proposed method is very simple and fast. In addition, the new method considers only the break points as the candidates of dominant points, it will further reduce the computation effort. The experimental results of our method and of the other methods are listed in Table 1.
For the chromosome curve, Teh and Chin’s method detects the minimum number of dominant points, but it has the largest E2 : Comparing to Ray and Ray’s method, it is seen that the proposed method has better performance for all criteria. In addition, it is seen that our method has the smallest E2 ; E1 ; WE2 ; and WE1 : That is, our method has the better performance than the other methods. Fig. 3(b) – (d)
Table 1 Results of the proposed method and of the other methods Curve
Method
nd
n=nd
Chromosome ðn ¼ 60Þ
Teh and Chin Ray and Ray Our method
15 18 16
4.00 3.33 3.75
Infinity ðn ¼ 45Þ
Teh and Chin Ray and Ray Our method
13 12 13
Leaf ðn ¼ 120Þ
Teh and Chin Ray and Ray Our method
Semicircles ðn ¼ 102Þ
Teh and Chin Ray and Ray Our method
E2
E1
WE2
WE1
7.20 5.57 4.70
0.71 0.71 0.69
1.88 1.67 1.65
0.18 0.21 0.18
3.46 3.75 3.46
5.93 5.99 5.78
1.00 0.89 1.11
1.71 1.60 1.67
0.29 0.24 0.32
29 32 24
4.14 3.76 5.00
14.96 14.72 15.93
0.99 1.00 0.99
3.62 3.93 3.19
0.24 0.27 0.20
22 29 26
4.64 3.52 3.92
20.61 11.82 9.04
1.00 0.83 0.88
4.45 3.36 2.31
0.22 0.24 0.23
W.-Y. Wu / Image and Vision Computing 21 (2003) 517–525
shows the detected dominant points for the chromosome curve by using Teh and Chin, Ray and Ray, and our methods, respectively. For infinity curve, Ray and Ray’s method seems to have the best performance. However, our method has smaller sum of square error than that of Ray and Ray’s method. In addition, our method detect the same number of dominant points to that of Teh and Chin’s method, whereas it has smaller sum of square error that that of Teh and Chin’s method. The detected dominant points of the infinity curve are presented in Fig. 4. Fig. 5 shows the dominant points of the leaf curve detected by thee three different methods. The proposed method has the smallest nd for the leaf curve. Therefore, it has the best performance on compression ratio. Although it has the largest value of sum of square error, the weighted sum of square error is the smallest while comparing to the other methods. In addition, the performance on maximum error and weighted maximum error are both smallest for the proposed method. That is, the new method can detect a set of the most significant points that has the minimum number of points and it can approximate the original curve very well. Our method detect smaller number of dominant points than that of Ray and Ray’s method for the semicircle curve, whereas it results in smaller E2 and WE2 : In fact, the proposed method has the best performance on
523
weighted sum of square error. The detected dominant points are shown in Fig. 6. Overall, we propose a simple method to determine region of support for each point, and the new method performs very well while comparing to the other methods. Since a dominant point detection method should be robust. That is, the detected dominant points for an object have to be consistent for the object under different scales and orientations. In order to evaluate the proposed method, we used the screw curves as shown in Fig. 7 to access its robustness. The numbers of points on the three curves are 599, 291, and 653, respectively. The three curves in Fig. 7 are all of the same screw, except that they are in different scales and orientation. There were 59, 56, and 64 dominant points detected by the proposed method as shown in Fig. 7. The positions of the detected dominant points are very consistent among the three curves. Further, from the consistent numbers of dominant points, it is seen that the proposed method is robust. Another experiment has been conducted on the Chinese characters. Fig. 8 shows the curves for Chinese characters that represent ‘image processing’. The image in Fig. 8(a) is the original curve, and Fig. 8(b) is its approximated polygon. From the superimposed image in Fig. 8(c), it is seen that the proposed method can approximate the original curve very well.
Fig. 7. Screw curves with different scales and orientations: (a) n ¼ 599 and nd ¼ 59; (b) n ¼ 291 and nd ¼ 56; and (c) n ¼ 653 and nd ¼ 64:
524
W.-Y. Wu / Image and Vision Computing 21 (2003) 517–525
Fig. 8. Chinese character curve: (a) original curve, (b) approximated polygon, and (c) superimpose (b) to (a).
4. Conclusions
References
Dominant points are those points that have curvature extreme on the curve and they can suitably describe the curve for both visual perception and recognition. Teh and Chin proposed an adaptive method to determine region of support for each point. Ray and Ray further suggested the k-cosine measurement to determine region of support. Both of the above two methods suffer to large computation effort. In this paper, we proposed a new significant measurement to solve the problem of determination of support region. The concept of linearity is used to find a set of break points. The region of support for each break point is determined using the bending value in the same time. The smoothing bending value is used to estimate curvature. The proposed method is fast and it needs no input parameters. From the experimental results, it is show that the proposed method is efficient and effective in detecting dominant points.
[1] N. Ansari, E.J. Delp, On detection dominant points, Pattern Recognition 24 (1991) 441 –450. [2] H. Aoyama, M. Kawagoe, A piecewise linear approximation method preserving visual feature points of original figures, CVGIP: Graphical Model and Image Processing 53 (1991) 435– 445. [3] F. Attneave, Some information aspects of visual perception, Psychological Review 61 (1954) 183–193. [4] B. Bell, L.F. Pau, Contour tracking and corner detection in a logic programming environment, IEEE Transactions of Pattern Analysis and Machine Intelligence 12 (1990) 913–917. [5] J.G. Dunham, Optimum uniform piecewise linear approximation of planar curves, IEEE Transactions of Pattern Analysis and Machine Intelligence 8 (1986) 67 –75. [6] H. Freeman, On the encoding of arbitrary geometric configurations, IRE Transactions of Electronics Computing 10 (1961) 260 –268. [7] S.C. Huang, Y.N. Sun, Polygonal approximation using genetic algorithms, Pattern Recognition 32 (1999) 1409–1420. [8] J. Hu, H. Yan, Polygonal approximation of digital curves based on the principles of perceptual organization, Pattern Recognition 30 (1997) 701 –718. [9] M.S. Kankanhalli, An adaptive dominant point detection algorithm for digital curves, Pattern Recognition Letters 14 (1993) 385–390. [10] U. Ramer, An iterative procedure for the polygonal approximation of plane curves, Computer Graphics and Image Processing 1 (1972) 244 –256.
Acknowledgements This paper is partially supported by National Science Council, ROC under grant no. NSC 83-0422-E-214-002.
W.-Y. Wu / Image and Vision Computing 21 (2003) 517–525 [11] B.K. Ray, K.S. Ray, Detection of significant points and polygonal approximation of digitized curves, Pattern Recognition Letters 13 (1992) 443–452. [12] A. Rosenfeld, E. Johnston, Angle detection on digital curves, IEEE Transactions of Computers 22 (1973) 875– 878. [13] A. Rosenfeld, J.S. Weszka, An improved method of angle detection on digital curves, IEEE Transactions of Computer 24 (1975) 940–941. [14] P.L. Rosin, G.A.W. West, Segmentation of edges into lines and arcs, Image and Vision Computing 17 (1989) 109–114. [15] J. Sklansky, V. Gonzalez, Fast polygonal approximation of digitized curves, Pattern Recognition 12 (1980) 327–331. [16] C.H. Teh, R.T. Chin, On the detection of dominant points on digital curves, IEEE Transactions of Pattern Analysis and Machine Intelligence 11 (1989) 859– 872. [17] D.M. Tsai, Boundary-based corner detection using neural networks, Pattern Recognition 29 (1996) 85–97.
525
[18] K. Wall, P.E. Danielsson, A fast sequential method for polygonal approximation of digitized curves, Computer Vision, Graphics, and Image Processing 28 (1984) 220– 227. [19] M.J. Wang, W.Y. Wu, L.K. Huang, D.M. Wang, Corner detection using bending value, Pattern Recognition Letters 16 (1995) 575–583. [20] W.Y. Wu, M.J. Wang, Detecting the dominant points by the curvature-based polygonal approximation, CVGIP: Graphical Models and Image Processing 55 (1993) 79– 88. [21] Y. Xiao, J.J. Zhou, H. Yan, An adaptive split-and-merge method for binary image contour data compression, Pattern recognition Letters 22 (2001) 299–307. [22] P.Y. Yin, A tabu search approach to polygonal approximation of digital curves, International Journal of Pattern Recognition and Artificial Intelligence 13 (1999) 1061–1082. [23] Y. Zhu, L.D. Seneviratne, Optimal polygonal approximation of digitized curves, IEE Proceedings—Vision, Image Signal Processing 144 (1997) 8 –14.