Sei sulla pagina 1di 7

International Journal of Emerging Trends & Technology in Computer Science (IJETTCS)

Web Site: www.ijettcs.org Email: editor@ijettcs.org, editorijettcs@gmail.com Volume 1, Issue 2, July August 2012 ISSN 2278-6856

A NOVEL NEURAL NETWORK BASED APPROACH FOR THE CLASSIFICATION OF BETEL LEAVES
SANDEEP KUMAR.E
Department of Telecommunication Engineering JNN College of Engineering, Shimoga-577204 Karnataka State, India

Abstract: Betel leaves has its dominant place in Indian


commercial market. This is because of its high medicinal values as per the history of Ayurvedic medicinal system, also habit of people chewing betel leaves with areca nut. In Karnataka state of India, there are two species of betel leaves which are commercially recognized by local names Mysore betel leaf and Ambadi betel leaf. These leaves are separated and packed manually. In this context, here is a new approach using machine vision and machine intelligence blend; for classification of these two species of betel leaves leading to less human effort. This paper uses image processing for machine vision where the leaf features such as width, gray histogram and color histogram is extracted. Machine intelligence part uses Neural Networks with back propagation algorithm. Keywords: Ayurvedic medicinal system, Mysore Betel leaf, Ambadi betel leaf, machine vision, machine intelligence, neural network.

leaves are beneficial in the treatment of nervous pains, nervous exhaustion and debility. Betel leaf has analgesic and cooling properties, instantly relieves constipation. Local application of the leaves is effective in treating sore throat. The application of leaves smeared with oil is said to promote secretion of milk when applied on the breasts during lactation and many more. Hence there is a sudden requirement to grow these plants and improve them commercially. This research work is a step towards automatic separation of the betel leaf species such as Mysore leaf and Ambadi leaf for further processing and packing. The work consists of two parts: machine vision and machine intelligence. The machine vision part uses image processing where the features such as width, color histogram and gray histogram are extracted. These parameters are fed to the machine intelligence part which uses artificial neural networks as the tool for the classification.

1. INTRODUCTION
The scientific name of betel leaf is Piper betle, belonging to the family Piperaceae. These leaves are well known as Vellya dele in Karnataka and Paan in other places of India. The betel plant is a slender, aromatic creeper, rooting at the nodes. The branches of the plant are swollen at the nodes. The plant has alternate, heartshaped, smooth, shining and long-stalked leaves, with pointed apex. It has five to seven ribs arising from the base; minute flowers and one-seeded spherical small berries. The use of betel leaf can be traced as far back as two thousand years. It is described in the most ancient historic book of Sri Lanka, Mahavasma, written in Pali. Betel is a native of central and eastern Malaysia. It spread at a very early date throughout tropical Asia and later to Madagascar and East Africa. In India, it is widely cultivated in Tamil Nadu, Madhya Pradesh, West Bengal, Orissa, Maharashtra and Uttar Pradesh. Offering betel morsel (pan-supari) to guests in Indian subcontinent is a common courtesy. Betel leaves has many medicinal properties, some of them are: It is useful in arresting secretion or bleeding and is an aphrodisiac. Its leaf is used in several common household remedies, helps in easing urination. Betel Volume 1, Issue 2 July-August 2012

2. RELATED WORK
This is a new approach for the classification of leaves belonging to the same botanical family. This in fact was a difficult work. Researchers have proposed methods to find the area of betel leaves [4]. Many others have proposed methods to classify leaves based on leaf features such as shape, texture as such [3] [8] [9] [11]. But specifically for betel leaf species has not been done. Hence this a new approach for the classification of betel leaves using neural networks.

3. PROPOSED METHODOLOGY
This section involves the various steps and techniques used in the process of separation of the leaves. 3.1 Image acquisition The image of betel leaves where taken from a 5 mega pixel camera, keeping 15 cms distance in between leaf and camera. All the images where taken from top view with white background. Page 10

International Journal of Emerging Trends & Technology in Computer Science (IJETTCS)


