<<

International Journal of Computer Science & CommunicationVol. 1, No. 2, July-December 2010, pp. 387-390 Fuzzy Edge Filter- and Feature Extraction Technique for Any JPEG Image

Neha Agrawal1, Rishabh Agrawal2 & Sushil Kumar1 1Technocrats Institute of Technology (T.I.T.), Bhopal, India 2National Productivity Council (NPC), New Delhi, India Email: [email protected], [email protected], [email protected]

ABSTRACT Edge detection is a terminology in image processing and , particularly in the areas of feature detection and feature extraction, to refer to algorithms which aim at identifying points in a image. This paper highlights the ways to detect edges at five different levels which will help in pattern recognition and feature extraction with the use of fuzzy logic a method well known in . The fuzzy edge filter technique is an operator introduced in order to simulate at a mathematical level the compensatory behavior in process of decision making or subjective evaluation. The following paper introduces such operators on hand of computer vision application and supported with MATLAB 7.5. Our fuzzy edge filter detects different classes of image pixels corresponding to gray level variation in the various directions. The goal in this case is to determine in which points in the image the first derivative of the gray level as a function of position is of high magnitude. By applying the variable threshold value to get the new output image, edges are formed in all arbitrary directions. Keywords: Edge Detection, Fuzzy Logic, Fuzzy Edge Filter, Feature Extraction, Threshold

1. INTRODUCTION membership functions. The output is presented again to Edges play quite an important role in many applications the values from 0-255 and then the black, white and edge of image processing, in particular for are detected. From the experience of the tested images in systems that analyze scenes of man-made objects under this study, it is found that the best result to be achieved controlled illumination conditions. During recent years, at the range black from zero to 126 gray values and from however, substantial research has also been made on 126 to 255 meaning is trace as white. computer vision methods that do not explicitly rely on edge detection as a pre-processing step.Most of the 2. METHODOLOGY traditional edge-detection algorithms in image For edge detection a set of nine pixels, part of a 3x3 or processing typically convolute a filter operator and the 5x5 window of an image to a set of fuzzy conditions which input image, and then map overlapping input image help to highlight all the edges that are associated with an regions to output signals which lead to considerable loss image. The fuzzy conditions help to test the relative in edge detection; however there is no such loss in the values of pixels which can be present in case of presence fuzzy based method described here. on an edge in a grayscale image [3]. The method described here uses a fuzzy based logic The 3 ×3 neighborhood of pixels about the center pixel model[1] with the help of which high performance is p5 as well as the four directions in which edges may achieved along with simplicity in resulting model. Fuzzy appear. The bi-directional summed magnitude differences logic helps to deal with problems with imprecise and in gray level between p5 and others according to the fuzzy vague information and thus helps to create a model for edge filter algorithm are. image edge detection as presented here displaying the accuracy of fuzzy methods in image processing. Edge detection of an image is white line as edges of the image on the black background. Generally grayscale image lies between 0-255 where 0 represents black moving toward white. The result images contribute the contours, the black and the white areas. From the side of the fuzzy construction, the input grays is ranged from 0-255 gray intensity, and according to the desired rules the gray level is converted to the values of the 388 International Journal of Computer Science & Communication (IJCSC)

The proposed approach begins by segmenting the 3. Fuzzy Edge Filter (Horizontal and Vertical) at images into regions using floating 3x3 binary matrixes Specified Threshold (Fig. 4). as shown below. A direct fuzzy inference system mapped 4. Fuzzy Edge Filter (45 degree) at Specified a range of values distinct from each other in the floating Threshold (Fig.5). matrix to detect the edges at all different levelsThe algorithm of edge detection of a JPEG image using fuzzy 5. Fuzzy Edge Filter (-45 degree) at Specified logic is as follows. Threshold (Fig.6). Algorithm: 6. Exit. Step 1: Select an input image. Step 2: Get convert the input image into Grayscale image. Step 3: Apply 3x3 pixel mask window to the image which are a set of fuzzy logic conditions at threshold value. Step 4: Get different features and patterns of edge detection on all five different levels at specified threshold. Step 5: Enter any one choice from 1-5 and also enter threshold value Step 6: Exit (level 6) Step 7: Apply same procedure on any image and get edge detected Fig. 2: Fuzzy Edge Filter at Automatic Threshold Step 8: End

Fig.3: Fuzzy Edge Filter at Specified Threshold

Fig.1: Gray Scale Image

3. EXPERIMENTAL ANALYSIS This paper gives a choice to get different edges on different threshold value with five different types of fuzzy edge filters applied on a gray scale image which considers the gradient as well as second derivative option at (fig. 1). Fuzzy edge filters applied on gray scale image are as follows: 1. Fuzzy Edge Filter at Automatic Threshold (Fig. 2). 2. Fuzzy Edge Filter at Specified Threshold (Fig.3). Fig. 4: Fuzzy Edge Filter (Horizontal and Vertical) at Specified Threshold Fuzzy Edge Filter-Edge Detection and Feature Extraction Technique for Any JPEG Image 389

