Project Overview
Plant pathology diagnosis in agricultural fields requires accurate, low-latency visual classification to prevent crop loss. This project implements a transfer learning pipeline utilizing VGG16 pretrained on ImageNet and fine-tuned on a 29,000+ image dataset covering 10 distinct tomato leaf diseases alongside healthy controls.
The pipeline incorporates automated data augmentation (rotation, zoom, horizontal flip) to overcome field lighting variances and evaluated multiple candidate backbones including DenseNet121, InceptionV3, Xception, and MobileNetV2. VGG16 delivered the highest precision-recall balance, achieving a 96.6% validation accuracy score.
Architectural Highlights
- Custom input preprocessing pipeline with normalized image tensor resizing and data augmentation.
- VGG16 convolutional feature extractor with frozen base layers and fine-tuned top dense classification heads.
- Categorical cross-entropy loss optimization with Adam optimizer and ReduceLROnPlateau scheduling.
- Confusion matrix and precision-recall scoring to analyze inter-class confusion among leaf spots.
Key Capabilities
- Classifies 11 conditions: Bacterial Spot, Early Blight, Late Blight, Leaf Mold, Septoria, Spider Mites, Target Spot, Yellow Leaf Curl, Mosaic Virus, and Healthy
- Automated evaluation scripts generating precision, recall, and F1-score reports
- Exportable lightweight model artifacts for edge and mobile deployment
Quick Setup & Installation
git clone https://github.com/KamalSDhami/Tomato-Leaf-Disease-Detection.git && pip install -r requirements.txtTechnologies Used
Python 3.10TensorFlowKerasScikit-learnNumPyMatplotlib