Keywords

1 Introduction

Plants are the basis of all living things on earth, serving as oxygen, food, shelter, medicine, and preserving the earth from climate changes and natural disasters. It is therefore becoming increasingly important to identify plants and preserve them [1]. One of the benefits of plants is their medicinal abilities; humans have been using medicinal plants for centuries. Medicinal plants have been used for both curative and preventive medical therapy preparations for human beings and also animals, which also has been used for the extraction of important bioactive compounds [2, 3]. It is estimated that nearly 80% of the world’s total population, regularly, uses traditional medicine and its products for its healthcare needs especially in third world countries [4]. People from developing countries combine conventional medicine (exercise, meditation, lifestyle) with traditional medicines to treat themselves. Medicinal plants are preferred mostly because of their lower side effect and affordability. Moreover, in rural areas where the accessibility of a proper healthcare system is rare whereby the healthcare facilities are concentrated in cities, People living in these areas tend to get dependent on traditional medicinal plants and traditional physicians, which they think they understand their culture, their symptoms, and environment according to their disease. Ethiopia is one of the countries whereby medicinal plants play an important role in primary health care. About 95% of traditional medicines works in Ethiopia stand to be of plant origin [5]. Scientific investigation of millennia-old community knowledge on plant use is essential to define cultural identities of a particular community and understand links to their history, land and plant use practices, and traditional environmental philosophy. The knowledge on traditional medicinal plants of Ethiopia, which exits for centuries, is now facing extinction the knowledge has mainly been stored in the memories of elderly peoples and handed down verbally for generations [6]. Although medicinal plants play a significant role in supporting primary healthcare in Ethiopia, a few attempts have been done to scientifically identify, document, and promote the widely used medicinal plants and associated knowledge dynamics in the country. Hence, an appropriate investigation, identification, documentation, and usage of the knowledge and linking up with the modern ways on medicinal plants is needed. Moreover, it provides the opportunity for recognition, promotion, management, and protection of indigenous knowledge of a community on medicinal plants as a vital part of a nation’s heritage, besides calling policymakers, natural resource managers, stakeholders, and cultural practitioners for conservation actions [6]. This study aims on classifying eight medicinal plants based on their leaf shape, texture, and color. Our contributions are as follow: (1) In this paper, we develop a novel dataset based on Ethiopian medicinal plants. (2) We use fine-tuning techniques for the architecture like changing the output classification layer to optimize such as SGD and Adams and adjust the learning rate. And data pre-processing techniques and data augmentation are used such as image data augmentation, image enhancement, and training epochs as a variable to get better result. (3) We use two models of a convolutional neural network to train and classify the dataset, and we compare both based on their performance on accuracy and chose the best to build a web-based medicinal plant identification system.

2 Related Work

This section defines different techniques used by researchers for identifying and classifying plants using machine methods. Machine learning techniques in classification, recognition, disease detection of plant species have been used for some time. Du et al. (2007) used leaf images of 20 plant species for plant identification based on digital morphological features, in this study K-Nearest neighbor is used for the classification and achieved 93% accuracy [8]. Herdiyeni and Wahyuni (2012) used a fusion of fuzzy local binary pattern and fuzzy color histogram and for classification, a Probabilistic neural network (PNN) is used on a dataset containing 2448 leaf images of medicinal plants from Indonesian forest achieving an accuracy of 74.5% [7]. According to ArunPriya C. and Balasaravanan in their work, 12 features are orthogonalized using Principal component analysis and fed into a classifier called support vector machine (SVM) achieving a result of 96.8% which is far better in performance compared to K-NN which achieved 81.3% [8]. According to Jiachun Liu et al. (2018), a novel classification method based on ten layers convolutional neural network is proposed and used on the Flavia dataset having 4800 images with 32 different kinds of leaf plants, achieving 87.92% accuracy [9]. Sue Han Lee et al. [10] Used deep learning in a bottom-up and top-down manner to classify 44 different plant species, Convolutional neural networks are used to learn the features and classify them. In addition, a Deconvolutional network is used for visualization of learned features, this work attained 99.5% of accuracy in identifying the plant species. Ferreira, Alessandro Dos Santos, et al. [11] used convolutional neural network in order to identify weed plant from soybean crops, More than 15,000 images composed of images of soybean crops, grass weeds, broadleaf is used for training the chosen classification architecture which is CaffeNet architecture of Neural Network. Baizel Kurian Varghese et al. proposed in their work a convolutional neural network that is based on ILSVRC 2012 dataset used for the pre-training process with the final layer, which is fully connected by replacing 1000 neurons with 44 neurons. More than 8800 leaf images were used for testing and 34,672 leaf images were used for training achieving an accuracy of 99.5%. Using a Mobile Net architecture with the same dataset and obtained correct predictions with an accuracy level of 99% [12, 13]. This paper aims at comparing two convolutional neural network models named AlexNet and GoogLeNet on a novel image dataset, which is based on Ethiopian medicinal plants; Different variables like such as techniques of image pre-processing like image augmentation and training epoch are put into consideration in choosing the best model from the two.

3 The Proposed System

In this part, we present the system architectures and the deep learning techniques. Figure 1 shows the main architecture of the proposed system. The proposed architecture mainly involves two phases, namely, the training phase and the identification phase. In the training phase, the image acquisition is done by collecting leaf images of medicinal plants; different techniques like image enhancement, image resizing, and image segmentation are used for preprocessing the images. Features extraction is done by selected CNN models, which are AlexNet and GoogLeNet. The Identification phase involves the classification and labeling of medicinal plants based on the trained CNN models. Each model is trained on these models of CNN with the prepared dataset where features are extracted and classified by their names.