The operator (fig.8)is a simple, quick to compute 2D spatial gradient measurement of a image.The operator consists 2x2 kernel detect the image at 45 and -45 degree .

5. RESULT ANALYSIS Edge Detection is a very important factor in image processing as it is use in variety of applications of machine vision and medical sciences.Various edge detection techniques like gradient methods (sobel ,prewitt,…) operator,second derivative(log) and canny operator these are either sensitive or time consuming computation and no satisfactory results though fuzzy edge filter at specified threshold is a better technique as it can be said as all technique with better result and according to the need. The fuzzy edge filter algorithm for image edge detection was tested for various images and the outputs were compared to the existing edge Fig.5: Fuzzy Edge Filter (45 degree) at Specified Threshold detection algorithms and it was observed that the outputs of this algorithm provide much more distinct marked edges at 45 and -45 degree which are useful for feature extraction and thus have better visual appearance than the ones that are being used. The sample output shown below in Fig.2(a-c) compares the “Sobel” Edge detection algorithm and “Robert” Edge detection algorithm the fuzzy edge filter pixel value algorithm is much better. It can be observed that the output that has been generated by the fuzzy method has found out the edges of the image more distinctly as compared to the ones that have been found out by the “Sobel” edge detection algorithm and Robert edge detection.Thus the Fuzzy edge filter algorithm provides better edge detection and has an exhaustive set of fuzzy conditions at specified threshold which helps to extract the edges with a very high feature extraction.

Fig.6: Fuzzy Edge Filter (-45 degree) at Specified Threshold

4. COMPARISON OF FUZZY EDGE FILTER WITH OTHER EDGE DETECTION ALGORITHMS For estimating image gradients from the input image different gradient operators can be applied. Some well- known edge detection algorithms are Sobel edge detection and Roberts cross edge detection algorithm based on edge filter. For better result analysis fuzzy edge filter at all the levels are recognized for edge detection and feature extraction are compared by Sobel and Roberts edge detection algorithms [2]. These are gradient methods.As Sobel detection operator consists a pair of 3x3 convolution kernel designed to get edges at horizontal and vertical way relative to pixel grid. The output compared with fuzzy edge filter at minimum Fig. 7: Sobel Edge Detection threshold is shown in fig.7. 390 International Journal of Computer Science & Communication (IJCSC)

over the other algorithms which has tremendous scope of application in various areas of image processing. The image edge detection using fuzzy edge filter algorithm give alternate methods that has been successful in obtaining the edges that are present in an image after the implementation and execution of the algorithms with various sets of images. Feature extraction of an image is very well extracted by fuzzy edge filter 45 and -45 degree at specified threshold.

REFERENCES [1] Abdallah A. Alshennawy, and Ayman A. Aly Edge Detection in Digital Images using Fuzzy Logic Tecniques, IEEE Tran. [2] Shashank Mathur, Anil Ahlawat in, ”Application of Fuzzy Logic in Edge Detection”. [3] “Competitive Fuzzy Edge Detection“, Lily Rui Liang, Fig.8: Roberts Cross Edge Detection Carl G. Looney Available at Computer Science Web. [4] H.G. Barrow and J.M. Tenenbaum (1981) “Interpreting 6. CONCLUSION Line Drawings as Three-dimensional Surfaces”, Artificial Fuzzy Edge filter for image processing is a powerful tool Intelligence, 17, Issues 1-3, Pages 75-116. form to get expert knowledge edge and the combination [5] T. Lindeberg (2001) “Edge Detection”, in M. Hazewinkel of imprecise information from five different sources. The (Editor), Encyclopedia of Mathematics, Kluwer/Springer, designed fuzzy rules are an attractive solution to improve ISBN 1402006098. the quality of edges as much as possible and give better [6] T. Lindeberg (1998), “Edge Detection and feature extraction. One past drawback of this type of with Automatic Scale Selection”, International Journal of algorithm was that the image formation is get saturated Computer Vision, 30, 2, pages 117—154. at a number which is vary for every method after that [7] M. Darwish and A. K. Jain, “A Rule Based Approach for also it give number of edge formation at every value of Visual Pattern Inspection “, IEEE Trans. on Pattern Analysis and Machine Intelligence, 10, No. 1, pp. 56-68, January 1988. level and threshold.In this paper, the fuzzy edge filter algorithm is to find the edge associated with any image [9] G. Maitre, H. Hugli, F. Tieche and J. P. Amann, “Range has been introduced which has been instrumental to Based on Function Approximation”, Published at ISPRS90, Zurich, Sept. 1990. abridge the concepts of artificial intelligence and image processing. Comparisons were made amongst the [10] Md. Shoiab Bhuiyan, Yuiji Iwahori, and Akira Iwata., “Optimal Edge Detection Under Difficult Imaging various other edge detection algorithms that have Conditions”, Technical Report, Educational Center for already been developed and displayed the accuracy of Information Processing and Dept. of Electrical and the edge detection using the fuzzy edge filter algorithm Computer Engineering, Nagoya Institute of Technology, Japan.