0% found this document useful (0 votes)
22 views8 pages

CNN-Based Tomato Leaf Disease Detection

Tomato leaf disease detection
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
22 views8 pages

CNN-Based Tomato Leaf Disease Detection

Tomato leaf disease detection
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Tomato Leaf Disease Prediction Using

CNN

Abstract— In many countries, tomatoes are regarded as an Tomatoes rank among the most significant and widely eaten crops
essential economic resource and are among the most valuable around the world. Current data indicates that global tomato production
vegetables in the world. Nevertheless, these crops are susceptible
exceeds 180 million metric tons and generates about 8. 81 billion USD
to a number of illnesses that can reduce and damage the yield of
in exports. However, the production of tomatoes is on the decline due
healthy plants, thus it is crucial to identify these conditions early
to the crop's vulnerability to numerous diseases. Tomato leaf diseases
and accurately. Because of this, a more number of research has
are a major cause of crop losses and financial hardship for farmers. The
recently used deep learning (DL) models to automatically detect
financial implications of agriculture are intimately related to the
tomato leaf diseases. However, a few of these techniques just
employ one DL framework, which necessitates a large amount of recognition of these leaf diseases. To maintain production and farmers'
processing power to modify hyperparameters. The process of profitability, it is critical to promptly detect tomato leaf diseases and
classification gets increasingly intricate this reliance. These take the necessary action. Conventional disease detection techniques
networks also generate large dimensions, which further necessitate a manual inspection of afflicted leaves, either by visual
challenge classification. As a result, this study offers a technique inspection or chemical analysis. This can be time-consuming and may
that uses three compact convolutional neural networks (CNNs) to result in errors and unreliability because of human error. This situation
automatically detect tomato leaf illnesses. For a more succinct is worsened by the lack of expertise among farmers and the scarcity of
and sophisticated representation, it uses transfer learning to trained agricultural specialists capable of identifying diseases in remote
extract deep features from the final fully connected layer of the areas, which hampers overall agricultural productivity. This kind of
CNNs. In order to capitalize on the advantages of each CNN carelessness puts the world's food security at serious danger and costs
structure, it then integrates the features from the three CNNs. A those who grow tomatoes a lot of money. These issues could be
comprehensive feature set with decreased dimensions is then successfully resolved and farmers could be assisted by using automated
selected and created using a hybrid feature selection method. Six tools and methods for early disease identification.
distinct classifiers are used identification process.
Because of their accuracy and capacity for process automation, deep
Keywords— Real Time alert , CNN , Open CV ,Dib learning techniques—particularly Convolutional Neural Networks, or
CNNs—have gained importance in the last several years for the
,MEN,LEN, Shape predictor,EARMAR.
detection of diseases in images. Accurate disease identification is made
possible by CNNs' proficiency in identifying patterns and details in leaf
images. In order to assure reliable and efficient disease detection, this
project aims to develop a CNN-based model for recognizing illnesses
[Link] : in TLD using the deep learning techniques.

Farming has long been the main way for many nations in Africa and The proposed approach entails collecting and creating tomato leaves,
Asia to earn money. The full commercialization of farming has model to recognize various diseases, and evaluating its efficacy in
greatly affected our environment. Detecting plant diseases comparison to existing methods. By automating the identification
agriculture. Finding diseases early helps stop them from spreading process, this research offers farmers and other agricultural professionals
to other plants, This may result in significant monetary losses. Plant a workable solution that enables them to act swiftly to minimize crop
illnesses significantly affect the agricultural sector This may result loss and boost production. It offers a versatile, discrete, and effective
in anything from minor issues to the loss of entire farms. method of equipping new cars with driver monitoring devices,
enhancing road safety.
[Link] REVIEW :
The Paper[4] DLDPF is a framework presented in the study [4] that
The Paper[1], discusses how plant diseases initially uses Keras, TensorFlow, and Python to integrate CNN utilizing cascade
affect leaves before they spread to the rest of the plant, inception of AlexNet and GoogleNet. This system, which aims to
impacting both the type and quantity of crops, which automate the detection of diseases in apple plants, shows good
performance compared to AlexNet, GoogLeNet, VGGNet16, and
significantly lowers agricultural output. To manage these
ResNet20. The framework, which is trained on an apple leaf dataset
diseases effectively, it is crucial to identify them accurately containing 10,888 training images and 2,801 test photos, has an
and early on. This research introduces a mode utilizes accuracy rating of 97.62%. It requires 2.84 GB of memory and takes
photos of 14 different healthy and sick plants, categorizing 33.45 minutes to train, which makes models. Investigating alternative
them into 38 classes from the Plant Village dataset. The models, like modified Recurrent Neural Networks (RNN), could be a
model demonstrates potential for leaf diseases, achieving a promising research avenue for improving disease prediction in
training accuracy of 98. 01% and a test accuracy of precision agriculture.

