Sebuah Kajian Pustaka: IT Journal Research and Development (ITJRD) Vol.8, No.1, August 2023, E-ISSN : 2528-4053 | P-ISSN : 2528-4061 DOI : 10.25299/itjrd.2023.13904 14 Journal homepage: http://journal.uir.ac.id/index/php/ITJRD Corn Leaf Diseases Recognition Based on Convolutional Neural Network Mutia Fadhilla1, Des Suryani2, Ause Labellapansa3, Hendra Gunawan4 Department of Informatics Engineering, Universitas Islam Riau1,2,3 tiafadhilla@eng.uir.ac.id1, des.suryani@eng.uir.ac.id, ause.labella@eng.uir.ac.id4, hendra@eng.uir.ac.id4 Article Info ABSTRACT Article history: Received Jun 02, 2023 Revised Jul 12, 2023 Accepted Aug 18, 2023 Maize or known as corn is one of the most important agricultural commodities in Indonesia beside rice. Indonesia is located in a tropical area which has high rate of rainfall and humidity which makes it easy for fungi and bacteria that caused plant disease to thrive. It could be a threat which is a decrease of corn harvest due to plant diseases. To prevent this, a deep learning approach can be implemented to recognize plant diseases automatically based on visual pattern on leaves. In this study, we proposed a CNN-based model for corn leaf diseases recognition. Based on the results, the proposed method has great performance which accuracy score of 93%. Besides that, the proposed method achieved up to 100% precision and recall, and up to 99% F1 score. Keyword: Corn Leaf Diseases Computer Vision Leaf Diseases Recognition Convolutional Neural Network Deep Learning © This work is licensed under a Creative Commons Attribution- ShareAlike 4.0 International License. 1. INTRODUCTION Indonesia is an agricultural country where most of the population has a livelihood in the agricultural sector. One of the important agricultural commodities in Indonesia is corn corps[1][2]. Corn or also known as Maize is the most important cereal crops in Indonesia besides rice. Meanwhile, it is ranked 3rd after wheat and rice worldwide[3]. Most of Indonesian people use corn as a staple food as a substitute for rice[4]. It is also used as an ingredient for making various types of cuisines. In addition, corn also has the potential to be developed as a main source of energy for livestock such as poultry[5]. Plant diseases have a negative impact on crop yields including corn. It can cause production loss if it is handled too late. Diseases in plants can be caused by several factors including the environmental conditions and climate of the place where they are cultivated. Besides that, this can also be caused by pests that come from fungi and bacteria. Indonesia is a country that located in a tropical area which has high rate of rainfall and humidity which makes it easy for fungi and bacteria to thrive in the hosts[3]. It certainly will be risky for plants and affect crop production. Therefore, early detection is needed to prevent this from happening. Plants infected with the disease can be recognized by visual changes in plant parts such as leaves, stems, flowers, and fruit. Each disease has a visually unique pattern that makes it easy to distinguish from the others. Most of the initial symptoms in diseased plants begin with a change in color or visual appearance on the leaves[6]. Generally, plant disease identification is conducted by direct observations in the field. It certainly has some weaknesses such as human error, fatigue, IT Jou Res and Dev, Vol.8, No.1, August 2023 : 14 - 21 Corn Leaf Diseases Recognition Based on Convolutional Neural Network, Mutia 15 takes a lot of time, is less effective and efficient. Therefore, a system is needed that can recognize diseases in plant leaves to prevent production loss in corn crops production. Nowadays, there are many agricultural technologies that utilize artificial intelligence to solve various problems in this field. With the development of artificial intelligence technology, it is now possible to identify diseases on leaves automatically using deep learning and computer vision approaches. The computer vision approach uses image processing and machine learning to recognize visual patterns of leaf diseases in corn crops. Several studies have been conducted previously using this approach. [7] conducted study that uses various image processing for extracting features such as RGB color and scale-invariant feature transform (SIFT). Then, it used some machine learning algorithms which are decision tree, random forest, and naive bayes to predict corn leaf disease based on features extracted. [8] also proposed similar classification model with [7] that use some supervised machine learning techniques with additional of k-nearest neighbor (KNN) model in the study. [9] proposed deep forest algorithms for corn leaf diseases classification. Meanwhile, [10] used 11 features of corn leaf images such as shape and texture with combination the support vector machine (SVM) algorithm to recognize the diseases. Furthermore, the deep learning approaches use deep neural network architecture to predict corn leaf diseases. These approache also known as modern techniques for image processing and have been successfully implemented in some areas including agriculture [11]. Convolutional neural network (CNN) is one of the most representative neural networks in the field of deep learning[12]. It successfully did some vision-related tasks such as image recognition and detection. Deep learning approaches have been used in several studies of plant leaf diseases including corn crops. [13] conducted research using image processing and CNN-based model to detect corn and peach leaf disease. [14] also proposed CNN-based classification model and compared the performance with pre-trained CNN models which are VGG-16 and InceptionV3. [15] introduced a dataset for plant disease detection and used pre-trained CNN model such as VGG16 and InceptionResnetV2 for training and testing the dataset. [16][17][18] proposed CNN-based deep learning model to detect leaf diseases of several plant species such as corn, grapes, potato, and sugarcane. [19] proposed monitoring system for leaf disease detection using CNN. Based on the problems that mentioned above and previous research, motivating us to propose classification model of corn leaf disease recognition for early prediction of plant diseases. It is important to prevent production loss of fruit and vegetables crops such as corn or maize. Hence, we proposed a CNN-based deep learning model for corn leaf disease recognition task. In this study, the proposed model used some convolutional layers and a fully connected layer as a classifier layer that has four nodes that represent the number of corn leaf category including healthy and disease infected corn leaf. In addition, some measurements are used for testing the performance of proposed model which are accuracy, recall, precision and F1 scores. 2. RESEARCH METHOD Figure 1. Research Processes The processes of research conducted in this study are shown in figure 1. The first process is collecting corn leaf images dataset. Then, the collected data was split into three types of data which are training set, validation set, dan testing set. The next process is training the proposed model which is CNN-based model using the training dan validation dataset, followed by testing stage of the proposed model. After testing the model, performance evaluation is conducted using some general measurements for classification task which are accuracy, precision, recall, and F1 scores. IT Jou Res and Dev, Vol.8, No.1, August 2023 : 14 - 21 Corn Leaf Diseases Recognition Based on Convolutional Neural Network, Mutia 16 2.1. Dataset Collection and Preprocessing Figure 2. Corn Leaf Image Examples: a. Healthy; b. Common Rust; c. Leaf Blight; d. Leaf Spot The dataset of corn leaf disease images is collected from the dataset that published by [20]. It consists of several plant varieties leaf images such as corn leaf, tomato leaf, potato leaf, and apple leaf images collection. It applied some augmentation techniques for increasing the image dataset. The techniques are rotation, scaling, PCA color, flipping and gamma correction. In this study, we collected the images dataset by subsetting the plant leaf images and obtained only the corn leaf images for the research. We randomly chose 1000 images that belong to four categories related to corn leaf images. The categories consist of healty leaf and three types of infected corn leaf which are common rust, leaf blight, and leaf spot. Figure 2 shows some image examples of corn leaf dataset. In this study, we divided the dataset into three kinds of data partitions, 200 images of testing dataset, and 800 images of training and evaluation dataset. 2.2. CNN Proposed Model Figure 3. CNN Architectures of Proposed Model The CNN architecture of proposed model in this study is illustrated in figure 3. It consists of various types of neural networks layer architecture. The first layer is the input layer that is the corn leaf image itself which is 128 x 128 size and RGB image channel. The next layers are four convolutional layers (conv1, conv2, conv3, and conv4) which is followed by max pooling layer. Each convolutional layer has 3 x 3 filter size. Where conv1 and conv2 layers have 32 filters, meanwhile conv3 and conv4 layers have 64 filters. The result of convolutional layers then IT Jou Res and Dev, Vol.8, No.1, August 2023 : 14 - 21 Corn Leaf Diseases Recognition Based on Convolutional Neural Network, Mutia 17 reshapped into one dimensional vector and connected to two fully connected layers. The first fully connected layer (fc1) has 100 nodes which use ReLU as activation function. Meanwhile, the next fully connected layer (fc2) has four nodes that represent the number of corn leaf disease categories. It uses softmax as the activation function. It will yield the propability value distribution that return an output vector which has four probability scores, in this case there will be four types of corn leaf diseases, that correspondent with each leaf disease category. In this study, the CNN-based proposed model will be trained to maximize the prediction accuracy in recognition of corn leaf disease by minimizing the loss function. During the training process, the weights of proposed CNN architecture will be updated in iterative process which has the goal to minimize the loss value in prediction. To predict the corn leaf disease, the loss function is categorical cross entropy that formula described below: 𝐶𝑆𝐸 = − ∑ 𝑔𝑖 log 𝑝𝑖 𝑛 𝑖=1 (1) where n is the number of categories, pi is the predicted label, and gi is actual label or known as ground truth label. In addition, we set some hyperparameters related to the training process which are 50 epoch and 32 batch size. 3. RESULTS AND ANALYSIS To evaluate the proposed method, confusion matrix is used to visualize the testing results. The confusion matrix can be shown in figure 4. As shown in figure 4, the proposed method has successfully predicted healthy corn leaf categories without any error or mistake. Meanwhile, the least successful category is leaf spot which has 41 of 50 data correctly predicted. Based on the results, the proposed method has great performance in recognition corn leaf disease. It has an accuracy value of 93%. Prediction Class Actual Class (Ground Truth) Figure 4. The Confusion Matrix of Testing Result IT Jou Res and Dev, Vol.8, No.1, August 2023 : 14 - 21 Corn Leaf Diseases Recognition Based on Convolutional Neural Network, Mutia 18 Figure 5. The Performance Evalution Results of Proposed Method Besides accuracy, there are other measurements to evaluate the performance of classification model. They are precision, recall, and F1 score. These measurements are calculated for earch category or class in classification task. The performance evaluation results can be seen from the chart in figure 5. The first measurement is precision. It is used to determine how precise the model is in predicting a certain class. Based on the results shown in figure 5, most of categories have precision score above 90%. And the highest score is common rust category that has 100% precision score. Furthermore, the average precision of proposed method is 93.24%. The next measurement to evaluate the proposed method is recall score. It calculates how accurate each category is being successfully predicted comparing the actual or ground truth class or label. The recall score can be used to calculate accuracy for each category. Based on chart in figure 5, most of categories also have recall score above 90% similar precision results. But the category which has the highest is healthy leaf with precision score of 100%. The last measurement to evaluate proposed model is F1 score. It can be calculated based on the precision and recall score. The highest F1 score is the common rust category which has F1 score of 99%. Table 1. Accuracy Comparison with Previous Studies Method Accuracy [8] 79.23% [14] 94% Proposed Method 93% In this study, we also compare the accuracy result with previous related study. The accuracy score comparison is shown on table 1. Based on the results, it shows that the proposed method has better accuracy score compared to [8] that only has accuracy of 79.23%. Meanwhile, the proposed method doesn’t have better performance compared to [14]. However, the difference in accuracy scores is only 1% higher than the proposed method, where [14] yield accuracy result of 94% and the proposed method has accuracy of 93%. In addition, some examples of corn leaf disease image recognition can be seen on table 2 and table 3. Table 2 shows the best case of corn leaf disease recognition. As seen on table 2, each category successfully predicted with relatively high confidence score which are above 90%. Meanwhile, the worst-case example of corn leaf disease recognition is shown in tabel 3. It shows that the proposed method can’t successfully recognize corn leaf category in some cases. The worst- cases are common rust image recognized as leaf spot, leaf blight image recognized as leaf spot or healthy leaf, and leaf spot image recognized as leaf blight. Common Rust Healthy Leaf Leaf Blight Leaf Spot Precision 1.00 0.96 0.84 0.93 Recall 0.98 1.00 0.92 0.82 F1-Score 0.99 0.98 0.88 0.87 0.00 0.20 0.40 0.60 0.80 1.00 1.20 The Performance of Proposed Method Precision Recall F1-Score IT Jou Res and Dev, Vol.8, No.1, August 2023 : 14 - 21 Corn Leaf Diseases Recognition Based on Convolutional Neural Network, Mutia 19 Table 2. Best Case Recognition Example of Proposed Method Result Example of Recognition Results (Best-Case) Input Image Actual Healthy Leaf Commont Rust Leaf Blight Leaf Spot Prediction Healthy Leaf Commont Rust Leaf Blight Leaf Spot Confidence 0.99 1.00 0.99 0.98 Table 3. Worst Case Recognition Example of Proposed Method Result Example of Recognition Results (Worst-Case) Input Image Actual Commont Rust Leaf Blight Leaf Blight Leaf Spot Prediction Leaf Spot Leaf Spot Healthy Leaf Leaf Blight Confidence 0.99 0.58 0.67 0.60 4. CONCLUSION In this study, we proposed a CNN-based model for corn leaf disease recognition. The CNN architecture consists of some convolutional layer followed by two fully connected layers in the last layers. It conducted training dan testing stages to improve the proposed method performance in recognition of corn leaf disease. To evaluate the performance of the proposed method, we use some measurements which are accuracy, precision, recall, and F1 scores. Based on the evaluation results, it shows that the proposed method has great performance where it has relatively high accuracy score of 93%. Furthermore, the proposed method has achieved 100% score of precision and recall, and 99% of F1 score. The proposed method still has opportunities to be developed in the future so that it has better performance. In addition, the proposed method also can be implemented into a mobile application that can be easily used by related users such as farmers effectively and efficiently. REFERENCES [1] W. Zhiwu et al., “Budidaya Jagung dengan Populasi Tinggi untuk Meningkatkan Produktivitas dan Efisiensi Lahan di Indonesia,” AGROSAINSTEK: Jurnal Ilmu dan Teknologi Pertanian, vol. 3, no. 1, 2019, doi: 10.33019/agrosainstek.v3i1.36. [2] Q. Ayun, S. Kurniawan, and W. A. Saputro, “PERKEMBANGAN KONVERSI LAHAN PERTANIAN DI BAGIAN NEGARA AGRARIS,” VIGOR: JURNAL ILMU PERTANIAN TROPIKA DAN SUBTROPIKA, vol. 5, no. 2, 2020, doi: 10.31002/vigor.v5i2.3040. IT Jou Res and Dev, Vol.8, No.1, August 2023 : 14 - 21 Corn Leaf Diseases Recognition Based on Convolutional Neural Network, Mutia 20 [3] F. U. Rehman et al., “Seed-Borne Fungal Diseases of Maize (Zea mays L.): A Review,” Agrinula : Jurnal Agroteknologi dan Perkebunan, vol. 4, no. 1, 2021, doi: 10.36490/agri.v4i1.123. [4] A. I. Dwi Putra and M. A. Surianto, “Analisis Penerapan Standar Operasional Prosedur Budidaya Untuk Pengendalian Kualitas Hasil Panen Jagung,” Entrepreneur: Jurnal Bisnis Manajemen dan Kewirausahaan, vol. 3, no. 1, 2022, doi: 10.31949/entrepreneur.v3i1.1755. [5] A. R. Lapui, U. Nopriani, and H. Mongi, “Analisis Kandungan Nutrisi Tepung Jagung (Zea mays Lam) dari Desa Uedele Kecamatan Tojo Kabupaten Tojo Una-Una untuk Pakan Ternak,” Jurnal Agropet, vol. 18, no. 2, 2021. [6] L. Li, S. Zhang, and B. Wang, “Plant Disease Detection and Classification by Deep Learning - A Review,” IEEE Access, vol. 9. 2021. doi: 10.1109/ACCESS.2021.3069646. [7] B. S. Kusumo, A. Heryana, O. Mahendra, and H. F. Pardede, “Machine Learning-based for Automatic Detection of Corn-Plant Diseases Using Image Processing,” in 2018 International Conference on Computer, Control, Informatics and its Applications: Recent Challenges in Machine Learning for Computing Applications, IC3INA 2018 - Proceeding, 2019. doi: 10.1109/IC3INA.2018.8629507. [8] K. P. Panigrahi, H. Das, A. K. Sahoo, and S. C. Moharana, “Maize Leaf Disease Detection and Classification Using Machine Learning Algorithms,” in Advances in Intelligent Systems and Computing, 2020. doi: 10.1007/978-981-15-2414-1_66. [9] J. Arora, U. Agrawal, and P. Sharma, “Classification of Maize leaf diseases from healthy leaves using Deep Forest,” Journal of Artificial Intelligence and Systems, 2020, doi: 10.33969/AIS.2020.21002. [10] T. Ren, Y. Zhang, and C. Wang, “Identification of Corn Leaf Disease Based on Image Processing,” in 2019 2nd International Conference on Information Systems and Computer Aided Education, ICISCAE 2019, 2019. doi: 10.1109/ICISCAE48440.2019.221610. [11] A. Kamilaris and F. X. Prenafeta-Boldú, “A review of the use of convolutional neural networks in agriculture,” Journal of Agricultural Science, vol. 156, no. 3. 2018. doi: 10.1017/S0021859618000436. [12] Z. Li, F. Liu, W. Yang, S. Peng, and J. Zhou, “A Survey of Convolutional Neural Networks: Analysis, Applications, and Prospects,” IEEE Trans Neural Netw Learn Syst, vol. 33, no. 12, 2022, doi: 10.1109/TNNLS.2021.3084827. [13] M. H. Sheikh, T. T. Mim, S. Md Reza, A. K. M. S. A. Rabby, and S. A. Hossain, “Detection of Maize and Peach Leaf diseases using Image Processing,” in 2019 10th International Conference on Computing, Communication and Networking Technologies, ICCCNT 2019, 2019. doi: 10.1109/ICCCNT45670.2019.8944530. [14] M. Agarwal, V. K. Bohat, M. D. Ansari, A. Sinha, S. K. Gupta, and D. Garg, “A Convolution Neural Network based approach to detect the disease in Corn Crop,” in Proceedings of the 2019 IEEE 9th International Conference on Advanced Computing, IACC 2019, 2019. doi: 10.1109/IACC48062.2019.8971602. [15] D. Singh, N. Jain, P. Jain, P. Kayal, S. Kumawat, and N. Batra, “PlantDoc: A dataset for visual plant disease detection,” in ACM International Conference Proceeding Series, 2020. doi: 10.1145/3371158.3371196. [16] K. P. Ferentinos, “Deep learning models for plant disease detection and diagnosis,” Comput Electron Agric, vol. 145, 2018, doi: 10.1016/j.compag.2018.01.009. [17] S. V. Militante, B. D. Gerardo, and N. V. DIonisio, “Plant Leaf Detection and Disease Recognition using Deep Learning,” in 2019 IEEE Eurasia Conference on IOT, Communication and Engineering, ECICE 2019, 2019. doi: 10.1109/ECICE47484.2019.8942686. [18] C. Ashwini and V. Sellam, “Corn Disease Detection based on Deep Neural Network for Substantiating the Crop Yield,” Applied Mathematics and Information Sciences, vol. 16, no. 3, 2021, doi: 10.18576/amis/160304. IT Jou Res and Dev, Vol.8, No.1, August 2023 : 14 - 21 Corn Leaf Diseases Recognition Based on Convolutional Neural Network, Mutia 21 [19] N. Radha and R. Swathika, “A Polyhouse: Plant Monitoring and Diseases Detection using CNN,” in Proceedings - International Conference on Artificial Intelligence and Smart Systems, ICAIS 2021, 2021. doi: 10.1109/ICAIS50930.2021.9395847. [20] A. P. J and G. GOPAL, “Data for: Identification of Plant Leaf Diseases Using a 9-layer Deep Convolutional Neural Network,” Mendeley Data, V1, 2019, doi: 10.17632/tywbtsjrjv.1.