PlantVillage Leaf Disease Classification
This repository hosts the Hugging Face release for the Atılım AI Club Plant AI Project.
The project focuses on plant disease classification from leaf images using the PlantVillage dataset, with two classification tracks:
- Binary classification: healthy vs. unhealthy
- Multiclass classification: per-disease category prediction
Project Context
This Hugging Face repository is the release companion to the main GitHub project:
GitHub project: atilimai/plant-ai-project
The broader project includes experiment planning, dataset notes, release documentation, notebook scaffolding, evaluation utilities, and model card drafting. This Hugging Face repository is intended specifically for publishing trained model artifacts and release-ready documentation.
Scope
In scope
- Binary classification of healthy vs. unhealthy leaves
- Multiclass disease category classification
- PyTorch-based transfer learning models
- Release-ready model packaging
- Usage documentation
- Model card documentation
Out of scope
- Redistribution of raw PlantVillage image files
- Claims of real-world field robustness
- Mobile or edge deployment optimization
- New dataset collection or annotation
Dataset
Dataset source: PlantVillage
Homepage: https://plantvillage.psu.edu/
Access source used in project planning: Hugging Face Datasets (
mohanty/PlantVillage)
Licensing note
According to the original PlantVillage paper, the dataset was released under Creative Commons Attribution-ShareAlike 3.0 Unported (CC BY-SA 3.0), with the additional clarification that algorithms trained on the data fall under the same license.
Important dataset note
This repository does not redistribute PlantVillage image files.
Only trained model weights, metadata, and documentation are provided here unless redistribution is later reviewed and explicitly approved by the project release process.
Attribution note
If you use this repository, please also attribute the original PlantVillage dataset and paper.
Classification Tracks
1. Binary Track — Healthy vs. Unhealthy
This framing relabels all images into:
Motivation: a simpler baseline suitable for quick screening and early triage-style use cases.
2. Multiclass Track — Disease Category
This framing preserves the original disease class labels, such as:
Tomato___Early_blight
Potato___Late_blight
Motivation: more informative predictions for disease-specific classification.
Data Leakage Warning — leaf_id Split Integrity
A critical constraint in this project is leaf-level split integrity.
PlantVillage may contain multiple images of the same physical leaf captured under different angles, crops, or lighting conditions. If train/validation/test splits are created at the image level, the same physical leaf may appear in multiple partitions, causing data leakage and artificially inflated metrics.
For this reason:
- all train/validation/test splits must be created at the leaf_id level
- all images belonging to the same physical leaf must remain in the same partition
- split logic must be enforced programmatically
- split manifests should be documented and versioned separately from raw image files
Controlled Background Limitation
PlantVillage images are captured under controlled laboratory conditions with relatively uniform backgrounds.
This matters because:
- a model may partially learn background cues instead of disease-relevant leaf features
- measured benchmark accuracy may be higher than true field performance
- performance reported from this dataset should be interpreted as controlled-condition performance
Real-World Generalization Warning
This project does not claim real-world robustness.
Models trained and evaluated only on PlantVillage may perform substantially worse on:
- field images
- natural backgrounds
- mobile phone images
- varied lighting and weather conditions
- different regions or growing seasons
Any deployment or real-world use claim would require separate external validation.
Repository Contents
This Hugging Face repository may contain:
- trained model checkpoints
- configuration files
- label mappings
- lightweight inference examples
- release documentation
- model card updates
Intended Use
This repository is intended for:
- academic experimentation
- benchmarking
- student project documentation
- reproducible model release
It is not intended for:
- direct agronomic decision-making
- commercial plant diagnosis pipelines
- unsupervised real-world deployment
Usage
Example usage will depend on the final released checkpoint format.
A minimal PyTorch inference example will be added alongside the released model weights.
Limitations
- Controlled-background dataset bias
- Potential domain shift outside PlantVillage
- Class imbalance concerns
- Binary and multiclass models should be evaluated separately
- Results are only as trustworthy as the enforced split policy
Attribution
This release is part of the Atılım AI Club Plant AI Project.
Please also refer to the main GitHub repository for:
- project planning
- dataset notes
- release checklist
- model card drafting
- implementation details
Citation
If you use this project or its released artifacts, please cite:
- Hughes, D. P. & Salathé, M. (2015). An open access repository of images on plant health to enable the development of mobile disease diagnostics
- the PlantVillage dataset
- the Atılım AI Club Plant AI Project repository
- this Hugging Face model repository