0% found this document useful (0 votes)
17 views

Strawberry Disease Detection Through An Advanced Squeeze-and-Excitation Deep Learning Model

Uploaded by

merlin xavier
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)
17 views

Strawberry Disease Detection Through An Advanced Squeeze-and-Excitation Deep Learning Model

Uploaded by

merlin xavier
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
You are on page 1/ 9

This article has been accepted for inclusion in a future issue of this journal.

Content is final as presented, with the exception of pagination.

IEEE TRANSACTIONS ON AGRIFOOD ELECTRONICS, VOL. 00, NO. 0, 2024 1

Strawberry Disease Detection Through an Advanced


Squeeze-and-Excitation Deep Learning Model
Jiayi Wu, Vahid Abolghasemi , Senior Member, IEEE, Mohammad Hossein Anisi , Senior Member, IEEE,
Usman Dar, Andrey Ivanov, and Chris Newenham

Abstract—In this article, an innovative deep learning-driven to identify potential kinds of disease objects. Traditional tech-
framework, adapted for the identification of diseases in straw- niques are mainly performed manually by growers, which is a
berry plants, is proposed. Our approach encompasses a compre-
labor-intensive and time-consuming task. In large-scale farm-
hensive embedded electronic system, incorporating sensor data
acquisition and image capturing from the plants. These images are ing systems, it is difficult to make an accurate estimate of
seamlessly transmitted to the cloud through a dedicated gateway the infected areas and the severity [2]. Today, there are many
for subsequent analysis. The research introduces a novel model, different types of plant diseases in different stages of growth
ResNet9-SE, a modified ResNet architecture featuring two squeeze- and several growing areas, which makes it difficult for laymen to
and-excitation (SE) blocks strategically positioned within the net- accurately identify the types of disease in a short period and on a
work to enhance performance. The key advantage gained is achiev-
ing fewer parameters and occupying less memory while preserving large scale. Besides, manual identification has the disadvantages
a high diagnosis accuracy. The proposed model is evaluated using of slow identification speed and low accuracy, which poses
in-house collected data and a publicly available dataset. The exper- a major challenge in containing the outbreak of diseases in
imental outcomes demonstrate the exceptional classification accu- agriculture.
racy of the ResNet9-SE model (99.7%), coupled with significantly In particular, the impact of disease on strawberry yield has
reduced computation costs, affirming its suitability for deployment
in embedded systems. become more serious due to its soft and delicate nature. Some
major strawberry plant diseases include powdery mildew, botry-
Index Terms—Computer vision, crop monitoring, deep learning, tis cinerea, anthracnose, and angular leaf spot. Diseases affect-
Internet of Things (IoT), plant disease detection.
ing strawberry crops have multifaceted impacts, ranging from
diminished yields and compromised fruit quality to economic
I. INTRODUCTION losses for farmers. The need for chemical interventions to man-
LANT diseases have become a major concern in today’s age diseases contributes to increased production costs and may
P forestry development. The impact of different diseases
is all-encompassing, affecting plants externally and internally,
disrupt sustainable agricultural practices. Rapid disease spread
poses contamination risks, while climate change vulnerabilities
from the top to the bottom, spanning from flowers and fruits further stress plant resilience. To this end, integrating smart data
down to the root system. This not only affects the normal collection and transmission with artificial intelligence (AI) for
growth of plants but can also cause a reduction in the yield early disease detection in plants can mitigate these challenges.
and quality of agricultural products and, in serious cases, food This could offer the potential to swiftly identify and manage
safety problems [1]. Therefore, rapid identification and diag- diseases, minimizing the reliance on chemical interventions.
nosis of plant diseases can reduce the economic losses caused This approach not only enhances sustainability by reducing
by plant diseases to the agricultural industry in the shortest environmental impact but also contributes to improved fruit
possible time. Plant disease identification is a technique for quality.
processing, analyzing, and understanding plant image datasets With the continuous development of deep learning on the
one hand, and increasing the computation power on another
hand, many researchers have started to study plant disease
Manuscript received 4 February 2024; revised 15 April 2024; accepted 4 June identification based on deep learning with either sensors or
2024. This work was supported by a Knowledge Transfer Partnership (KTP) image data (or both). Using computer vision technology to
from Innovate U.K. under Partnership 12298, between Wilkin & Sons Ltd. and identify plant disease areas and species can effectively reduce
the University of Essex. This article was recommended by Associate Editor
Matias Miguez. (Corresponding author: Mohammad Hossein Anisi.) time costs and improve the efficiency of agricultural produc-
Jiayi Wu is with Xidian University, Xi’an 710071, China (e-mail: ji- tion [3]. Furthermore, with the advances in the Internet of Things
[email protected]). (IoT) technology, effective and continuous monitoring of various
Vahid Abolghasemi and Mohammad Hossein Anisi are with the School of
Computer Science and Electronic Engineering, University of Essex, CO4 3SQ systems has become easier and more accessible. This has led
Colchester, U.K. (e-mail: [email protected]; [email protected]). to greater autonomy of systems in practice. The solutions that
Usman Dar, Andrey Ivanov, and Chris Newenham are with Wilkin & IoT offers are complemented by machine learning (ML) and
Sons, CO5 0RF Colchester, U.K. (e-mail: [email protected]; [email protected];
[email protected]). computer vision-based techniques to improve classification and
Digital Object Identifier 10.1109/TAFE.2024.3412285 detection performance.

2771-9529 © 2024 IEEE. Personal use is permitted, but republication/redistribution requires IEEE permission.
See https://www.ieee.org/publications/rights/index.html for more information.

