| Literature DB >> 36217500 |
Laura Falaschetti1, Lorenzo Manoni1, Denis Di Leo1, Danilo Pau2, Valeria Tomaselli3, Claudio Turchetti1.
Abstract
Identifying diseases from images of plant leaves is one of the most important research areas in precision agriculture. The aim of this paper is to propose an image detector embedding a resource constrained convolutional neural network (CNN) implemented in a low cost, low power platform, named OpenMV Cam H7 Plus, to perform a real-time classification of plant disease. The CNN network so obtained has been trained on two specific datasets for plant diseases detection, the ESCA-dataset and the PlantVillage-augmented dataset, and implemented in a low-power, low-cost Python programmable machine vision camera for real-time image acquisition and classification, equipped with a LCD display showing to the user the classification response in real-time. Experimental results show that this CNN-based image detector can be effectively implemented on the chosen constrained-resource system, achieving an accuracy of about 98.10%/95.24% with a very low memory cost (718.961 KB/735.727 KB) and inference time (122.969 ms/125.630 ms) tested on board for the ESCA and the PlantVillage-augmented datasets respectively, allowing the design of a portable embedded system for plant leaf diseases classification. Source files are available at https://doi.org/10.17605/OSF.IO/UCM8D.Entities:
Keywords: Esca disease; Image detector; convolutional neural network; embedded systems; plant diseases recognition
Year: 2022 PMID: 36217500 PMCID: PMC9547307 DOI: 10.1016/j.ohx.2022.e00363
Source DB: PubMed Journal: HardwareX ISSN: 2468-0672
Summary of the state-of-the-art CNNs for plant diseases detection.
| Mohanty et al. | AlexNet | PlantVillage | 38 | 99.27%, 99.34% | AlexNet: 60 million GoogleNet: 5 million | – |
| Ramcharan et al. | Inception V3 | Cassava dataset | 6 | 93% | Inception V3: 27 million | – |
| Fuentes et al. | Faster R-CNN | custom Tomato Diseases and Pests Dataset 5000 images | 9 | 83% | Faster R-CNN with VGG: 2.4 million | – |
| Pawara et al. | AlexNet | AgriPlant Dataset | 10 | 96.37%, 98.33% | AlexNet: 60 millionGoogleNet: 5 million | – |
| LeafSnap Dataset | 184 | 89.51%, 97.66% | ||||
| Folio Dataset | 32 | 97.67%, 97.63% | ||||
| Ferentinos et al. | AlexNetOWTBn | custom dataset 87848 images | 58 | 99.49%, 99.53% | AlexNetOWTBn: 60 million VGG: 138 million | – |
| Ramacharan el al. | MobileNet | Cassava dataset | 6 | 80.6% on images 70.4% on video | MobileNet-SSD: 6 million | ✓Samsung Galaxy S5 Android device |
| Geetharamani et al. | CNN | PlantVillage with data augmentation | 39 | 96.46% | 212,543 | – |
| Chen et al. | VGG-19 pre-trained on ImageNet with Inception module | Maize PlantVillage | 4 | 92% | VGG-19: 143 million | – |
| Chen et al. | DenseNet | Maize PlantVillage | 4 | 98.50% | 33.97 million | – |
| Chen et al. | MobileNet-V2 | PlantVillage | 38 | 99.71% | 3.83 million | – |
| Chen et al. | DenseNet | custom dataset 1000 images | 5 | 97.60% | 3.40 million | – |
| Li et al. | CNN | NBAIR | 50 | 95.4% | 0.75 million | ✓FPGA |
| Li et al. dataset | 10 | 96.2% | ||||
| Chen et al. | MobileNet-V2 | Li et al. dataset | 10 | 99.14% | 3.83 million | – |
| Chen et al. | Semantic Segmentation and CNN | Grape PlantVillage | 4 | 93.75% | 44.51 million | – |
| Mishra et al. | CNN | PlantVillage | 3 | 88.46% | 22.75 million | ✓ Intel Movidius NCS with Raspberry Pi 3 |
| Gajjar et al. | SSD | PlantVillage | 20 | 96.88% | 6.07 million | ✓ NVIDIA Jetson TX1 |
Fig. 1OpenMV Cam with LCD display (a) used connected to a PC provided with OpenMV IDE that shows on the serial terminal the classification response applied to different leaves (CNN trained on PlantVillage-augmented dataset), (b) used in stand-alone mode powered by a power bank.
Fig. 2OpenMV Cam with LCD display that shows the classification response applied to Esca disease (CNN trained on ESCA-dataset). (a) Healthy leaf (no tag), (b) Leaf affected by Esca disease correctly detected as shown in the LCD display (tag ‘E’).
Consistency of the Esca dataset partition considered for training, validation and testing.
| esca | 5328 | 1332 | 2220 | 8880 |
| healthy | 5292 | 1323 | 2205 | 8820 |
| Total | 10620 | 2655 | 4425 | 17700 |
Consistency of the PlantVillage-augmented dataset partition considered for training, validation and testing.
| Apple_scab | 600 | 150 | 250 | 1000 |
| Apple_black_rot | 600 | 150 | 250 | 1000 |
| Apple_cedar_apple_rust | 600 | 150 | 250 | 1000 |
| Apple_healthy | 987 | 246 | 412 | 1645 |
| Background_without_leaves | 685 | 171 | 287 | 1143 |
| Blueberry_healthy | 901 | 225 | 376 | 1502 |
| Cherry_powdery_mildew | 631 | 157 | 264 | 1052 |
| Cherry_healthy | 600 | 150 | 250 | 1000 |
| Corn_gray_leaf_spot | 600 | 150 | 250 | 1000 |
| Corn_common_rust | 715 | 178 | 299 | 1192 |
| Corn_northern_leaf_blight | 600 | 150 | 250 | 1000 |
| Corn_healthy | 697 | 174 | 291 | 1162 |
| Grape_black_rot | 708 | 177 | 295 | 1180 |
| Grape_black_measles | 829 | 207 | 347 | 1383 |
| Grape_leaf_blight | 645 | 161 | 270 | 1076 |
| Grape_healthy | 600 | 150 | 250 | 1000 |
| Orange_haunglongbing | 3304 | 826 | 1377 | 5507 |
| Peach_bacterial_spot | 1378 | 344 | 575 | 2297 |
| Peach_healthy | 600 | 150 | 250 | 1000 |
| Pepper_bacterial_spot | 600 | 150 | 250 | 1000 |
| Pepper_healthy | 886 | 221 | 371 | 1478 |
| Potato_early_blight | 600 | 150 | 250 | 1000 |
| Potato_late_blight | 600 | 150 | 250 | 1000 |
| Potato_healthy | 600 | 150 | 250 | 1000 |
| Raspberry_healthy | 600 | 150 | 250 | 1000 |
| Soybean_healthy | 3054 | 763 | 1273 | 5090 |
| Squash_powdery_mildew | 1101 | 275 | 459 | 1835 |
| Strawberry_leaf_scorch | 665 | 166 | 250 | 1081 |
| Strawberry_healthy | 600 | 150 | 278 | 1028 |
| Tomato_bacterial_spot | 1276 | 319 | 532 | 2127 |
| Tomato_early_blight | 600 | 150 | 250 | 1000 |
| Tomato_late_blight | 1145 | 286 | 250 | 1681 |
| Tomato_leaf_mold | 600 | 150 | 444 | 1194 |
| Tomato_septoria_leaf_spot | 1062 | 265 | 420 | 1747 |
| Tomato_spider_mites_two-spotted_spider_mite | 1005 | 251 | 352 | 1608 |
| Tomato_target_spot | 842 | 210 | 1340 | 2392 |
| Tomato_yellow_leaf_curl_virus | 3214 | 803 | 399 | 4416 |
| Tomato_mosaic_virus | 600 | 150 | 250 | 1000 |
| Tomato_healthy | 954 | 238 | 478 | 1670 |
| Total | 36884 | 9213 | 15389 | 61486 |
Fig. 3Design TensorFlow of CNN architecture.
CNN architecture in detail.
| conv_1 | |||
| relu_1 | – | ||
| maxpool_1 ( | – | ||
| conv_2 | |||
| relu_2 | – | ||
| maxpool_2 ( | - | ||
| conv_3 | |||
| relu_3 | – | ||
| maxpool_3 ( | – | ||
| flatten | – | ||
| dense_1 | |||
| relu_4 | – | ||
| dropout (0.5) | – | ||
| dense_2 | |||
| softmax | – |
* Different number of parameters for the architecture applied to ESCA and PlantVillage-augmented dataset, since the dense layer depends on the number of classes (2 and 39 classes respectively).
Compression factors for the pruned models.
| conv_1 | 0.35 | 0.35 |
| conv_2 | 0.5 | 0.5 |
| conv_3 | 0.5 | 0.5 |
| dense_1 | 0.9 | 0.9 |
Details for the finetuning of the pruned models.
| pruning method | ||
| optimizer | Adadelta | Adadelta |
| learning rate | 1.0 | 1.0 |
| epochs | 20 | 25 |
Pruned CNN architecture.
| conv_1 | |||
| relu_1 | – | ||
| maxpool_1 ( | – | ||
| conv_2 | |||
| relu_2 | – | ||
| maxpool_2 ( | – | ||
| conv_3 | |||
| relu_3 | – | ||
| maxpool_3 ( | – | ||
| flatten | – | ||
| dense_1 | |||
| relu_4 | – | ||
| dropout (0.5) | – | ||
| dense_2 | |||
| softmax | – |
* Different number of parameters for the architecture applied to ESCA and PlantVillage-augmented dataset, since the dense layer depends on the number of classes (2 and 39 classes respectively).
Model performance on PC — ESCA-dataset.
| CNN | h5 | 128 × 128 | 19164.75 | 97.88 | 53.22 |
| tflite | 128 × 128 | 1602.555 | 97.90 | 75.45 | |
| Pruned CNN | h5 | 128 × 128 | 5739.289 | 97.79 | 51.95 |
| tflite | 128 × 128 | 718.961 | 97.69 | 19.94 |
Model performance on PC — PlantVillage-augmented dataset.
| CNN | h5 | 128 × 128 | 19386.688 | 96.52 | 52.93 |
| tflite | 128 × 128 | 1621.195 | 96.50 | 78.67 | |
| Pruned CNN | h5 | 128 × 128 | 8786.457 | 95.87 | 44.44 |
| tflite | 128 × 128 | 735.727 | 95.72 | 22.70 |
Details of the model analyzed with X-CUBE-AI — ESCA-dataset.
| CNN | h5 | 1630754 | 21081040 | 6523016 | 334088 |
| tflite | 1630754 | 20749400 | 1632632 | 88515 | |
| Pruned CNN | h5 | 728178 | 5338585 | 2912712 | 242000 |
| tflite | 728178 | 5221717 | 729724 | 62315 |
Details of the model analyzed with X-CUBE-AI — PlantVillage-augmented dataset.
| CNN | h5 | 1649735 | 21100576 | 6598940 | 334236 |
| tflite | 1649735 | 20769084 | 1651724 | 88552 | |
| Pruned CNN | h5 | 745235 | 5356197 | 2980940 | 242148 |
| tflite | 745235 | 5239477 | 746892 | 62352 |
Model performance on OpemMV Cam H7 Plus — ESCA-dataset.
| CNN | tflite | 128 × 128 | 98.40 | 276.404 | 3.61 |
| Pruned CNN | 128 × 128 | 98.10 | 122.969 | 8.13 |
Model performance on OpemMV Cam H7 Plus — PlantVillage-augmented dataset.
| CNN | tflite | 128 × 128 | 283.30 | 3.52 | |
| Pruned CNN | 128 × 128 | 95.24 | |||
| Geetharamani et al. | tflite | 128 × 128 | 94.34 | 270.61 | 3.69 |
| Hardware name | |
| Wio Lite AI Single Board: | |
| MIT License | |
| $136.47 | |
| https://doi.org/10.17605/OSF.IO/UCM8D | |
| CNN_Esca.ipynb | Google Colaboratory Notebook file | MIT License | OSF Repository |
| CNN_Esca_pruned.ipynb | Google Colaboratory Notebook file | MIT License | OSF Repository |
| CNN_PV.ipynb | Google Colaboratory Notebook file | MIT License | OSF Repository |
| CNN_PV_pruned.ipynb | Google Colaboratory Notebook file | MIT License | OSF Repository |
| CNN_Esca_model.h5 | model file | MIT License | OSF Repository |
| CNN_Esca_model.tflite | model file | MIT License | OSF Repository |
| CNN_Esca_pruned_model.h5 | model file | MIT License | OSF Repository |
| CNN_Esca_pruned_model.tflite | model file | MIT License | OSF Repository |
| CNN_PV_model.h5 | model file | MIT License | OSF Repository |
| CNN_PV_model.tflite | model file | MIT License | OSF Repository |
| CNN_PV_pruned_model.h5 | model file | MIT License | OSF Repository |
| CNN_PV_pruned_model.tflite | model file | MIT License | OSF Repository |
| conversion_DatasetEsca_into_bmp_format.ipynb | Google Colaboratory Notebook file | MIT License | OSF Repository |
| conversion_DatasetPV_into_bmp_format.ipynb | Google Colaboratory Notebook file | MIT License | OSF Repository |
| augmented_esca_dataset_9transformation_splitted.zip | data file | MIT License | OSF Repository |
| Dataset_Esca_Test_bmp_128x128.zip | data file | MIT License | OSF Repository |
| Dataset_PV_Test_bmp_128x128.zip | data file | MIT License | OSF Repository |
| openmv_demoEsca_SD_testingSet.py | micropython file | MIT License | OSF Repository |
| openmv_demoEsca_SD_realtime.py | micropython file | MIT License | OSF Repository |
| openmv_demoEsca_SD_realtime_responseOnLCD.py | micropython file | MIT License | OSF Repository |
| openmv_demoPV_SD_testingSet.py | micropython file | MIT License | OSF Repository |
| openmv_demoPV_SD_realtime.py | micropython file | MIT License | OSF Repository |
| demo_Esca-1.mp4 | media file | MIT License | OSF Repository |
| demo_Esca-2.avi | media file | MIT License | OSF Repository |
| demo_PV.mp4 | media file | MIT License | OSF Repository |
| OpenMV Cam H7 Plus | OC1 | 1 | 80.00 | 80.00 | |
| OpenMV LCD Shield | LCD1 | 1 | 20.00 | 20.00 | |
| Micro SD Card | SD1 | 1 | 8.69 | 8.69 | |
| micro USB cable | USB1 | 1 | 7.79 | 7.79 | |
| power bank | PW1 | 1 | 19.99 | 19.99 | |