Web Site: www.ijettcs.org Email: editor@ijettcs.org, editorijettcs@gmail.com Volume 1, Issue 2, July August 2012 ISSN 2278-6856
3.2 Image samples In this work, seventy image samples were taken from Mysore betel leaf species. From which, fifty were used for the training neural network and nineteen samples were taken as the test samples. Seventy image samples were taken from Ambadi betel leaf species. From which, fifty were used for training neural network and eighteen samples were taken as test samples. The leaf images of both species are shown in Figure-1. 3.3 Devised Methodology In this work two species of betel leaves: Mysore betel leaf and Ambadi betel leaf is considered. The image is captured using a 5MP camera. Later in the pre-processing stage it is resized to 200 X 300 resolutions, which is as per our requirement. Also image is processed for the noise removal. Then the first information i.e., color histogram is extracted. Then the color image is converted to its equivalent grayscale image and gray histogram of the leaf is calculated. This is the second parameter useful to notify the leaf intensity. This grayscale image is converted to its equivalent binary image and width of the leaf is calculated. This is the third parameter. Once we extract all these three parameters in the feature extraction stage, we feed these parameters as the training parameters for the classifier, which is an Artificial Neural Network using Back propagation algorithm. The system block diagram is shown in Figure-2.

Figure 2 System Block diagram

4. FEATURE EXTRACTION
This section deals with the three important features which are extracted from the betel leaves which are used for their classification. 4.1 Width of leaf

Figure 3 Width of the leaf Width is one of the important parameters which give a fine differentiation between the two leaf species. As one can notice in Figure 1, Mysore betel leaf is broader and width of the leaf is more compared with the Ambadi leaf. Hence this section makes an attempt to extract this information.

Figure 1 (a) Ambadi betel leaf. (b) Mysore betel leaf.

Volume 1, Issue 2 July-August 2012

Page 11

International Journal of Emerging Trends & Technology in Computer Science (IJETTCS)


Web Site: www.ijettcs.org Email: editor@ijettcs.org, editorijettcs@gmail.com Volume 1, Issue 2, July August 2012 ISSN 2278-6856
Algorithm: Step 1: Start Step 2: Read the image Step 3: Convert the color image to black and white image Step 4: Starting from first row first pixel i.e., (1, 1) move column wise until we get a black pixel or till column end is reached. Step 5: If black pixel is encountered, load the pixel position to variables say (h, b). This is co-ordinate 1; Go to Step 7 else Go to Step 6. Step 6: If black pixel not encountered and we have reached to the column end, increment row count and move to the next row and start moving column wise and go to Step 5. Step 7: Start from last row first pixel i.e., (200, 1) move column wise until we get a black pixel or till row end is reached. Step 8: If black pixel is encountered, load the pixel position to variables say (h1, b1). This is coordinate; Go to Step 10 else Go to Step 9. Step 9: If black pixel not encountered and we have reached to the column end, increment row count and move to the next row and start moving column wise and go to Step 8. Step 10: Calculate the Euclidean distance. Let this be variable Width. Step 11: Stop. Euclidean distance (in this case width) is calculated by the formula: Step 4: Add the three histograms values and find the average to get the overall image color histogram. Step 5: Stop 4.3 Gray Histogram Referring to Figure-4 one can notice that the there is minute intensity difference in the two images. i.e., Mysore betel leaf is darker compared to the Ambadi betel leaf. Hence this section extracts this information from the leaf. The gray histograms extracted can be seen referring to Figure-5 and Figure-8. Algorithm: Step 1: Start Step 2: Acquire the leaf image. Step 3: Convert the RGB image to its equivalent grayscale image. Step 4: Calculate the histogram value of this image. Step 5: Stop

Euclidean distance (width) = [(h1-h) ^2 + (b1-b) ^2] ^ 0.5 Where, (h, b) Co-ordinate 1. (h1, b1) Co-ordinate 2. 4.2 Color Histogram Referring to Figure-1, the leaf color of Ambadi species is light green and that of the Mysore species is dark green. Hence this section of the work extracts this color variation of both the leaves by calculating the entire image color histogram. The color histogram extracted can be seen referring to Figure-6, Figure-7, Figure-9 and Figure-10. Algorithm: Step 1: Start Step 2: Acquire the leaf image Step 3: Calculate the green histogram value, blue histogram value and red histogram value separately of the image. Volume 1, Issue 2 July-August 2012