Authorized licensed use limited to: VTU Consortium. Downloaded on July 01,2024 at 08:09:08 UTC from IEEE Xplore. Restrictions apply.
This article has been accepted for inclusion in a future issue of this journal. Content is final as presented, with the exception of pagination.

2 IEEE TRANSACTIONS ON AGRIFOOD ELECTRONICS, VOL. 00, NO. 0, 2024

A. Our Contributions the need for expensive cameras for imaging. Abbas et al. [8] used
There is limited research on the utilization of reliable a deep learning model to identify strawberry fungal leaf blight in
IoT systems for agricultural data collection and processing. strawberry fields in real-time. By training and testing four CNN
Furthermore, there is a lack of focused research on early on- (SqueezeNet, EfficientNet-B3, VGG-16, and AlexNet) models,
set detection for strawberry plants. In our previous work, we they evaluated health and leaf scorch. Their study showed that
demonstrated the development of a prototype convolutional the model EfficientNet-B3 achieved the highest classification
neural network (CNN) capable of classifying three types of accuracy, 80% and 86% for the initial and severe stages of the
strawberry images: healthy, powdery mildew-affected, and leaf disease, respectively. The model proposed by Tariqul and Islam
scorch-affected. We obtained an average accuracy of 95.48% [9] was designed to diagnose the disease leaf of grapes and
[4]. Furthermore, we have established an advanced test-bed in strawberries. They used a CNN model to train the dataset where
Wilkin & Sons farm, dedicated to sensors and images’ data an accuracy rate of 93.63% was obtained.
collection from the strawberry farms [5]. A self-constructed SPIKE dataset from images of relevant
In this article, three major contributions are introduced. First, complex wheat fields was used in an object detection method
we demonstrate the details of a fully scalable and automated based on identifying diseased plants (or parts affected by dis-
system (including sensors, cameras, and connectivity, etc.) that eases or pathogens) proposed by Hasan et al. [10]. The model
can be utilized in agricultural applications. Our hardware design used was an R-CNN architecture that generated four different
can be easily adapted and extended for data collecting data from models, four different datasets of training, and test images
an operational farm. Using this system, we can have valuable based on four different datasets to capture plant diseases at
sensory and imagery data for future analysis. Second, we provide different growth stages with an accuracy of 93.4%. Toda and
a comprehensive overview of the state-of-the-art in plant disease Okura [11] employed the YOLOv3-DenseNet algorithm for
detection (with a focus on strawberry plants) in both hardware direct object detection, focusing on disease object detection
design and ML approaches. Third, we propose a novel deep concerning growing apple leaves, with an accuracy of 95.75%.
learning architecture benefiting from a unique feature, i.e., a And using human intervention to validate the authenticity of the
squeeze-and-excitation (SE) block to reduce the number of model and the training dataset, a CNN trained using publicly
model parameters and hence occupying less memory leading to available plant disease image datasets, various neuron and layer
better adaptation to hardware implementation. We also introduce visualization methods were applied. Zhang et al. [12] developed
a “variable learning rate” in our model which leads to higher a method, called GPDCNN, for multiclass classification detec-
accuracy compared to a fixed rate. Our results exhibit robust tion of cucumber images, i.e., using different stages of the plant
performance, showcasing the potential for automated, real-time for possible disease detection, where the accuracy of 94.65%
disease identification. was achieved.
The rest of this article is organized as follows. The next section In another study, Hari et al. [13] used the PDDNN algorithm
reviews the related works. In Section III, the proposed system for for the detection of various plant disease images, using
both the data collection and ML stages is described. Section IV TensorFlow as the framework, with an accuracy of 86%. As
is devoted to experimental results and data analysis. Finally, a comparison, Picon et al. [14] also published a paper using
Section V concludes this article. the RESNET-MC1 algorithm for the detection of various plant
disease images using TensorFlow and Keras as the framework of
choice, with an accuracy of 98%. Howlader et al. [15] employed
II. RELATED WORKS the AlexNet algorithm to detect plant diseases on guava leaves
Existing studies have investigated the use of ML algorithms with an accuracy of 98.74%. Nagasubramanian et al. [16] used
for the early detection of various plant diseases, and notable ef- the 3-D-CNN algorithm to detect plant diseases in soybean using
forts have been directed towards addressing strawberry-specific a binary classification method, i.e., only diseased or healthy,
issues. ML models, particularly CNNs and support vector ma- without distinguishing between specific growth regions and
chines (SVMs) have demonstrated significant promise in accu- growth stages, with an accuracy of 95.73%. Pal and Kumar [17]
rately identifying and classifying different strawberry diseases. proposed an Agricultural Inspection (AgriDet) framework,
Researchers in [6] presented an approach using deep learning which combines the traditional Inception-Visual Geometry
techniques to detect powdery mildew disease on strawberry Group network (INC-VGGN) and the Kohonen-based deep
leaves. Due to dealing with a small dataset, they have applied learning network to detect plant diseases and classify the
data augmentation for around 1400 healthy and infected leaf im- severity of diseased plants where the performance of the
ages to prevent overfitting. Their study suggests that SqueezeNet statistical analysis is validated to demonstrate the effectiveness
would be the most suitable model when considering the mem- of the results in terms of accuracy, specificity, and sensitivity.
ory requirements for hardware deployment. Additionally, Jiang In the article by Mathew et al. [18], the SVM classifier was
et al. [7] explored the integration of spectral imaging and ML replaced with a voting classifier to classify the data into multiple
for early disease diagnosis in strawberry plants. By extracting classes. The accuracy of voting and SVM classifiers is compared.
intricate features from hyperspectral data, their model achieved The results show that the accuracy of the proposed method is
high accuracy in distinguishing between healthy and infected improved by 10%. Bedi and Gole [19] proposed a hybrid system
plants, providing valuable insights into the spectral signatures based on convolutional auto-encoder (CAE) and CNN that can
associated with specific diseases. The drawback of this system is achieve automatic detection of plant diseases. In the experiment,