94. 33%. Future initiatives will involve collaborating with The paper [5] aim of plant pathology, as stated in paper [5], is to study
diseases caused by pathogens and environmental factors.
farms to gather various data, enhancing the CNN with
additional architectures on more complex datasets, and This involves examining how to identify pathogens,
developing a system for realtime disease monitoring. understanding disease cycles, evaluating economic impacts, and
exploring management strategies. Traditionally, disease diagnosis used
spectroscopic technologies, which tend to be costly and require skilled
According to the report [2], agriculture—which entails operators. This research introduces a technique for identifying plant
clearing land and growing crops for human consumption—is a diseases with the help of a CNN. Initially, an image of a leaf sample is
vital sector of the Indian economy. However, illnesses that processed to remove healthy green pixels and separate color channels,
impede plant growth may be caused by different farming allowing a focus on the damaged regions. The features from these
practices, seasonal variations, and climate variables. Plant affected areas are extracted and input into a CNN for disease
protection depends on the prompt detection and diagnosis of these classification. Once the illness is identified, solutions are sent to the
diseases. Standard classifiers including Backpropagation Neural user’s mobile device via a GSM module.
Network (BPNN), Probabilistic Neural Network (PNN), Function
of Rasial basis a neural network (RBFNN), Support Vector
Machine (SVM), and KNearest Neighbors (KNN) have been Using the Plant Village dataset, the research [6] presents a Modified
utilized in the past for plant disease classification. However, these LeNet architecture which utilizes deep convolution neural networks
classifiers frequently struggle to strike a compromise between (CNNs) to detect leaf diseases in maize. When trained to differentiate
accuracy and speed. In order to classify plant diseases, this between, the CNN model attains an impressive accuracy of 97.89%.
research presents an accurate and efficient image processing three disease categories and healthy maize leaves. This method, which
technique. is based on rigorous testing that changed variables including depth and
The suggested approach starts by using the backpropagation kernel size, efficiently classifies many illnesses affecting maize leaves
technique to ascertain the weights of neural network connections. by focusing on both local and global aspects. The study emphasizes the
The application of particle Swarm Optimization(PSO) enhances significance of the suggested CNN design for enhancing agricultural
the neural network's connections in order to address problems like information systems by showing that it is adaptable and effective in
local optima and overfitting that are frequently encountered in dealing with plant leaf diseases beyond those that impact maize.
conventional neural network training. Using photos of leaves
afflicted with illnesses Spot, the tests 96.2%.
Paper [7] CNNs, a deep learning technique, are utilized in the study [7]
to tackle the primary threat that crop diseases represent to global food
The Paper [3] According to the paper, a smartphone security. Using a set of 3852 photos from PlantVillage, a novel CNN
application was created to identify and categorize grape leaf model with 15 layers is developed to automatically identify crop
illnesses [3]. To precisely locate and identify the impacted regions diseases in maize. In addition to pictures of healthy plants, this
in the photos, this application makes use of the RCNN model for collection includes pictures of three distinct diseases: Northern Corn
object identification, which is backed by an InceptionV2 Leaf Blight (NCLB), Common Rust (CR), and Gray Leaf Spot (GLS).
backbone. It operates independently on mobile devices and has The study also uses a technique called transfer learning to assess how
demonstrated a remarkable accuracy of 97. 9% based on tests well performs compared to several pretrained networks. proposed
conducted with images depicting grape diseases. By enabling CNN model surpasses the leading pretrained network, DenseNet121,
early detection and management of diseases, the application by 3.2 percent, even though it has fewer trainable parameters. This
assists farmers and cultivators in reducing crop losses and indicates that for identifying diseases in maize crops, the suggested
preventing disease spread. CNN model outperforms other methods.
The study [8] looks at how the AlexNet model can be used to swiftly
and precisely detect illnesses that harm maize leaves, which have a
big influence on agricultural output and result in losses for
businesses all over the world. With the assistance of the
PlantVillage dataset, which contains diseases like Common Rust
and leafspot ailments (Cercospora and Gray), the suggested deep
neural network achieves a remarkable 99.16% accuracy rate.
AlexNet and other convolutional neural networks automatically
Fig.1 Depicting the classic architecture of CNN
derive information from raw photos, which simplifies the illness
identification process. In order to properly identify and treat these Several crucial elements, referred to as layers in its architecture,
diseases—which is essential for safeguarding maize harvests and make up a convolutional neural network:
sustaining farmers' livelihoods—it is difficult to manage sizable
datasets and optimize model iterations. • Convolutional Layer: This part employs a technique known
as convolution to find characteristics like edges. This
The study referenced as [9] investigates the enhancement of
entails matching the input channels of the image with a
agricultural output by means of computer vision techniques that
filter or kernel of a particular size applied to the input
automate the detection of diseases affecting maize leaves. achieve
volume. A feature map is the end product of this operation.
this, three sophisticated designs of CNNs were assessed, employing
We will produce k feature maps if we apply k filters.
strategies such as data augmentation, finetuning, and
hyperparameter optimization via Bayesian methods. Both the
• Pooling Layer: This part is in charge of downsampling. It
training and testing processes utilized a strict fivefold
minimizes the size of the representations, accelerates
crossvalidation method datasets, with the Plant Village dataset
computations, and enhances the durability of some detected
serving as the basis for evaluation. The findings indicated that all
features. There are no parameters to learn for gradient
analyzed CNN models achieved impressive accuracy levels of up
to 97%, highlighting the effectiveness of CNNs in disease • descent in this layer. The hyperparameters related to
classification when appropriate parameters are applied. pooling include filter size and stride, with a typical choice
being a filter size of 2 X 2 and a stride of 2, which ultimately
In order to overcome the shortcomings of traditional image
reduces the dimensions of the representations by a factor of
processing techniques and enhance the precision of disease
2.
classification in maize plants, the work described in paper [10]
investigates deep transfer learning techniques. It examines the • Fully Connected (FC) Layer: Fully connected layers make
performance of four specific deep learning models in identifying dense connections to the neurons in the layer below using
subtle illness indicators: Inception V3, ResNet50, the flattened output from the pooling levels. A softmax
InceptionResNetV2, and VGGNET. With a validation accuracy of layer, which is frequently employed as the output layer for
87. 51%, precisions of 90. 33%, and a recall rate of 99. 80%, classification, can be connected to these neurons. The
ResNet50 stands out among these models. By using efficient and architecture of the network can influence the way many
adaptable disease classification techniques designed for maize completely connected layers a CNN has.
plants, these findings show the potential and benefits of deep
transfer learning in raising agricultural output.
3.2 DATA set:
Diseases in maize crops are identified using the Kaggle picture
dataset of maize plants. It includes a variety of pictures showing
[Link]: various diseases of maize plants. To improve accuracy, the
dataset is split into two sections: 30% testing and 70% training.
A. A. The convolutional neural The Harr cascade method employs a collection of attributes to
recognize diseases in maize plant photos and to identify the
3.1 CNN is a kind of deep neural network that is primarily utilized photographs. This study utilized a dataset that was generated by
for visual image analysis. Convolutional neural networks, or CNNs, augmenting the original TPD dataset.
are a subclass of artificial neural networks used in deep learning for
tasks including disease identification and picture classification.
CNN successful in several fields. Among these are convolutional
layers, which carry out the crucial function of feature extraction. A
typical CNN structure consists of a number of distinct parts or
layers. A CNN's conventional layout is depicted in Figure 1.
• Data Gathering: Users provide image data of maize plants either
through the mobile app or by uploading from their device's
storage.