Figure 4 Gray scale image of (a) Mysore Betel leaf (b) Ambadi betel leaf. Color histogram and gray histogram of the image cannot be fed directly to the neural network. Hence the histogram is reduced to a single value by applying Euclidean distance formula. For the gray scale image, histogram is calculated and then normalized; the distance of the histogram from the origin of histogram plot is calculated this is fed to the neural network. Since the gray histogram of Mysore betel leaf is nearer to the origin compared to the Ambadi betel leaf. Similarly we apply for the color Page 12

International Journal of Emerging Trends & Technology in Computer Science (IJETTCS)


Web Site: www.ijettcs.org Email: editor@ijettcs.org, editorijettcs@gmail.com Volume 1, Issue 2, July August 2012 ISSN 2278-6856
image also. In this case, we calculate the histogram of the red plane, blue plane and green plane separately then normalize it, then distance of the histogram is calculated separately for then three planes and average of the three is calculated. This is fed as color histogram value for the neural networks. One can notice that even the color histogram of Mysore betel leaf is nearer to the origin of the plot than the Ambadi betel leaf [3]. Hence the width, color histogram and the gray histogram are the three important features that differentiates these two betel leaf species and these parameters are used to train the classifier. 4.4 System algorithm Step 1: Start Step 2: Read leaf image Step 3: Calculate color histogram Step 4: Convert color image to gray scale image Step 5: Calculate gray histogram Step 6: Convert the gray image to black and white image Step 7: Calculate width of the leaf Step 8: Input these values to the trained neural network Step 9: Compare the output, whether positive or negative Step 10: If positive display Ambadi Betel leaf, if negative display Mysore Betel leaf. Step 11: Repeat Step 2 to Step 10 for all test images Step 12: Stop

Figure 7 Red and Blue Histograms of Ambadi Betel Leaf

Volume 1, Issue 2 July-August 2012

Page 13

International Journal of Emerging Trends & Technology in Computer Science (IJETTCS)


Web Site: www.ijettcs.org Email: editor@ijettcs.org, editorijettcs@gmail.com Volume 1, Issue 2, July August 2012 ISSN 2278-6856 5. CLASSIFICATION OF LEAVES
As a classifier this rejuvenated work uses Artificial Neural Networks. These Networks can be likened to collections of identical mathematical models that emulate some of the observed properties of biological nervous systems and draw on the analogies of adaptive biological learning. The key element of an Artificial Neural Network is its structure. It is composed of a number of interconnected processing elements tied together with weighted connections, which take inspiration from biological neurons. Learning like in a biological system takes place through training, or exposure to a set of input and output data where the training algorithm adjusts the weights iteratively. Artificial Neural Networks are good pattern recognition engines and robust classifiers, with the ability to make decisions about imprecise input data. What is needed is a set of examples that is representative of all the variations in those two types of leaf species. This neural network is trained using Back Propagation Algorithm. Figure-11 shows the block diagram representation of an Artificial Neural Network.

Back Propagation Algorithm: Back propagation was created by generalizing the Widrow-Hoff learning rule to multiple-layer networks and nonlinear differentiable transfer functions. Input vectors and the corresponding target vectors are used to train a network until it can approximate a function, associate input vectors with specific output vectors, or classify input vectors in an appropriate way as defined by you. Networks with biases, a sigmoid layer, and a linear output layer are capable of approximating any function with a finite number of discontinuities. The term back propagation refers to the manner in which the gradient is computed for nonlinear multilayer networks. There are a number of variations on the basic algorithm that are based on other standard optimization techniques, such as conjugate gradient , Newton methods so on. Properly trained back propagation networks tend to give reasonable answers when presented with inputs that they have never seen. Typically, a new input leads to an output similar to the correct output for input vectors used in training that are similar to the new input being presented. This generalization property makes it possible to train a network on a representative set of input/target pairs and

Figure 9: Red and Blue Histograms of Mysore Betel Leaf Volume 1, Issue 2 July-August 2012

Page 14

International Journal of Emerging Trends & Technology in Computer Science (IJETTCS)