Authorized licensed use limited to: VTU Consortium. Downloaded on July 01,2024 at 08:09:08 UTC from IEEE Xplore. Restrictions apply.
This article has been accepted for inclusion in a future issue of this journal. Content is final as presented, with the exception of pagination.

WU et al.: STRAWBERRY DISEASE DETECTION THROUGH AN ADVANCED SQUEEZE-AND-EXCITATION DEEP LEARNING MODEL 3

CAE is used to compress the parameters required for training,


and the parameters required for the hybrid model are reduced.
The proposed hybrid model used only 9914 training parame-
ters. The experiment uses a public dataset called PlantVillage
to obtain leaf images of peach plants with the training and
testing accuracies reported at 99.35% and 98.38%, respectively.
Abdalla et al. [20] used the VGG16 Encoder algorithm to detect
binary segmentation of 400 oilseed images in two different
environments with an accuracy of 96%. Fig. 1. Data collection, transmission, and analysis layout.
Some studies also address image segmentation during (or
before) disease detection. Lin et al. [21] used the U-Net seg- environmental variations. Future research directions may in-
mentation algorithm to segment cucumber leaves with an ac- volve the refinement of existing models, the exploration of trans-
curacy of 96.08%. Wiesner-Hanks et al. [22] implemented a fer learning techniques, and the incorporation of explainable
binary segmentation task to identify maize diseases using the AI for transparent decision-making in the agricultural domain.
ResNet - Crowdsourced algorithm for binary segmentation, The convergence of ML and AI technologies holds immense
which divides the image into homogeneous regions according to promise for revolutionizing strawberry disease detection. The
defined criteria and generates a binary image of the plant disease amalgamation of sophisticated algorithms, sensor technologies,
with the highest accuracy rate, i.e., 99.79%. In a recent study, Li and data analytics paves the way for sustainable, technology-
et al. [23] addressed the detection of powdery mildew on straw- driven agriculture, ensuring the resilience of strawberry crops
berry leaves based on DAC-YOLOv4 model. They compared against the threat of diseases and contributing to global food
several models and also deployed their algorithm on the Jetson security initiatives.
Xavier NX and Jetson Nano hardware to meet the real-time
detection requirements. Their experimental results indicated that III. PROPOSED SYSTEM
the DAC-YOLOv4 can provide an acceptable performance in
strawberry leaf detection on the embedded platform. In [24], a In this section, we showcase the details and results of our
mango fruit grading system using a computer vision approach plant disease detection system. As shown in Fig. 1, we develop a
was proposed. The proposed method classified the fruit images network of sensors and cameras that are wirelessly connected to
using an AlexNet–spatial pyramid pooling network (SPP-Net) a base station, continuously monitor the conditions of plants, and
with a segmentation algorithm based on a mask region-based seamlessly transmit the images and sensors’ data. In the follow-
CNN (R-CNN). ing, first, the hardware specifications and design for data/image
Furthermore, the intersection of IoT devices and ML for capturing and communication are described. Then, the results
continuous monitoring has been a focal point. However, there of applying novel deep learning models on both the collected
exist limited works reported on developments of plant disease dataset and existing datasets are provided.
diagnosis with on-board hardware. Kim et al. [25] proposed a
sensor-based system that collected environmental data and em- A. Data Collection
ployed ML algorithms to predict disease outbreaks in strawberry The imaging system is composed of an SVC3 camera that
crops. This proactive approach offers the potential for timely can capture images at 2560 × 1920 resolution. The camera
interventions and preventive measures. Pankaj et al. [26] pro- features 20× optical zoom as well as 255◦ pan and 120◦ tilt
posed an IoT hardware sensor-based cotton disease prediction that enables the capture of high-quality close-up images of the
using a CNN. Their IoT gadget has different sensors, such as plant matter over a large area. A Raspberry Pi-based camera
temperature, humidity, and PH, to collect the data to be used controller which is deployed on the same Wi-Fi network as the
for classification. In another work by Mora et al., [27], a plant cameras, requests images from each camera at fixed intervals
disease detection using the Raspberry Pi 4 was implemented. Not during the day before uploading them via a Wi-Fi access point.
many results are reported in this work, however, an accuracy of In contrast to the imaging system, the sensor network has been
around 90% was obtained for the prediction of plant disease on a custom-designed to meet the needs of this application. The
private dataset. A diagnostic system implemented on Raspberry ATMega644p microcontroller, shown in Fig. 2(a), is respon-
Pi was proposed for scab and leaf disease detection. The authors sible for interfacing with seven sensor modules; temperature,
used a CNN model and four classes of scab, black rot, cedar pressure, humidity, ambient light, UV light, soil moisture, and
rust, and healthy were detected. A smart crop growth monitoring leaf wetness. The microcontroller samples the sensors roughly
using edge artificial intelligence (AI) was developed in [28] once every 30 minutes and uses a Semtech SX1262 LoRa
where a complex system was implemented to monitor health transceiver to transmit the data to a Dragino LG01-N LoRa
plants and classify the pest and disease severity. They used gateway, which pushes this data to a privately hosted server that
cryptographic hardware modules, including RTEA32, RTEA64, is responsible for parsing the data and storing it in a database
XTEA32, and XTEA64, and used the binarized neural network hosted on Amazon Web Services. The system is designed to be
and achieved 76.57% accuracy for disease detection on dragon flexible to the farm conditions through the modular architecture
fruits. allowing different components (hardware and software) to be
While strides have been made, challenges persist, including easily added, removed, or replaced without disrupting the overall
the need for diverse datasets representative of geographical and functionality. This facilitates scalability and the addition of new
Authorized licensed use limited to: VTU Consortium. Downloaded on July 01,2024 at 08:09:08 UTC from IEEE Xplore. Restrictions apply.
This article has been accepted for inclusion in a future issue of this journal. Content is final as presented, with the exception of pagination.