• Data Preparation: To guarantee uniform sizes, modify colors,


and improve the dataset for model training, the stored data is
preprocessed.

• Development of Models: The prepared dataset is used to train


deep learning-based models through transfer learning methods.
Models like VGG16, ResNet50, and ResNet100 are utilized for
feature extraction.
Fig 2: exemplary images for every class in the tomato dataset
• Model Refinement: To facilitate efficient use on mobile
This collection comprises approximately 2400 RGB images of various devices, the trained models are adjusted and converted into
crop leaves—both healthy and unhealthy—affected by different TensorFlow Lite (TFLite) format.
diseases. The photographs have been used to create four different
groups. • Mobile App: The mobile application has features for taking
photos, conducting realtime analysis with the trained models,
showing the analysis results, and enabling user engagement.

3.2: Proposed System • Image Recognition: Object detection algorithms identify


In order to ensure precise categorization and diagnosis, the process of images that show disease before analysis, guaranteeing
precision in detecting maize plant diseases.
identifying diseases in tomato plants is organized in a specific
sequence. First, image data is obtained using Kaggle. During
• System Oversight: System management tasks such as
preparation, the images are resized to a uniform dimension of
administration, monitoring, and maintenance are in place to
224x224 pixels. Each disease category is assigned a distinct label, and
support the system's reliability, security, and performance.
the dataset is divided into training and testing sets. An initial feature
extraction and disease identification are performed using a Haar
Cascade classifier. After this, a Convolutional
3.3 The Proposed CNN

