6

Click here to load reader

[IEEE 2011 International Conference on Wavelet Analysis and Pattern Recognition (ICWAPR) - Guilin, China (2011.07.10-2011.07.13)] 2011 International Conference on Wavelet Analysis

Embed Size (px)

Citation preview

Page 1: [IEEE 2011 International Conference on Wavelet Analysis and Pattern Recognition (ICWAPR) - Guilin, China (2011.07.10-2011.07.13)] 2011 International Conference on Wavelet Analysis

A NEW ALGORITHM FOR EDGE DETECTION BY HYBRID DIFFERENTIAL EVOLUTION ALGORITHM

YONG-DONG HUANG, HONG-HONG WANG

Institute of Information and System Science, Beifang University of Nationalities, Yinchuan 750021, China E-MAIL: [email protected], [email protected]

Abstract: In this paper, a new algorithm for edge detection was

proposed. This method inspired by A. Bastürk’s thoughts was formed, who proposed efficient edge detection using one neighbor CNN cloning template optimized by differential evolutionary algorithm. In order to consider interaction of more cells, and overcome solution’s precocious phenomena, this paper extend one neighbor to two neighbors, and adopt hybrid differential evolutionary algorithm with a disturbance mutation operator optimizing two neighbors CNN cloning template. Through the general test images, simulation experiments indicate that the proposed method comparing with traditional edge detection methods has obvious advantage.

Keywords: Cellular neural networks; Cloning template; Basic

differential evolutionary algorithm; A disturbance mutation operator; Edge detection

1. Introduction

Image edges carry out most of information, so edge detection is very important in image processing, Edges typically exist as irregular structures and imbalance phenomenon in an image, named singularity or mutation points in signal. These points give the rough sketch of an image. Usually these contours provide important features conditions for image processing. So we need to detect and extract edges for an image. Therefore, the studies of effective edge detective algorithms have a very important significance.