4 IEEE TRANSACTIONS ON AGRIFOOD ELECTRONICS, VOL. 00, NO. 0, 2024

Fig. 2. Proposed IoT-based plant disease detection system implemented at Wilkin & Sons in Tiptree. (a) View of the entire sensing and imaging system, (b) the
processing unit hardware, and (c) the camera installed with a view of the farm.

sensors or devices to adapt to the specific needs of different blocks, regularizing each layer first, then using ReLU as the
farms. Our power-efficient hardware and software components activation function and max pooling to reduce the size of the data
can maximize battery life and minimize energy consumption in and increase the speed of computation. Furthermore, the Adam
remote farm environments where access to power sources may optimizer and the cross-entropy loss function were employed
be limited. in this model. In the last layer, the data are flattened, and linear
regression is used to classify the different types of plant diseases.
2) ResNet9-SE: To further enhance the discriminative power
B. Data Analysis of our model, we introduce SE blocks into the ResNet9 archi-
1) ResNet9: ResNet [29], with its ability to train very deep tecture. SE blocks have proven effective in capturing channel-
networks effectively, has found applications in various computer wise dependencies, allowing the network to focus on essen-
vision tasks, including plant disease diagnosis. In this study, tial features while suppressing less informative ones. The SE
we enhance the performance ResNet9 by introducing the SE block consists of two key operations: squeeze and excitation.
blocks. The key innovation in ResNet is the utilization of residual In the squeeze operation, global average pooling is applied
blocks, which allow the model to skip connections across layers. to compress spatial information into channelwise descriptors.
Traditional deep networks often suffer from the vanishing gra- The dimensions of the original feature map are H × W × C,
dient problem, making it difficult to train very deep networks. where H is the height, W is the width, and C is the number
Residual blocks alleviate this issue by introducing shortcut of channels of the input data matrix. What squeeze does is
connections or skip connections, which enable the gradient compress H × W × C into 1 × 1 × C, which is equivalent to
to flow directly through the network. The basic ResNet lay- compressing H and W into one dimension. In practice, it is
ers include convolutional layers (for initial feature extraction), generally implemented using global average pooling. After H
residual blocks (the core building blocks of ResNet, consisting and W are compressed into one dimension, this dimensional
of stacked convolutional layers with skip connections), pooling parameter obtains the global view of the previous H × W , and
layers (to reduce spatial dimensions), and fully connected (FC) the sensing area is wider.
layers (often used for classification tasks). The excitation operation involves learning channelwise at-
Many variants of ResNet model have been proposed in the tention weights that are then applied to the input features. After
literature. Among these, ResNet9 has a relatively shallow ver- obtaining the 1 × 1 × C representation of squeeze, add a FC
sion of the ResNet architecture compared to deeper variants layer to predict the importance of each channel, obtain the
like ResNet50 or ResNet101. In scenarios with limited data importance of different channels, and then apply (stimulate) it
or computational resources (such as our case), a shallower to the previous feature. On the corresponding channel of the
network may be more practical while still benefiting from the map, perform subsequent operations. This adaptive recalibration
advantages of residual connections. When choosing a neural mechanism enables our model to better capture intricate patterns
network architecture for plant disease diagnosis, factors such as and crucial information relevant to plant disease detection. The
the size of the dataset, computational resources, and the specific SE block contains a global average pooling layer, two FC layers,
requirements of the application should be considered. ResNet9 and a Sigmoid activation function. The calculation process is as
offers a good balance of performance and efficiency, making it follows:
a viable option for image classification tasks, including plant 1) F = FC1 (Z)
disease diagnosis. 2) F = ReLU(F )
As mentioned above, we used the 9-layer structure of the 3) F  = FC2 (F )
ResNet as a baseline. In this model, each layer feeds into the 4) SE(X) = Sigmoid(F  )
next layer and directly into the layers about 2–3 hops away. where X is the input of the SE block, Z denotes the output of
Conventional preprocessing, such as image resizing, was applied the first pooling layer, F is the output of the FC layer (which is
to input images where required. The network in this study uses updated by ReLU function), and F  is the output of the second
a combination of two convolutional layers and two residual FC layer which is inputted into sigmoid function to yield the
Authorized licensed use limited to: VTU Consortium. Downloaded on July 01,2024 at 08:09:08 UTC from IEEE Xplore. Restrictions apply.
This article has been accepted for inclusion in a future issue of this journal. Content is final as presented, with the exception of pagination.

WU et al.: STRAWBERRY DISEASE DETECTION THROUGH AN ADVANCED SQUEEZE-AND-EXCITATION DEEP LEARNING MODEL 5