Fig 4. Architecture of the CNN experiment


This model consists of two convolutional layers, each containing 32
filters of size 3x3. Following that, there is a max pooling layer with a
2x2 window. The dimensions of the input are set to 256 × 256 x 3.
The following block contains two convolutional layers, each with 64
filters of size 3x3, along with a max pooling layer that replicates the
configuration of the first block.
Fig 3. The steps of proposed system
The configuration of the first block is duplicated in the third block, To assess the model's effectiveness in detecting illnesses on tomato
which contains 128 convolutional filters and two convolution layers, leaves, a confusion matrix is employed that demonstrates how
along with a max pooling layer. After the fully connected layer, there proficiently the model classifies the leaves. Four key elements exist
is a dropout layer with a rate of 0.5. Die Ausgabeschicht besteht aus to this matrix: True Positives (TPs), which are the diseased leaves that
38 Einheiten, was der Anzahl der Klassen entspricht. Except for the the model classified correctly; True Negatives (TNs), indicating the
output layer that utilizes a softmax function, all layers employ the healthy leaves that were correctly identified; False Positives (FPs),
Rectified Linear Unit (ReLU) as their activation function. In this where healthy leaves are wrongly classified as having disease; and
experiment, the settings used were the Adam optimizer, a batch size False Negatives (FNs), where diseased leaves are mistakenly
of 30, a dropout rate of 0.5, and a total of 10 epochs. categorized as healthy. Grasping these values is essential for
calculating important evaluation metrics score, which contribute to a
reliable assessment of the model's performance.
E. Metrics for assessing the model
IV. RESULTS AND DISCUSSION
To assess the effectiveness of the model, three metrics were utilized
demonstrates the model's excellent accuracy and dependability as it
in these experiments: True Positive (TP), True Negative (TN), False
reaches and stabilizes at approximately 97% by the 10th epoch. The
Positive (FP), and False Negative (FN).
sophisticated design of ResNet101, which successfully discerns
complex patterns and features in maize plant images and utilizes them
for precise disease classification, contributes to this outstanding
performance. This result highlights the model's potential for practical
applications in agriculture, allowing for rapid and precise disease
identification to enhance crop management. The results are illustrated
in Fig 8 and Table 2.

Fig [Link] Models


The metric for evaluating the performance of trained models. It offers
a thorough examination of the model's predictions and how accurate
they are in comparison to the real classes. When it comes to binary
classification tasks, like distinguishing between several illnesses in
maize plants, the confusion matrix is particularly useful.

Fig 7. Train & validation accuracy obtained using rennet[10]

Fig 6. Confusion matrix

Fig 8. Analysis Result of ResNet101 model


Deep Learning No of Epochs Accuracy
Models

Resnet 100 10 0.97


Fig 8 .
Web
Resnet 50 10 0.69 interface

VGG 16 10 0.94

TABLE 1. Performance of DL models


Fig 9 . Disease detection

CONCLUSION
Classifying Tomato leaf disease pridection using deep learning. By
combining several CNN architectures-MobileNetV2, VGG16, and
ResNet50- our model effectively extracts high-quality features while
lowering computational requirements. The Streamlining the dataset and
choosing the most pertinent features for classification.
The experimental results indicate that the proposed framework attains a
remarkable classification accuracy exceeding 97%, and it surpasses
conventional single-CNN models regarding both accuracy and
efficiency. Utilizing six different classifiers results in a more
reliable detection method, ensuring improved
generalization across various illness categories.
This research contributes, in practical terms, to the development of
sophisticated agricultural technologies that assist farmers in early
disease identification. greatly improve real-time case monitoring and
decision-making in smart farming systems or mobile applications.
Future research can investigate broadening this approach to encompass
a wider variety of crop diseases optimizing lightweight CNN
architectures for immediate deployment, and integrating real-world
environmental factors into the dataset to enhance model robustness,
Moreover, further advancements in feature selection methods and
classifier optimization can refine accuracy and efficiency even more
feature selection methods and classifier optimization can refine accuracy
and efficiency even more
feature selection methods and classifier optimization can refine
accuracy and efficiency even more

You might also like