3.1 Dataset Preparation

Based on different expertise from the Department of Plant Biology and Biodiversity Management (lecturers, taxonomists) at Addis Ababa University, a list of plants that are used as medicine was prepared with a possible location area for all. From more than 80 medicinal plants, listed, leaf-based medicinal plants are chosen and located. Eight medicinal plants are chosen for the research and the research method used is experimental. More than 2100 leaf images of selected medicinal plants are collected from different parts of Addis Ababa, Ethiopia. To take photos of the leaf’s Redmi Mobile phone with 64MP (Mega Pixel) camera is used. The dataset is then divided into two parts, 80% of the dataset is used for training, while the rest 20% is used as a test set and validation set. The total number of medicinal plant leaf images is shown in a table format below (Table 1).

Fig. 1.
figure 1

The main architecture of the proposed system.

3.2 Image Pre-processing

The collected images are first cleaned in a way that does not affect labeled images. Since deep learning performance is improved based on the number of data the algorithm is fed, the total number of images increased using a technique called image augmentation. Image augmentation techniques like horizontal flip, vertical flip and rotate augmentation are used. Likewise, according to the model, different activities that are suitable input for our models are performed including resizing the images. All images are resized to fit the scale represented by AlexNet and GoogLeNet, which are 227 * 227 and 224 * 224 respectively. Below is a table showing the number of images in each class after image augmentation (Table 2).

Table 1. Total number of images before data augmentation
Table 2. The total number of images after augmentation

3.3 Experiment Parameters

Two CNN architectures AlexNet and GoogLeNet were fine-tuned and used. The batch size used was 64 and 16 for both AlexNet and GoogLeNet respectively. For optimization algorithms, Adam and SGD are used which helps to compute the adaptive learning rate for each parameter and improves the accuracy of the model. For both models, the output classification layers are adjusted to the number of classes, which is eight. Dropout parameter is layer is used with a probability of 40%, to increase the accuracy of the model. After comparing the results of the accuracy of the two models, the one with better performance is chosen to train the dataset with the augmented data. In order to increase the original size of the training dataset and to avoid overfitting data augmentation is used with the following variable horizontal flip, Zoom range and shift range 0.2, rotation range 30\(^\circ \), width, and height shifting. Epochs given for training varied from 50 to 200 for both architectures.

3.4 Training and Classification of the Models

In this study, two architectures of convolutional neural networks are used to train and classify leaf images of medicinal plants collected and preprocessed for identification purposes. AlexNet and GoogLeNet, the two networks, differ in general architecture. Goog-LeNet has Inception Modules, which perform with different convolutions and concatenate the filters for the next layer. AlexNet, on the other hand, has layers input provided by one previous layer instead of a filter concatenation. In this paper, the collected images are trained to classify images on AlexNet and GoogLeNet models to choose which model performs better in terms of accuracy, loss, and validation. After getting better accuracy results in GoogLeNet, this model is chosen to train and classify the medicinal plants and the model to feed for a web-based classification system.

4 Experiment and Results

In our experiment, 1740 leaf images of the original dataset are used for training and 432 leaf images are considered for testing the performance of the system. For AlexNet, 42 samples are misclassified. 5 data is misclassified in class 1. 3 data is misclassified in class 2. 8 data is misclassified in class 3. 9 data is misclassified in class 4. 6 data is misclassified in class 5. 2 data is misclassified in class 6. 4 data misclassified in class 7 and 5 data misclassifies in class 8 as shown in Table 3. Classification accuracy for each class is 90.7%, 89.4%, 85.1%, 83.3%, 88.8%, 96.2%, 96.2%, 92.5%, 90.7% from class1 to class 8 respectively, which gives overall average accuracy of 90.2%. For GoogLeNet in total 30 samples are misclassified. 4 data misclassified in class 1, 4 data misclassified in class 2, 5 data misclassified in class 3, 6 data misclassified in class 4, 2 data misclassified in class 5, 3 data misclassified in class 6, 5 data misclassified in class 7 and 3 data misclassified in class 8 shown in Table 3. Classification accuracy for each class is 94.4%, 92.4%, 90.7%, 88.8%, and 96.2%, 94.2%, 90.0%, 94.4% from class1 to class 8 respectively, which gives overall average accuracy of 92.8%. The classification result for both AlexNet and GoogLeNet before data augmentation is shown in the Fig. 2 table below.

Table 3. Classification results of the proposed architectures.

Based on the result, GoogLeNet is chosen as the preferred CNN architecture to train and classify the medicinal plants with the augment-ed dataset and fine-tuned algorithm. The number of epoch given for the training was 100,150 and 200 in which the results were 89.8%, 94.3% and 96.7% respectively.

Fig. 2.
figure 2

The plot for training and testing accuracy and validation loss using GoogLeNet.

5 Conclusion

In this paper, an automatic classification of Ethiopian medicinal plants based on convolutional networks is proposed. We first pre-process images by resizing, enhancement, data augmentation and normalization, and we use fine-tuning technique to improve the accuracy of the model. Two convolutional neural network architectures namely AlexNet and GoogLeNet are used to train and classify the medicinal plants and the results are compared in terms of accuracy and validation loss. Our experimental results showed that the larger the dataset and the number of epochs GoogLeNet showed better achievement in classification the target correctly. GoogLeNet showed 96.7% training accuracy with 200 epochs, which is used for a web-based application to able users to upload a leaf image of a medicinal plant and identify the plant along with a description of their use.