The traditional methods of edge detection are commonly used including Roberts Sobel PrewittLaplzcian LOG Canny and so on[1-6]. But these classical edge detection methods are not ideal when considering both of edge detection accuracy and the anti-noise, and lost many details of the image in the process at the same time. Wavelet transform has time-frequency localization properties and multi-resolution ability, S. Mallat ]7[ and

some other people proposed the theory of wavelet multi-scale edge detection. Then, image edge detection by using wavelet transform becomes wide. But for an image of line singularities prominence, the results by using wavelet transform can not achieve optimal results. In 2003, J.Zhao ]8[ proposed a new algorithm of edge detection for an image including noise. The simulate experiment showed that this method has a certain practicality. But this method only involves one neighbor elements on the influence of a cellular neural network cloning template. In 2009, A. Bastürk ]9[ proposed an efficient edge detection algorithm using a cellular neural network optimized by differential evolution algorithm, and achieved a better result. However, this algorithm has some deficiencies. One is that this method only involves one neighbor elements for the influence of cloning template, but in practice, we also need to think about the influence of more neighbor elements, such as two or three neighbor; The other is that authors only using cloning template optimized by using basic differential evolution algorithm. It is very known that the fault of basic DE is precocious phenomenon, so we can use DEDMO algorithm which is differential evolution algorithm with a disturbance mutation operator [10].

Following this, this paper proposes edge detection in digital image using a cellular neural network cloning template for two neighbor optimized by hybrid differential evolutionary algorithm with a disturbance operator.

This paper is structured as follow: Section 2 gives a brief introduction on architecture of the CNN. And section 3 gives an introduction on basic DE algorithm. Section 4 presents hybrid DE algorithm. In section 5, CNN cloning template (for 2 neighbors) learning via hybrid DE algorithm with a disturbance mutation operator is presented. Experimental studies are conducted in section 6, including comparisons of the performances of proposed method and well known edge detection operators such as SobelPrewitt Robert and Canny for binary and gray level test images. Conclusions are drawn in Section 7.

292011 IEEE978-1-4577-0282-2/11/$26.00 ©

Proceedings of the 2011 International Conference on Wavelet Analysis and Pattern Recognition, Guilin, 10-13 July, 2011

Page 2: [IEEE 2011 International Conference on Wavelet Analysis and Pattern Recognition (ICWAPR) - Guilin, China (2011.07.10-2011.07.13)] 2011 International Conference on Wavelet Analysis

2. Architecture of the cellular neural network

In this section, we can briefly describe the model of a two-dimensional CNN which is a locally interconnected analog processor array.

Consider a NM × cellular neural network, having NM × cells arranged in M rows and N columns. We

call the cell on the i th row and the j th column cell ),( ji ,and denote it by ),( jiC .Now let us define what we mean by a neighborhood of ),( jiC .

The r -neighborhood of a cell ),( jiC , in a CNN is defined by

,|||,max(|:),({),( rjiiklkCjiN r ≤−−= 1 , 1 }k M l N≤ ≤ ≤ ≤ 1

where r is a positive integer number. In this paper, let 2=r .Sometimes, we call the 2=r

neighborhood a “ 55× ” neighborhood. Now, we give the circuit equations of a cell.

State equation:

2 2( , ) ( , ) ( , ) ( , )ij ij ij kl kl kl kl

C k l N i j C k l N i jx z x a y b u

∈ ∈

= − + +� ��

MjMi ≤≤≤≤ 1,1 . (2) Output equation:

|)1||1(|21 −++= ijijij xxy ,

MjMi ≤≤≤≤ 1,1 (3) Input equitation:

ijij Eu = MjMi ≤≤≤≤ 1,1 (4) Constraint equations: 1|)0(| ≤ijx , MjMi ≤≤≤≤ 1,1 (5)

1|| ≤iju , MjMi ≤≤≤≤ 1,1 (6) Parameter assumptions:

),;,(),;,( jilkAlkjiA = , ),;,(),;,( jilkBlkjiB = ,

MjMi ≤≤≤≤ 1,1 (7) where input, threshold, state and output are denoted by

iju , ijz , ijx , ijy .Also each ijx cell has the feed-forward

synapses as kl klb u that is the input and has the feed-back

synapses as kl kla y that is the output of each neighbors

cells. So, the performance for image processing of CNN

with 5 5× neighborhood can be decided by feedback

matrix { } 5 5ijA a R ×= ∈ , control matrix { } 5 5

ijB b R ×= ∈ ,

which all have twenty-five entries, and one bias. So the total is 51. In order to use the optimization algorithm of section 4, we can write these 51 real numbers as a array v in Eq.(8) [ ]1 2 25 1 2 25v a a a b b b z= � � (8)

A completely stable CNN 5 5× can be formed by choosing the cloning template as

1 2 3 4 5

6 7 8 9 10

11 12 13 14 15

16 17 18 19 20

21 22 23 24 25

a a a a aa a a a a

A a a a a aa a a a aa a a a a

� �� �� �� �=� �� �� �� �

1 2 3 4 5

6 7 8 9 10

11 12 13 12 11

10 9 8 7 6

5 4 3 2 1

a a a a aa a a a aa a a a aa a a a aa a a a a

� �� �� �� �=� �� �� �� �

(9)

and

1 2 3 4 5

6 7 8 9 10

11 12 13 14 15

16 17 18 19 20

21 22 23 24 25

b b b b bb b b b b

B b b b b bb b b b bb b b b b

� �� �� �� �=� �� �� �� �

1 2 3 4 5

6 7 8 9 10

11 12 13 12 11

10 9 8 7 6

5 4 3 2 1

b b b b bb b b b bb b b b bb b b b bb b b b b

� �� �� �� �=� �� �� �� �

(10)

3. Differential evolution algorithm

Basic differential evolutionary algorithm is a simple and effective evolutionary algorithm based on real-coded;

30

Proceedings of the 2011 International Conference on Wavelet Analysis and Pattern Recognition, Guilin, 10-13 July, 2011

Page 3: [IEEE 2011 International Conference on Wavelet Analysis and Pattern Recognition (ICWAPR) - Guilin, China (2011.07.10-2011.07.13)] 2011 International Conference on Wavelet Analysis

its main steps include mutation, crossover and selection which are described briefly in the following.

(1) Mutation operator The mutation’s element is the vector in parent

generation. Each differential vector is generated by two different individuals

1 2,G G

r rx x from the parent generation.

The differential vector is defined as1 21,2G Gr rD x x= − . The

mutation operation is defined as: 1 2ˆ ( )G G G G

i i r rx x F x x= + × − (11) Where, ˆG

ix is the mutated individual, Gix is the parent

individual,1

Grx ,

2Grx , G

ix are three different individuals.

F is called mutation constant, which presents the degree of the differential vector influence the next generation individual. The value of F has an important influence on the performance of the algorithm. If the value of F is too large, the convergence of the algorithm becomes slow. If the value of F is too small, the diversity of the population reduces. So the algorithm traps into local optimum easily. The value of F is usually between 0 and 2.

(2) Crossover operator A trial vector is generated by the individual ˆG

ix and tix , through the following scheme:

1 ˆ , () ;, .

GjiG

ji Gji

x rand CRU

x otherwise+ ≤= �

� (12)

Where, ( )rand is a random number within [0,1] , {1,2, , }j m∈ � , m is the dimension of the decision

vector, CR is a crossover constant. The value of CR is larger, the contribution of ˆG

ix to ix is greater, the speed of the evolution is faster, the algorithm falls into local optima easier. The value of CR is smaller, the contribution of G

jix to ix is greater, the diversity maintain is easier. It shows that, the population diversity maintain and the algorithm convergence speed improve are contradictory. The value of CR is usually between 0 and 1. (3) Choose operator

To decide whether the trial vector 1tiU + should be a

member of the population comparing the next generation, it is compared to the corresponding target vector t

ix , and the greedy selection strategy is adopted in DE. The selection

operator is as following 1 1

1 , ( ) ( )

,

t t ti i it

i ti

U f U f xx

x otherwise

+ ++ <= �

� (13)

where f is the fitness function.

4. Hybrid differential evolutionary algorithm

As we all known, basic DE algorithm can be easy to appear later stagnation phenomenon. In order to overcome this phenomenon, we can introduce a disturbance mutation operator, which is described as follows:

(1 (0.5,1))t tij bestU x N= × + (14)

where (0.5,1)N is the normal distribution random number, tbestx is the t th optimal position.

In the proceeding of evolutionary, if rrand p< , we use the disturbance mutation operator, otherwise, the differential evolutionary algorithm is adopted, where rp is disturbance probability.

5. CNN cloning template learning by hybrid differential evolution algorithm

In literature [9], an edge detection operator in digital mages using a cellular neural network optimized by differential evolution (DE) algorithm is proposed. In this paper, we further investigate edge detection employing DE algorithm and CNN technique. In order to improve premature phenomenon of DE, we employ hybrid differential evolutionary algorithm with a disturbance operator. And considering the actual needs, we extend one neighbor to two neighbor, that is 5 5× neighborhood. Because of this, we call our method CNN 5 5× . The flow chart of this algorithm is shown in Fig.1.

Figure 1.Flow Chart of edge detection

In order to illustrate the effectiveness of the proposed method .Firstly, we will use a binary training image with small size showing in Fig.2. Fig.2. (a) shows the original

31

Proceedings of the 2011 International Conference on Wavelet Analysis and Pattern Recognition, Guilin, 10-13 July, 2011

Page 4: [IEEE 2011 International Conference on Wavelet Analysis and Pattern Recognition (ICWAPR) - Guilin, China (2011.07.10-2011.07.13)] 2011 International Conference on Wavelet Analysis

training image with 64 64× size. Fig.2. (b) shows the ideal edge detection image which can be obtained by using intensity differences in the original training image.

(a) (b)

Figure 2. The training images. (a) Original training image. (b) Ideal edge image.

So far, we haven’t ascertained the time step and the iteration values, but they are also important in CNN systems. In order to achieve good results, we also optimize the time step and the iteration values like literature [9] doing. So, parameters in Eq.(8) for the optimization algorithm has 29 entries. That is

1 2 13 1 2 13[ Timestep Iteration]v a a a b b b z= � � (15) The algorithm can involve parameters as follows:

the dimension of the decision vector m is 29, the population size is 20, the maximum iteration number is 10. the mutation constant F is 0.05,the crossover constant CR is 0.7, the disturbance probability rp is 0.1

and initial state (0)ijx is zero which is important for edge detection of CNN.

6. The simulation results and analysis

For evaluating performance of the proposed CNN 5 5× edge detector, detailed edge detection experiments are performed with four different test images for the test. To compare the performance of the proposed CNN 5 5× operator and four other popular competitive edge detectors (Sobel, Robert, Prewitt, and Canny) are used. Simulation experiment results are showing in Fig.3-Fig.6.

Now single out simulation experiment results of the Lena image, because it is the matlab classic digital image, and also is easily to find. The optimized template ( , ,a b z ), timestep, and iteration values given below, respectively:

7.5706 0.4510 11.8623 4.0636 13.0093

3.1146 7.8552 0.7618 8.7527 7.4657

3.8907 4.9005 5.1761 4.9005 3.8907

7.4657 8.7527 0.7618 7.8552 3.1146

13.0093 4.0636 11.8623 0.4510 7.5706

A

− − − − −

= − −

− − − − −

� �� �� �� �� �� �� �� �

,

10.9703 5.2886 3.8253 14.5763 0.7017

2.2664 3.2662 2.9064 4.2663 13.2661

4.1079 12.4116 1.4223 12.4116 4.1079

13.2661 4.2663 2.9064 3.2622 2.2664

0.7017 14.5763 3.8253 5.2886 10.9703

B

− −

= − − −

− −

� �� �� �� �� �� �� �� �

1.4287, Timestep = 2.8423, Iteration = 4.z = (14)

Experimental results are described below: (1) Fig.3 shows the results of the Lena image edge

detection. Apparently CNN 5 5× method is more beautiful than the remaining four methods, whether in the hat texture, the brim, the hair and the facial features as well as in the backgrounds which are quite fluent and clear.

(2) Fig.4 shows the results of the Cameraman image edge detection. In the vision of building, church and sky and so on, also grassland detection aspects, the detection result of CNN 5 5× is obviously better than Prewitt, Sobel, and Robert. On the grass aspect, the detection result of Canny operator is disjointed. It also needs to point out that the method of CNN 5 5× can detect the protagonist's hair but the Canny operator cannot. What’s more important is that the detection result of CNN 5 5× method is obvious in hand and clothes button detection. At last, we have to point out that the method of CNN 5 5× can detect the two buildings, but the Canny operator can only detect one of the buildings.

(3) Fig.5 shows the results of the House image edge detection. Apparently, CNN 5 5× method is rather better than other methods, because they can not test all lines in the top of the house. But in the eaves, the windows, the bricks and corner etc, the results of Canny operator are significantly inferior the CNN 5 5× algorithms. The result of the CNN 5 5× method is the best. If we take the image magnification, we can even clearly see bricks arrangement of the house.

(4) Fig.6 shows the results of texmos3.s512 figure (popular test image from USC-SIPI) edge detection. While Sobel and Prewitt operators almost have the same performance, but worse than the performance of Robert operator, they all have some irregularities and discontinuations. Apparently, CNN5 5× method and the Canny operator are better than the effect of the other methods. Although the Canny operator can detect the diagrams and show all the edges as well as CNN 5 5× operator, the brightness is significantly weaker.

32

Proceedings of the 2011 International Conference on Wavelet Analysis and Pattern Recognition, Guilin, 10-13 July, 2011

Page 5: [IEEE 2011 International Conference on Wavelet Analysis and Pattern Recognition (ICWAPR) - Guilin, China (2011.07.10-2011.07.13)] 2011 International Conference on Wavelet Analysis

Input image Sobel Prewitt

Robert Canny CNN 5 5×

Figure 3. Lena image

Input image Sobel Prewitt

Robert Canny CNN 5 5×

Figure 4. Cameraman image

Input image Sobel Prewitt

Robert Canny CNN 5 5×

Figure 5. Cameraman image

Input image Sobel Prewitt

Robert Canny CNN 55×

Figure 6. Texmos3.s512 image

7. Conclusions

As we all know, edge detection is one of the most important and difficult steps in image processing and pattern recognition systems. And it is also an old, important and challenging subject. But it cannot achieve expected results, when we process image by using classical edge detectors, such as Sobel, Prewitt, Robert, and Canny. So, our intention is to tackle this subject.

In this paper, an efficient edge detection employing CNN with two neighbor and differential evolution algorithm with a disturbance mutation operator is investigated. The satisfactory results can be achieved by choosing more suitable templates among a few experiments. From the simulation results, the method of this paper shows excellent performance in detecting the details in images. Therefore, it is more suitable for high definition image processing. In the further, it is necessary to think about the influence of noise, because noise is a universal phenomenon in acquisition, transmission and processing of image, which can reduce the quality of image, seriously.

Acknowledgements

This work was supported by the National Science Foundation of China (Grant 10961001), the Key Project of Chinese Ministry of Education (Grant No.10961001) and the High School Science Foundation of Ningxia High (Grant No.0961001).

References

[1] Roberts, L. G., “Machine perception of 3-D solids” ser. Optical and Electro-Optical Information Processing. MIT Press,1965.

33

Proceedings of the 2011 International Conference on Wavelet Analysis and Pattern Recognition, Guilin, 10-13 July, 2011

Page 6: [IEEE 2011 International Conference on Wavelet Analysis and Pattern Recognition (ICWAPR) - Guilin, China (2011.07.10-2011.07.13)] 2011 International Conference on Wavelet Analysis

[2] Sobel, I., “Neighbourhood coding of binary images fast contour following and general array binary processing”, Computer Graphics and Image Processing, Vol 8, pp.127–135, 1978.

[3] Prewitt, J. M. S., “Object enhancement and extraction, picture processing and psychopictorics”, Academic Press, New York, 1970.

[4] Berzins, V., “Accuracy of laplacian edge detectors”, Computer Vision, Graphics, and Image Processing, Vol 27,pp. 195–210, 1984.

[5] Huertas,A., Medioni ,G., “Detection of intensity changes with subpixel accuracy using laplacian-gaussian masks”, IEEE Transactions on Pattern Analysis and Machine Intelligence, Vol 8(5),pp.651–664, 1986.

[6] Canny, J., “A computational approach to edge detection”, IEEE Transactions on Pattern Analysis and

Machine Intelligence, PAMI-8, No.6, pp.679–698, 1986.

[7] Mallat,S, Zhong, S., ”Characterization of signals from multiscale edges”, IEEE Transactions on Pattern Analysis and Machine Intelligence, Vol 14,N0.6,pp. 710-732,1992.

[8] Zhao J., Wang H., and Yu, D., “A new approach for edges detection of noisy image based on CNN”, Int.J. Circ. Theor.Appl., Vol 31, pp. 119-131, 2003.

[9] Bastürk A., and Enis G., “Efficient edge detection in digital images using a cellular neural optimized by differential evolution algorithm”, Expert Systems with Application Vol 36, pp.2645-2650, 2009

[10] Wang, Y.N, Wu, L. H., and Yuan, X.F., “multi-objective self-adaptive differential evolution with elitist archive and crowding entropy-based diversity measure”, Verlag: Springer, 2009.

34

Proceedings of the 2011 International Conference on Wavelet Analysis and Pattern Recognition, Guilin, 10-13 July, 2011