Plant leaf disease identification

Contact us Fork on GitHub

Plant leaf disease identification is crucial for agriculture helping to prevent the spread of diseases, which can have a significant impact on crop yields and food security. Identifying the specific disease allows farmers to take appropriate measures to control or eradicate the disease, such as applying the correct pesticides only on targeted plants or implementing quarantine measures.


  • The STM32 model zoo provides everything you need to train and retrain models with your own data
  • The solution proposes a model trained on a public dataset providing very good accuracy while running on a STM32
  • The model can be easily deployed on the STM32H747 discovery kit with the STM32 model zoo Python scripts
  • The use case presented is based on a plant leaf dataset to identify diseases


Vision: Camera module bundle (reference: B-CAMS-OMV)


Dataset: Plant Village dataset of plant leaf (License CC0 1.0 Public Domain)
Data format:
39 different classes of plant leaf and background images
RGB color images 


Model: Fast-downsampling MobileNet 0.25 

Input size: 224x224x3

Memory footprint:
137 KB Flash for weights
152 KB RAM for activations

Float model: 99.82%
Quantized model: 99.62% 

Performance on STM32H747 (High-perf) @ 400 MHz 
Inference time: 63.2 ms
Frame rate: 16 fps

Confusion matrix