Conference Paper 05 12
Conference Paper 05 12
Yash Kaushik1, Atul Kumar2, Vagarth Verma3, Yashvi Agarwal4 and Santosh Kumar
Upadhyay5
1,2,3,4,5
Computer Sciences and Engineering Ajay Kumar Garg Engineering College Ghaziabad, India
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
Abstract: Agriculture isa the most crucial part of a country’s economy thus it becomes
very important to introduce new technologies in this field to get better outcomes. The
yield highly depends on the health of crops and their treatment. Various technologies
have been introduced to detect diseases on leaves. This paper will discuss how to
segment multiple diseases on a leaf so that they can be detected and then cured. This
begins with pre-processing on the leaf using canny edgea detection to remove the
background and masking the image. Masks are classified into healthy, rust and scab. The
generated masks are combined into a single multi mask as- background=0, healthy=1,
rust=2, scab=3. Now this processed data is used for training and validation for models.
Canny edge detection algorithm is used here for segmentation. It uses convolutional and
pooling layers for pixel wise segmentation of diseased regions. It helps to identify
multiple disease patterns on the leaf. This algorithm works on every pixel that belongs to
one of the predefined classes. The model has a fixed number of epochs with a batch size
for which it has been trained. Thus, quantitative analysis can be done which can predict
severity of the disease and what measures to be taken to cure it.
Keywords: Canny edge detection· Segmentation · Plant disease · Scab ·
Rust · Mask image
1. Introduction
To ensure food and minimize crop losses, the early detection of plant disease is necessary.
The main problem faced by traditional manual inspection methods is that it is time
consuming and prone to human errors. It may also require domain expertise [14,15]. In
recent years, there have been advancements in deep learning and computer vision to
facilitate precise agriculture techniques and early detection [2][3][4] strategies by using
automated plant disease detection [5][6][7] and segmentation [18]. Advancement of
machine learning helps researchers to solve different agricultural issues like crop
recommendation [22][23], yield prediction [24][25], and disease detection [26]. This
research focuses mainly on using modern day image processing techniques and deep
learning-based segmentation models in order to detect, identify and classify infected regions
[8] on the plant leaf. This study focuses on traditional methods in computer vision (such as
edge detection and color-based segmentation) [17] in order to perform multi class
segmentation. The multi class masks are being generated by preprocessing the leaf images
which includes background removal and these help the model in learning to differentiate
between healthy parts and parts affected by rust and scab diseases. The scab disease is
caused by numerous fungi and pathogens, but in apple plant, the primary source of scab
infection is Venturia inadequacies. The dark and velvety spots that appears on stem, fruit or
leaves suggests the presence of the fungi infection. The infected area appeared to be a little
elevated and cracked over a period of time. The premature or yellowing of the leaves also
suggests the presence of the scab infection in the plant. The scab infection causes reduction
in the quality of the fruit of the plant and if not treated properly could reduce the
photosynthetic ability of the plant. This disease is spring season dominated disease and
found in cold and moist conditions. The spreading agents includes wind, rain and infected
debris. The rust disease on the contrary is caused by rust fungi that belongs to species like
Puccinia or Uromyces genus. The orange, red or brown pustules on the lower side of the
stems or the leaves suggests the presence of the rust fungi on the plant. Over period of time,
the leaves may become yellow and may also wither. If the infection is severe, the plants
yield drops and plants become weak. This leads to economic losses. If the infection persists
for long period of time, the productivity and vigor of plants reduces. This leads to drop in
quality and quantity of yield. Rust dominates in humid conditions with moderate to high
temperatures. The spreading agents that accelerate the spread includes windborne spores
which can affect large areas within short period of time. The preprocessing part uses Canny
edge detection [1] to isolate the leaf regions and HSV-based color segmentation to isolate
key features of the infected area. These preprocessing steps ensure that the model receives
high quality of input for further processing thus facilitating more accurate infected area
segmentation. The rough edges of the stuck healthy umbrella cover, rust and the scab
regions are all united to present a single multi class mask. The Canny edge detection
technique is being used on this high-quality input dataset to give segmented images as a
result, where each pixel belongs to a specific type of class: healthy, rust, scab or
background pixels. Comparison between scab and rust is shown in table 1. In order to
segment the leaf into three classes, which are healthy, rust diseased and scab diseased
leaves, the HSV, that is, hue, saturation and value color space is utilized. This paper states
the methodology details for preprocessing the images of plant leaves, generating the multi-
class masks and training a segmentation model based on deep learning for disease
segmentation. The approach proposed in this paper provides a scalable solution towards
plant disease diagnosis automation and has the potential to enable early detection and target
oriented treatments and thus improving agricultural productivity significantly. By providing
demonstration of the applications of above-mentioned techniques, this research aims at
providing a contribution to growing work on the field of integrating computer vision
techniques with machine learning to provide precision in agriculture, providing a
foundation for further advancements in automated plant health monitoring systems.
Edge detection techniques including Canny edge detection [1] and its variants are explored
for its applications in plant disease detection automation. The study shows how effective is
the algorithm in detecting boundaries and areas having high intensity, thus helping in tasks
including leaf disease segmentation and infected area classification. However there still
exists challenges in handling overlapping regions or regions having low contrast and direct
classification without proper segmenting the infected areas which sometimes leads to
reduced accuracy because of false results. The integration of edge detection with machine
learning and deep learning frameworks shows potential but still requires further
improvements for proper applicability in real world
Rice Crop Diseases, and Pest Detection Using Edge Detection Techniques and
Convolution Neural Network. P. Muruganandam et al. [9] discussed about how edge
detection methods along with CNN are used to detect pests and diseases in rice crops. The
study was unable to increase the CNN model’s accuracy in complex situations.
Leaf Classification and Identification Using Canny Edge Detector and SVM Classifier.
Salman et al.[10] use Canny Edge detection variants and studied the use of Canny edge
detection algorithm variants and studied the modified Canny edge detection algorithm in
domains such as leaf classification. It differentiated the sharp boundaries or areas with high
intensity that highlights the boundaries. But the result in overlapping areas or areas having
low contrast were not apt.
Leaf Disease Detection using Image processing. Suja Radha et al.[11] discussed the use of
machine learning classifiers. The study focused on the use of the classifiers like SVM and
Random Forest in classification of disease. The classification relies mainly on features that
are extracted from the leaf. These includes the color, texture and pattern on the leaves. The
study directly classifies without doing proper segmentation which lead to the generation of
false results.
D. Zhang et al. [14] discussed the use of image processing techniques for detecting rust
through multispectral imaging in soyabean plants. They collected the images of the leaves
that have been infected by the rust disease. Thereafter, they applied segmentation on those
images to extract out the infected areas that represented the region of interest and used this
segmentation to calculate the severity of the infection on the plant leaves.
Tian Y. et al. [15] discussed about the use of hyperspectral imaging in order to detect the
infected cucumber leaves infected due to pseudoperonospora cubensis . The study further
demonstrated that this technique can differentiate between healthy and infected regions on
the leaves with higher efficiency. This helped in early detection and early treatment.
Murali Krishnan et al. [16] worked on detecting infected area on leaf infected by bacterial
leaf scorch(BLS) caused by bacteria known as Xylella fastidiosa and used K-means
clustering for segmenting out the infected areas on leaves as region of interest. This proved
to be a non-destrtuctive approach.
3. Methodology
The project methodology comprises an orderly procedure in devising, testing and
implementing the deployed solution for leaf disease detection and leaf disease
segmentation. This strategy uses advanced image processing techniques such as Canny
Edge Detection and HSV color segmentation to locate and measure diseased areas of a
single leaf. The steps involved are as follows:
3.1. Dataset Overview This dataset is from competition that targets multi-class
classification of apple leaf diseases. It has reasonably clear pictures of the leaves
categorized into healthy leaves, those with scab, those with rust, or leaves with
several diseases. The meta files provided include train.csv (source of labels for
training), test.csv (source of labels for evaluation), and an empty submission
template.
3.2. Exploratory Data Analysis (EDA)
Class Imbalance Based on the observation, Carys[21] and her colleagues
suspected about the classes, specifically in multiple diseases class where not
enough instances were found. Some methods such as resampling or data
augmentation were attempted for the purpose of dataset balancing.
Image Features RBG histograms, distribution of pixel intensity values, color
transformation such as HSV were analyzed to see patterns specific to the target
diseases.
3.3. Preprocessing Phase
Background Removal as a preprocessing step, the Canny Edge Detection tool is
used to remove the background focusing only on the leaf region: The input image
is converted to black and white to ease the process of detecting outlines. A
Gaussian Blur was applied to include some noise and enhance the accuracy of the
edge detection mechanisms. Canny Edge Detection is employed to bring out
abrupt changes in the intensity of pixels. To cover the background, contours
around the perimeter of the edges are located and circles drawn around the edges.
Bitwise operations were applied over the image of the leaf region that has
shadow.
The Canny edge flowgraph is as shown in fig 1.
Fig. 1. Cannya Edge Detection Flowchart
4. Proposed Solution
4.1. Overview
The proposed solution addresses the challenge of detection of multiple diseases on
a single leaf such as rust and scab while also being able to identify the healthy
regions. This is achieved through the integration of Canny Edge Detection to
eliminate backgrounds and HSV color segmentation in order to classify the leaf
into healthy, rust, and scab regions. Furthermore, actionable information is given as
the levels of severity of the rust and scab diseases are also measured.
The very first step was to analyze the pixel value. We calculated the mean values
of the red, green, blue and total pixel intensities for all the images in the datasets
to analyze color intensity distribution. This part helps to aggregates color-based
metrics for statistical insights
The preprocessing involves using Canny Edge Detection that helps to detect leaf
edges and removal of the background.
Version 1 In this first attempt we directly create the mask as a white canvas and
fills the contours. With no extra description or segregations were done as shown in
fig 4.
Fig. 4. Version 1
Version 2 From the first attempt the functionality is similar but there is logical
segregation which is more explicit as shown in fig 5.
Fig. 5. Version 2
Rust and Scab severities are expressed in percentage of total leaf area as shown
in fig 6. The simulated result is shown in fig 7.
6. Conclusion
The paper talks about automated detection and segmentation of multiple disease in plants
and leaves classified as scab and rust specifically. The methodology includes computer
vision techniques such a s canny edge detection, HSV based color segmentation techniques.
It generates high quality mask images that classify pixels into healthy, rust, scab and
multiple. These provide foundation for using deep learning segmentation models by which
the disease accuracy and severity can be detected.
It is highly important to detecta the diseases at an early stage for maintaining the health of
the plants. It is equally essential to be able to detect multiple disease and their severity to
find its treatment and cure. The technique is to merge image processing and machine
learning to generate accurate diagnosis for plant disease and to be able to work on efficient
solution. The result demonstrates the potential of this technique and improving agriculture
sector.
References
1. Tian, Y., & Zhang, L. (2012). Study on the methods of detecting cucumber downy mildew
using hyperspectral imaging technology. ScienceDirect, 11(5), 743–750.
2. Upadhyay, S. K., & Kumar, A. (2021). Early-stage brown spot disease recognition in paddy
using image processing and deep learning techniques. Traitement du Signal, 38(6), 1755–
1766. https://doi.org/10.18280/ts.380619
3. Upadhyay, S. K., & Kumar, A. (2022). A novel approach for rice plant diseases
classification with deep convolutional neural network. International Journal of Information
Technology, 14, 185–199. https://doi.org/10.1007/s41870-021-00817-5
4. Rukhsar, & Upadhyay, S. K. (2022). Rice leaves disease detection and classification using
transfer learning technique. 2022 2nd International Conference on Advance Computing and
Innovative Technologies in Engineering (ICACITE), 2151–2156.
https://doi.org/10.1109/ICACITE53722.2022.9823596
5. Upadhyay, S. K., & Kumar, A. (2022). An accurate and automated plant disease detection
system using transfer learning-based Inception V3 model. 2022 2nd International
Conference on Advance Computing and Innovative Technologies in Engineering
(ICACITE), 1144–1151. https://doi.org/10.1109/ICACITE53722.2022.9823559
6. Rukhsar, & Upadhyay, S. K. (2022). Deep transfer learning-based rice leaves disease
diagnosis and classification model using InceptionV3. 2022 International Conference on
Computational Intelligence and Sustainable Engineering Solutions (CISES), 493–499.
https://doi.org/10.1109/CISES54857.2022.9844374
7. Upadhyay, S. K., & Kumar, A. (2023). Automatic recognition and classification of tomato
leaf diseases using a transfer learning model. Future Farming: Advancing Agriculture with
Artificial Intelligence, 1(23). https://doi.org/10.2174/9789815124729123010005
8. Upadhyay, S., Jain, J., & Prasad, R. (2024). Early blight and late blight disease detection in
potato using EfficientNetB0. International Journal of Experimental Research and Review,
38, 15–25. https://doi.org/10.52756/ijerr.2024.v38.002
9. Muruganandam, P., Tandon, V., & Baranidharan, B. (2022). Rice crop diseases and pest
detection using edge detection techniques and convolutional neural network. In J. C. Bansal,
A. Engelbrecht, & P. K. Shukla (Eds.), Computer Vision and Robotics. Algorithms for
Intelligent Systems. Springer, Singapore.
10. Salman, A., Semwal, A., Bhatt, U., & Thakkar, V. M. (2017). Leaf classification and
identification using Canny edge detector and SVM classifier. 2017 International Conference
on Inventive Systems and Control (ICISC), Coimbatore, India.
11. Radha, S. (2017). Leaf disease detection using image processing. Journal of Chemical and
Pharmaceutical Sciences.
12. Bonifacio, D., Pascual, A. M. E., Caya, M. V. C., & Fausto, J. C. (2020). Determination of
common maize (Zea mays) disease detection using gray-level segmentation and edge-
detection technique. 2020 IEEE 12th International Conference on Humanoid,
Nanotechnology, Information Technology, Communication and Control, Environment, and
Management (HNICEM).
13. Raj, N., Perumal, S., Singla, S., Sharma, G. K., Qamar, S., & Chakkaravarthy, A. P. (2022).
Computer-aided agriculture development for crop disease detection by segmentation and
classification using deep learning architectures. Computers and Electrical Engineering, 103,
108357.
14. Cui, D., Zhang, Q., Li, M., Hartman, G. L., & Zhao, Y. (2010). Image processing methods
for quantitatively detecting soybean rust from multispectral images. ScienceDirect, 22(4),
186–193.
15. Tian, Y., & Zhang, L. (2012). Study on the methods of detecting cucumber downy mildew
using hyperspectral imaging technology. ScienceDirect, 11(5), 743–750.
16. Krishnan, M., & Sumithra, M. G. (2013). A novel algorithm for detecting bacterial leaf
scorch (BLS) of shade trees using image processing. IEEE 11th Malaysia International
Conference on Communications.
17. Radha, S. (2017). Leaf disease detection using image processing. Journal of Chemical and
Pharmaceutical Sciences.
18. Katyal, V., & Aviral. Leaf vein segmentation using odd Gabor filters and morphological
operations.
19. Devaraj, A., Rathan, K., Jaahnavi, S., & Indira, K. (2019). Identification of plant disease
using image processing technique. International Conference on Communication and Signal
Processing.
20. Sannakki, S. S., Rajpurohit, V. S., & Birje, S. J. (n.d.). Comparison of different leaf edge
detection algorithms using fuzzy mathematical morphology. International Journal of
Innovations in Engineering and Technology (IJIET).
21. Christine Kaeser-Chen, Fruit Pathology, Maggie, and Sohier Dane authored the Plant
Pathology 2020 - FGVC7 dataset, released in 2020.
22. Upadhyay, S. K. and Vikas, "Intelligent Crop Recommendation using Machine
Learning," 2024 International Conference on Automation and Computation (AUTOCOM),
Dehradun, India, 2024, pp. 330-335, doi: 10.1109/AUTOCOM60220.2024.10486182
23. Upadhyay, S. K, Upadhyay, H., Tripathi, H., Rawat, K. P. and Sharma, L. (2024). Smart
Crop Recommendation for Modern Farming using Machine Learning, 1st International
Conference on Advanced Computing and Emerging Technologies (ACET), Ghaziabad, India,
2024, pp. 1-7, doi: 10.1109/ACET61898.2024.10730582.
24. Upadhyay, S. K., Kushwaha, P. and Garg, P. (2024). A Machine Learning Approach for
Predicting Crop Yield in Precision Agriculture, International Conference on Automation
and Computation (AUTOCOM), Dehradun, India, 2024, pp. 289-294, doi:
10.1109/AUTOCOM60220.2024.10486160.
25. Upadhyay, S. K., Kushwaha, P., Garg, P.,Pandey, M. N. and Kumar, M. (2024). Predictive
Insights in Precision Agriculture: Leveraging Deep Learning for Crop Yield Estimation,
IEEE International Conference on Smart Power Control and Renewable Energy
(ICSPCRE), Rourkela, India, 2024, pp. 1-6, doi: 10.1109/ICSPCRE62303.2024.10675180.
26. Upadhyay, S.K., Singh, R., Kumar, A., Sagar, N. (2024). Rice Leaves Disease Detection
Mechanism Using VGG16 Deep Learning Architecture. In: Bhattacharya, A., Dutta, S.,
Dutta, P., Samanta, D. (eds) Innovations in Data Analytics. ICIDA 2023. Lecture Notes in
Networks and Systems, vol 1005. Springer, Singapore. https://doi.org/10.1007/978-981-97-
4928-7_17