Fig. 3. Structure of the proposed model based on ResNet with SE blocks.

output result of the whole SE block. The mathematical equation


for SE is as follows:
SE = σ(W2 γ(W1 z + b1 ) + b2 ) (1)
where σ is the sigmoid, γ denotes the ReLU function, and {W1 ∈
C C
R 1 xC , b1 } and {W2 ∈ R 1 xC , b2 } are the weights connecting
two FC layers. Inside the SE, the computational cost and capacity
are controlled by a reduction ratio r. The input X and the scalar
SE are multiplied channel-by-channel to obtain the final output Fig. 4. Sample images of strawberry plants for (a) healthy, (b) leaf scorch, and
(c) powdery mildew.
XSE = X ⊗ SE (2)
where ⊗ denotes the channelwise multiplication. The SE struc-
ture will retain useful features and reduce unnecessary features scorch) images. The other private dataset, called the “strawberry
to boost the network’s performance. dataset,” contains healthy strawberries and two types of diseases
Fig. 3 shows the proposed structure of the ResNet9-SE model. of strawberry, including strawberry leaf scorch and strawberry
To appropriately integrate the SE block into the ResNet structure, mildew. Each type contains about 2000 pictures of strawberries.
we embed two SE blocks at the end of each residual block. For Some sample images of healthy and diseased plants are shown
each SE block, global average pooling is first used to implement in Fig. 4.
the squeeze operation, and then the FC layer, linear rectification For proper model evaluation, a tenfold cross-validation was
function, and activation function are used to implement the exci- considered on both datasets for the evaluation of different
tation operation. The output of the SE block is combined with the algorithms. The ratio for train and test subsets was chosen to be
output of the residual block through elementwise multiplication, 80% and 20%, respectively. Also, to evaluate the performance of
enabling dynamic adjustment of features. the proposed algorithm for disease detection, three well-known
performance metrics were used. The accuracy, defined as the
IV. EXPERIMENTAL RESULTS ratio of correctly identified samples to the total samples, serves
as a comprehensive metric for assessing the overall performance
A. Experimental Setup and Performance Metrics
of the algorithm. To quantify the accuracy of an algorithm in
To provide a comprehensive evaluation and the generalizabil- detecting corn diseases, the following was employed:
ity power of the proposed system, we use a widely used public
TP + TN
dataset, i.e., “PlantVillage” as well as data collected by ourselves Accuracy = (3)
at Wilkin & Sons in Tiptree [21] (see Fig. 1). The original TP + TN + FP + FN
PlantVillage dataset consists of about 87 000 RGB images of where TP is the true positive (i.e., samples that have the disease
healthy and diseased crop leaves, which are categorized into and were correctly identified as such), and TN is the true
38 different classes of 14 unique plants, including strawberry. negative (i.e., samples that do not have the disease and were
In this study, we used the strawberry images from PlantVillage correctly identified as such). Also, FP is the false positive (i.e.,
dataset, which consists of over 800 healthy and unhealthy (leaf samples that do not have the disease but were wrongly identified

Authorized licensed use limited to: VTU Consortium. Downloaded on July 01,2024 at 08:09:08 UTC from IEEE Xplore. Restrictions apply.
This article has been accepted for inclusion in a future issue of this journal. Content is final as presented, with the exception of pagination.

6 IEEE TRANSACTIONS ON AGRIFOOD ELECTRONICS, VOL. 00, NO. 0, 2024

as having it), and FN is the false negative (i.e., samples that TABLE I
FINETUNING VERSUS FINAL LAYER TRAINING STATISTICS
have the disease but were wrongly identified as not having it).
We also used another metric, called Recall, to measure the
capability of the proposed models to correctly images of straw-
berry plants that are infected with a specific disease

TP
Recall = . (4)
TP + TN

The final performance metric is F1-Score, which represents


the harmonic mean of precision and sensitivity score which C. Classification Results
is a commonly used performance evaluation metric in ML Before demonstrating the results obtained using the proposed
approaches, particularly in binary classification tasks ResNet9-SE model, we demonstrate and compare the perfor-
mance for state-of-the-art algorithms using transfer learning
P recision × Recall
F 1Score = 2 × . (5) (i.e., pretrained models on the ImageNet database). The aim is
P recision + Recall to show why we have selected the ResNet model as our baseline
In (5), Precision is a metric that measures how often the model and to modify it to receive the best performance. While not
correctly predicts the positive class and is defined via all the images in the ImageNet dataset were relevant to the
aims and objectives of this study, further training the models
TP on the strawberry dataset yielded two important benefits. First,
P recision = . (6) the model’s generalizability was far greater as it was able to
TP + FP
leverage the knowledge gained from the large ImageNet dataset
The machine used for conducting the experiments was to reduce biases. Second, the losses were lower, and the models
equipped with the NVIDIA RTX 3070 GPU which has 5888 converged much faster since the weights and parameters were
CUDA cores and 8 GB of VRAM. The GPU was interfaced already well optimized for image classification problems.
with an Intel i5-8400 @ 2.8 GHz CPU with access to 16 GB of Before the pretrained models could be used within the context
RAM. of this study, their architectures had to be adjusted. This meant
that for all the models, the FC output layer had to be redefined and
initialized without the pretrained weights. This was performed
B. Preprocessing
to merely update the weights in the newly redefined final layer
Before training the model, the images were transformed and while keeping all other weights the same. This would allow for
augmented to prepare the data for the input layer of the networks faster, training of the models since the backpropagation would
and to reduce biases. The first step was to perform a normaliza- be limited to only the final layer, resulting in fewer calculations
tion operation on the images. This was done by calculating the needing to be done. The other approach, fine-tuning, would
mean and standard deviation of the entire dataset, individually require all the weights to be adjusted at every step during the
across each of the RGB channels. The resulting values were then training, which would increase the training time significantly
used to normalize the images to account for the variations in the due to the number of calculations required. To determine the fea-
way the images were captured. The second step was to resize sibility of four models (i.e., Resnet50, Resnet100, GoogleNet,
the images to one standard size that the input to the classifier and AlexNet), each architecture was trained with a learning rate
accepts. This is done to account for the various image sizes of 0.01 and batch size of 32 for 100 epochs twice, with and
in the dataset. The consequence of this approach is that every without fine-tuning approach. The times and accuracies of each
image that is passed through the classifier during evaluation of the models were observed after the hundred epochs, the results
and deployment will also have to be resized. The dimensions of which are summarized in Table I. As seen from this table,
chosen were 224 × 224 pixels as this is a standard used in many fine-tuning has a positive effect on the running time and most
widely used architectures, allowing for a convenient way to swap models have achieved acceptable accuracy with ResNet50 being
architectures if required. Additionally, this allowed for better the best.
direct comparisons between architectures as the dimensionality The optimizer used was stochastic gradient descent (SGD)
of the input was kept consistent throughout the comparisons. with momentum. Using SGD with momentum allowed models
The data were augmented by introducing random vertical and trained with lower learning rates to carry their “momentum”
horizontal and vertical flips as well as random 30◦ rotations. as they descended into minima. This allowed the models to
This allowed for biases relating to image orientation to be overcome any shallow local minima that they descended into
reduced significantly. This step was crucial to improving system and significantly increased their likelihood of converging at the
generalizability as most images of the plants were taken with absolute minimum loss or at least a deeper minima, which would
the stem appearing on the lower half of the image. In practice, provide better classification accuracy.
this is not always the case, so it was important to ensure that Both the optimizer (used to adjust parameters and weights
the networks did not make the wrong association between the during training) and the loss function (used to measure network
orientation of the plants and the disease they intended to classify. performance) were kept consistent while training models to

Authorized licensed use limited to: VTU Consortium. Downloaded on July 01,2024 at 08:09:08 UTC from IEEE Xplore. Restrictions apply.
This article has been accepted for inclusion in a future issue of this journal. Content is final as presented, with the exception of pagination.

WU et al.: STRAWBERRY DISEASE DETECTION THROUGH AN ADVANCED SQUEEZE-AND-EXCITATION DEEP LEARNING MODEL 7

TABLE II
PERFORMANCE OF (PRETRAINED) DEEP MODELS AFTER FINE-TUNING THE
PARAMETERS

Fig. 6. Trend of loss functions for the proposed model with different datasets.
(a) ResNet9. (b) ResNet9-SE.

The obtained results shown above, imply that ResNet models


achieve the best performance among the others. Hence, we con-
sidered ResNet as our base architecture to propose our novel ap-
proach by adding the SE layers along with our variable learning
rate. The aim has been to reduce the model size and also preserve
the accuracy so that it can be suitable for deployment on the edge.
To measure the performance of our proposed models, here also
we have used cross-validation and considered 80% of data for
training and 20% for testing. We used batch size 32 and ran the
Fig. 5. Loss function (a) and accuracy (b) performance for pretrained models. model for 50 epochs, respectively. In this experiment, we trained
our models on both PlantVillage and Wilkin & Sons datasets.
The training loss behavior for both models, i.e., ResNet9 and
ResNet9-SE, is illustrated in Fig. 6. It can be observed from
obtain the fairest comparison possible. The loss function used this figure that both models achieve a decreasing trend in loss
was cross-entropy loss which provided a robust measurement value, but the proposed ResNet9-SE shows a faster reduction
of the network performance by measuring the difference in with both datasets [see Fig. 6(b)]. This observation, confirms
probability distributions of the model’s predicted output with the effectiveness of adding two new SE blocks to the network
the correct expected output. This means that it not only mea- architecture.
sures if the model has made the correct prediction but also It is also worthwhile to mention that instead of using a fixed
accounts for how confident the model was in the prediction it learning rate, we used a variable learning rate, which changes
made. after each batch of training. We start with a low learning rate
We varied key parameters, including the learning rate and and gradually increase it to a high learning rate in batches over
the batch size, to find the best performance. The batch size was about 30% of the cycles. We then gradually reduce it to a very
kept as large as possible (while being a multiple of 2) and was low value over the remaining cycles, so only the maximum
restricted by two factors. Also, different learning rates were used learning rate needs to be set when setting the parameters. The
for each architecture. These were linearly spaced between 0.001 key advantages of this strategy are twofold: initially, gradually
and 0.1. The aim was to train all models up to 500 epochs; lowering the learning rate speeds up model convergence by
however, some models had their training ended early to minimize quickly updating parameters early on and then approaching
time spent on suboptimal training models. The obtained results the optimal value as training progresses. Second, this variable
are given in Table II. Also, the performance of different models learning rate approach prevents the model from getting stuck in
in terms of loss and accuracy per epoch is given in Fig. 5. local optima. Adjusting the rate during later stages aids in finding

Authorized licensed use limited to: VTU Consortium. Downloaded on July 01,2024 at 08:09:08 UTC from IEEE Xplore. Restrictions apply.
This article has been accepted for inclusion in a future issue of this journal. Content is final as presented, with the exception of pagination.

8 IEEE TRANSACTIONS ON AGRIFOOD ELECTRONICS, VOL. 00, NO. 0, 2024

TABLE III improve performance. The obtained experimental results show


PERFORMANCE EVALUATION AND MODEL COMPLEXITY OF DIFFERENT
MODELS
that the proposed model can achieve very high classification
accuracy with less computation costs, which shows the effec-
tiveness of deployment on embedded systems. We further aim
to expand the number of data collection nodes throughout the
farm, enriching the dataset and developing a fusion model to
analyze both sensors’ data and image data simultaneously to
provide an early and accurate prediction of potential diseases.
The ultimate aim is to optimize the proposed model and deploy it
the global optimal solution while enhancing model stability to
as a fully operational real-time on-field disease diagnosis system
adapt to changing data distributions, reducing oscillation and
in strawberry farms.
instability during training. Through following this procedure in
our experiments, we found and set the learning rates of 0.04 and
0.01 for ResNet models with the PlantVillage, and Wilkin & REFERENCES
Sons datasets, respectively.
[1] I. Navrozidis, T. Alexandridis, A. Dimitrakos, A. Lagopodi, D. Moshou,
The final part of the results is devoted to the analysis of and G. Zalidis, “Identification of purple spot disease on asparagus crops
numerical performance and model complexities using the met- across spatial and spectral scales,” Comput. Electron. Agriculture, vol. 148,
rics provided at the beginning of this section. In Table III, the pp. 322–329, 2018.
[2] N. ElBeheiry and R. S. Balog, “Technologies driving the shift to smart
total number of parameters, the total size of the model, and farming: A review,” IEEE Sensors J., vol. 23, no. 3, pp. 1752–1769,
the performance metrics are provided. As can be seen from Feb. 2023.
this table, the proposed ResNet9-SE requires a slightly smaller [3] R. Rayhana, Z. Ma, Z. Liu, G. Xiao, Y. Ruan, and J. S. Sangha, “A review
on plant disease detection using hyperspectral imaging,” IEEE Trans.
number of parameters and occupies less memory while still AgriFood Electron., vol. 1, no. 2, pp. 108–134, Dec. 2023.
achieving a high accuracy. When the SE module was added [4] U. Dar, M. H. Anisi, V. Abolghasemi, C. Newenham, and A. Ivanov,
to the ResNet9 model, the number of parameters and memory “Visual sensor network based early onset disease detection for strawberry
plants,” in Proc. IEEE Appl. Sens. Conf., 2023, pp. 1–3.
footprint were slightly reduced while maintaining high accuracy. [5] J. Wu, U. Dar, M. H. Anisi, V. Abolghasemi, C. N. Wilkin, and A. I.
This is because the introduction of the SE module enhances the Wilkin, “Plant disease detection: Electronic system design empowered
ability of the neural network to model features and improves with artificial intelligence,” in Proc. IEEE Conf. AgriFood Electron., 2023,
pp. 30–34.
the efficiency of parameter usage. First, the parameters in the [6] J. Shin, Y. K. Chang, B. Heung, T. Nguyen-Quang, G. W. Price, and A.
SE module are globally shared, which means that the number Al-Mallahi, “A deep learning approach for RGB image-based powdery
of parameters in the SE module is fixed regardless of the size of mildew disease detection on strawberry leaves,” Comput. Electron. Agri-
culture, vol. 183, 2021, Art. no. 106042.
the input image. Second, the SE module introduces a channel [7] Q. Jiang et al., “Hyperspectral imaging for early identification of straw-
attention mechanism that allows the network to adaptively learn berry leaves diseases with machine learning and spectral fingerprint fea-
the importance of each channel and weight the feature map. tures,” Infrared Phys. Technol., vol. 118, 2021, Art. no. 103898.
[8] I. Abbas, J. Liu, M. Amin, A. Tariq, and M. H. Tunio, “Strawberry fungal
This helps the network to pay more attention to the information leaf scorch disease identification in real-time strawberry field using deep
that is useful for the classification task, reducing unnecessary learning architectures,” Plants, vol. 10, no. 12, 2021, Art. no. 2643.
information transfer and computation, and thus reducing pa- [9] M. T. Islam and A. Tusher, Automatic Detection of Grape, Potato and
Strawberry Leaf Diseases Using CNN and Image Processing. Berlin,
rameter redundancy. In addition, the introduction of the SE Germany: Springer, Jan. 2021, pp. 213–224.
module enhances the feature modeling capability of the network, [10] M. M. Hasan, J. P. Chopin, H. Laga, and S. J. Miklavcic, “Detection
thus, further reducing the number of parameters and memory and analysis of wheat spikes using convolutional neural networks,” Plant
Methods, vol. 14, 2018, Art. no. 100.
footprint. Finally, the SE module also has a regularization effect, [11] Y. Toda and F. Okura, “How convolutional neural networks diagnose plant
which helps reduce the risk of overfitting and makes the model disease,” Plant Phenomics, vol. 2019, pp. 1–14, 2019.
more generalizable. Taken together, the addition of the SE mod- [12] S. Zhang, S. Zhang, C. Zhang, X. Wang, and Y. Shi, “Cucumber leaf disease
identification with global pooling dilated convolutional neural network,”
ule not only improves the representation ability and classification Comput. Electron. Agriculture, vol. 162, pp. 422–430, 2019.
accuracy of the network but also effectively reduces the number [13] S. S. Hari, M. Sivakumar, P. Renuga, S. Karthikeyan, and S. Suriya,
of parameters and memory occupation, making the network “Detection of plant disease by leaf image using convolutional neural
network,” in Proc. Int. Conf. Vis. Towards Emerg. Trends Commun. Netw.,
more lightweight and efficient. 2019, pp. 1–5.
[14] A. Picon, M. Seitz, A. Alvarez-Gila, P. Mohnke, A. Ortiz-Barredo, and J.
Echazarra, “Crop conditional convolutional neural networks for massive
V. CONCLUSION multi-crop plant disease classification over cell phone acquired images
In this article, a novel deep learning-based architecture was taken on real field conditions,” Comput. Electron. Agriculture, vol. 167,
2019, Art. no. 105093.
proposed for the application of strawberry plant disease detec- [15] M. R. Howlader, U. Habiba, R. H. Faisal, and M. M. Rahman, “Automatic
tion. We designed and implemented a fully embedded electronic recognition of guava leaf diseases using deep convolution neural network,”
system including sensors’ data capturing as well as RGB camera in Proc. Int. Conf. Elect. Comput. Commun. Eng., 2019, pp. 1–5.
[16] K. Nagasubramanian, S. Jones, A. K. Singh, S. Sarkar, A. Singh, and
image acquisition from strawberry plants. The images were then B. Ganapathysubramanian, “Plant disease identification using explainable
sent to the cloud through a gateway for analysis. A new modified 3D deep learning on hyperspectral images,” Plant Methods, vol. 15, 2019,
ResNet model, called ResNet9-SE, was proposed and applied to Art. no. 98.
[17] A. Pal and V. Kumar, “AgriDet: Plant leaf disease severity classification
a set of collected data as well as a publicly available dataset. The using agriculture detection framework,” Eng. Appl. Artif. Intell., vol. 119,
new model benefits from two SE blocks within the network to 2023, Art. no. 105754.

Authorized licensed use limited to: VTU Consortium. Downloaded on July 01,2024 at 08:09:08 UTC from IEEE Xplore. Restrictions apply.
This article has been accepted for inclusion in a future issue of this journal. Content is final as presented, with the exception of pagination.

WU et al.: STRAWBERRY DISEASE DETECTION THROUGH AN ADVANCED SQUEEZE-AND-EXCITATION DEEP LEARNING MODEL 9

[18] A. Mathew, A. Antony, Y. Mahadeshwar, T. Khan, and A. Kulka- [24] J.-F. Yeh, K.-M. Lin, C.-Y. Lin, and J.-C. Kang, “Intelligent mango
rni, “Plant disease detection using GLCM feature extractor and voting fruit grade classification using AlexNet-SPP with mask R-CNN-based
classification approach,” Materials Today: Proc., vol. 58, pp. 407–415, segmentation algorithm,” IEEE Trans. AgriFood Electron., vol. 1, no. 1,
2022. pp. 41–49, Jun. 2023.
[19] P. Bedi and P. Gole, “Plant disease detection using hybrid model based [25] S.-H. Kim, M. Hun Lee, and C. Shin, “IoT-based strawberry disease pre-
on convolutional autoencoder and convolutional neural network,” Artif. diction system for smart farming,” Sensors (Basel, Switzerland), vol. 18,
Intell. Agriculture, vol. 5, pp. 90–101, 2021. 2018, Art. no. 4051.
[20] A. Abdalla et al., “Fine-tuning convolutional neural network with transfer [26] G. Sahitya, C. Kaushik, P. S. Simha, D. Reddy, S. Kumar, and V. Vinay,
learning for semantic segmentation of ground-level oilseed rape images in “Leaf disease detection using Raspberry Pi,” in Proc. 13th Int. Conf.
a field with high weed pressure,” Comput. Electron. Agriculture, vol. 167, Comput. Commun. Netw. Technol., 2022, pp. 1–7.
2019, Art. no. 105091. [27] E. A. H. Mora, V. A. G. Huitrón, A. E. R. Mata, and H. R. Rangel,
[21] K. Lin, L. Gong, Y. Huang, C. Liu, and J. Pan, “Deep learning-based seg- “Plant disease detection with convolutional neural networks implemented
mentation and quantification of cucumber powdery mildew using convo- on Raspberry Pi 4,” in Proc. IEEE Int. Autumn Meeting Power Electron.
lutional neural network,” Front. Plant Sci., vol. 10, 2019, Art. no. 422622. Comput., 2020, pp. 1–23.
[22] T. Wiesner-Hanks et al., “Millimeter-level plant disease detection from [28] C.-H. Huang, B.-W. Chen, Y.-J. Lin, and J.-X. Zheng, “Smart crop growth
aerial photographs via deep learning and crowdsourced data,” Front. Plant monitoring based on system adaptivity and edge AI,” IEEE Access, vol. 10,
Sci., vol. 10, 2019, Art. no. 1550. pp. 64114–64125, 2022.
[23] Y. Li, J. Wang, H. Wu, Y. Yu, H. Sun, and H. Zhang, “Detection of powdery [29] K. He, X. Zhang, S. Ren, and J. Sun, “Deep residual learning for image
mildew on strawberry leaves based on DAC-YOLOv4 model,” Comput. recognition,” in Proc. IEEE Conf. Comput. Vis. Pattern Recognit., 2016,
Electron. Agriculture, vol. 202, 2022, Art. no. 107418. pp. 770–778.

Authorized licensed use limited to: VTU Consortium. Downloaded on July 01,2024 at 08:09:08 UTC from IEEE Xplore. Restrictions apply.

You might also like