Web Site: www.ijettcs.org Email: editor@ijettcs.org, editorijettcs@gmail.com Volume 1, Issue 2, July August 2012 ISSN 2278-6856
get good results without training the network on all possible input/output pairs. Mysore betel leaf In the following scenario there is one input vector for the feed forward network with three elements: p= [width; color; gray]; Where, width Width of leaf parameter. color Color histogram parameter. gray Gray histogram parameter. Inputs color and gray are in the range [0 1] and width is in the range [1 200].Hidden layer has 25 neurons and the output layer has a single neuron. The transfer function in the hidden layer and the output layer are tan-sigmoid. The training function is trainscg- Scaled conjugate gradient algorithm. Training function, Scaled conjugate gradient algorithm was developed by Moller and is designed to avoid the time-consuming line search. The basic idea is to combine the model-trust region approach with the conjugate gradient approach. The neural network is trained for +1 for Mysore betel leaf species and -1 for Ambadi betel leaf species. Ambadi betel leaf Test image 13 Test image 14 Test image 15 Test image 16 Test image 17 Test image 18 Test image 19 -0.6100 0.5810 -0.7809 0.6252 -0.9265 -0.9246 -0.2687

Out of 19 leaf images 14 were correctly identified as Mysore betel leaf. Hence the accuracy is 74%. Table 2: Results obtained for Ambadi betel leaf Leaf species Input test image Test image 1 Test image 2 Test image 3 Test image 4 Test image 5 Test image 6 Test image 7 Test image 8 Test image 9 Test image 10 Test image 11 Test image 12 Test image 13 Test image 14 Test image 15 Test image 16 Test image 17 Test image 18 Output obtained 0.1540 0.2712 0.7817 0.5611 0.5731 0.9573 0.4842 0.9667 0.6060 0.3399 -0.8439 -0.9913 0.2946 -0.6981 -0.9013 0.8443 -0.8879 0.6393

6. RESULTS AND DISSCUSSIONS


50 samples of Mysore leaf species and 50 samples of Ambadi leaf species were used to train the neural network. Epochs were set for 500. Learning rate was set for 0.5. The neural network was trained to -1 for Mysore betel leaf species and +1 for Ambadi leaf species. 19 samples of Mysore leaf images were given as the test images and 18 samples of Ambadi leaf images were given as the test images. The output of the neural network is tresholded for negative value for Mysore betel leaf and positive value for Ambadi betel leaf. The algorithm was coded and tested using MATLAB 2010. Table 1: Results obtained for Mysore betel leaf Leaf species Input test image Test image 1 Test image 2 Test image 3 Test image 4 Test image 5 Test image 6 Test image 7 Test image 8 Test image 9 Test image 10 Test image 11 Test image 12 Output obtained -0.1080 -0.5167 -0.5626 0.3779 0.1222 -0.4745 -0.8955 -0.2863 -0.7414 0.5460 -0.5958 -0.9530

Out of 18 leaf images 13 were correctly identified as Ambadi betel leaf. Hence the accuracy is 72%. Table 1 and Table 2 depict the results obtained. Here classification of leaves was a challenge, since they belong to the same family Piperaceae. The border pattern, the length, the vein pattern of both the leaf species remains same. The only difference observed was with respect to the width and the color. That too both the leaves are of green color. But one is light green and the other is little darker than the other. Also the difference in width, color and gray histograms values was also very less. With these limited ranged inputs successfully the network has been trained for the accuracy of 74% and 72%. With still more different sets of samples for training, one can get better accuracy.

Mysore betel leaf

7. CONCLUSION
This is an innovative approach ever done for the classification of betel leaves. The methodology uses a blend of machine vision and machine intelligence for Page 15

Volume 1, Issue 2 July-August 2012

International Journal of Emerging Trends & Technology in Computer Science (IJETTCS)


