Plant Disease Detection System - Madda Walabu University
# 🌿 Plant Disease Detection System
**Madda Walabu University — College of Computing**
**Department of Computer Science**
**Course:** Artificial Intelligence Project
**Author:** Morketa Negash (Ugrr/51983/15)
**Instructor:** Shume. B
---
## 📋 Project Overview
An end-to-end AI system that detects plant diseases from leaf images using a
**Convolutional Neural Network (CNN)** trained on 16,000 images from the
PlantVillage dataset. The model is deployed via a **Streamlit** web interface
that provides instant diagnosis, confidence scores, and treatment recommendations.
**Supported Crops:** Apple · Corn · Potato · Tomato
**Total Disease Classes:** 21 (including healthy classes)
---
## 🗂️ Project Structure
```
Plant disease detection system/
│
├── app.py ← Main Streamlit web application
├── requirements.txt ← Python dependencies
├── setup.bat ← One-click setup script (Windows)
├── run_app.bat ← Launch the web app
├── run_training.bat ← Start model training
│
├── model/
│ ├── train_model.py ← CNN training script (Chapter 4.4)
│ ├── predictor.py ← Inference / prediction module
│ ├── disease_info.py ← Disease database + treatment advice
│ ├── plant_disease_cnn.h5 ← Saved model (created after training)
│ └── class_names.json ← Class index map (created after training)
│
├── utils/
│ ├── download_dataset.py ← Kaggle dataset downloader
│ ├── evaluate_model.py ← Metrics + confusion matrix (Table 4.1)
│ └── demo_mode.py ← Simulated predictions for UI testing
│
└── dataset/ ← PlantVillage images (you add this)
├── Apple___Apple_scab/
├── Apple___healthy/
├── Tomato___Late_blight/
└── ...
```
---
## 🚀 Quick Start (Windows)
### Step 1 — Install & Setup
Double-click **`setup.bat`** or run in CMD:
```cmd
setup.bat
```
This creates a virtual environment and installs all dependencies …