Web Site: www.ijettcs.org Email: editor@ijettcs.org, editorijettcs@gmail.com Volume 1, Issue 2, July August 2012 ISSN 2278-6856
precision agriculture. In machine vision part, image processing was used where the leaf features were extracted. In machine intelligence part neural network working on back propagation algorithm was used. Hence the work was successful with the accuracy of 74% and 72%. This is a small contribution towards agriculture and growing this medicinally valued precious plant species, which is moving towards extinction because of negligence now a days. [6] Chris Solomon and Toby Breckon, Fundamentals of Digital Image Processing- A practical approach with examples in Matlab. [7] R.C. Gonzalez, R. E. Woods and S. L. Eddins, Digital Image Processing, Prentice Hall, 2004. [8] Basavaraj Anami, J.D. Pujari, Rajesh.Yakkundimath Identification and Classification of Normal an Affected Agriculture/horticulture Produce Based on Combined Color and Texture Feature Extraction, International Journal of Computer Applications in Engineering Sciences, [VOL I, ISSUE III, SEPTEMBER 2011] [VOL I, ISSUE III, SEPTEMBER 2011] [9] Stephen Gang Wu, Forrest Sheng Bao, Eric You Xu, Yu-Xuan Wang, Yi-Fan Chang and Qiao-Liang Xiang4,A Leaf Recognition Algorithm for Plant Classification Using Probabilistic Neural Network [10] Abdul Kadir, Lukito Edi Nugroho, Adhi Susanto, Paulus Insap Santosa Leaf Classification Using Shape, Color, and Texture Features International Journal of Computer Trends and Technology- July to Aug Issue 2011. [11] P. Pattanasethanon and B. Attachoo, Thai botanical herbs and its characteristics: Using artificial neural network African Journal of Agricultural Research Vol. 7(2), pp. 344-351, 12 January, 2012. [12] MATLAB Neural Network toolbox. AUTHOR [1] Dr. R.C.Prajapati, I.F.S, APCCF & Member Secretary, KARNATAKA BIODIVERSITY BOARD, BIODIVERSITY OF KARNATAKA-At a Glance. [2] P. Guha, Betel Leaf: The Neglected Green Gold of India, J. Hum. Ecol., 19(2): 87-93 (2006). [3] Sandeep Kumar.E, LEAF COLOR, AREA AND EDGE FEATURES BASED APPROACH FOR IDENTIFICATION OF INDIAN MEDICINAL PLANTS, Indian Journal of Computer Science and Engineering (IJCSE), Vol. 3 No.3 Jun-Jul 2012. [4] Sanjay B Patil and Dr. Shrikant K Bodhe, Betel Leaf Measurement Using Image Processing, International Journal on Computer Science and engineering (IJSCE), Vol. 3 No. 7 July 2011. [5] Hamzah Ali, Genetic algorithm based approach in Artificial Neural Network for Pattern RecognitionM.tech Report, 2008-2009,Dept. of Information Science & Engineering, M.S Ramaiah Institute of Technology, Bangalore. Volume 1, Issue 2 July-August 2012 Page 16
Sandeep Kumar. E completed his Bachelor of Engineering in Telecommunication Engineering from JNN college of Engineering (Affiliated to Vishveshvaraya Technological University), Shimoga, Karnataka state, India. Presently he is working as Lecturer in Department of Telecommunication Engineering, JNN college of Engineering, Shimoga, Karnataka state, India with 3 years of teaching experience. He has handled subjects: C, C++, Data Structures, Optical Communication & networking. His area of Interest being machine vision and machine intelligence, towards precision agriculture. Published 2 papers on machine vision in national journal/ conference. Received many merit awards and scholarships during his carrier.

ACKOWLEDGEMENT
Author likes to thank his family for their valuable support through out his work. He likes to thank Dr. S.V Sathya Naryana, Professor, Dept. of Electronics and Communication Engineering, JNN College of Engineering, for his valuable guidelines in making this paper a success. Author likes to thank Mr. Sashikiran S, Asst. Professor, Dept. of Telecommunication Engineering, JNN college of Engineering. Author is grateful to Mrs. Veena K.N, Asst. Professor, Dept. of Telecommunication Engineering, JNN College of Engineering and Mr. Pawan Kumar M.P, Lecturer, Dept. of Information Science & Engineering JNN college of Engineering, for their support and advice through out this work. Also Author is thankful to the principal, JNN college of Engineering for his support and Co-operation through out this work.

REFERENCES

Potrebbero piacerti anche