πŸ₯¦ Cauliflower Disease Detection β€” YOLOv8 Model

πŸ“Œ Overview

This repository hosts a trained YOLOv8 object detection model for identifying cauliflower leaf diseases and stress conditions from images.

The model was trained on a curated, multi-class agricultural dataset and is suitable for:

  • Automated crop disease detection
  • Smart agriculture & decision support systems
  • Mobile and edge inference
  • Research in plant pathology & computer vision

The model detects five distinct disease categories from field images and outputs bounding boxes and class labels.


🧠 Model Summary

Attribute Value
Task Object Detection
Architecture YOLOv8-Small
Framework PyTorch (Ultralytics YOLOv8)
Input Size 640 Γ— 640
Classes 5
Training Epochs 200
Precision FP32
Export Format TorchScript

🏷️ Supported Classes

Class ID Disease / Condition
0 alternaria_leaf_spot
1 black_rot
2 downey_mildew
3 insect_infested
4 nutrient_deficiency

βš™οΈ Training Configuration

The model was trained using Ultralytics YOLOv8. The exact training arguments used are listed below:

# Key Training Parameters
task: detect
model: yolov8s.pt
data: cauli_disease-3/data.yaml

# Training Setup
epochs: 200
batch: 32
imgsz: 640
optimizer: auto
pretrained: true
amp: true
seed: 0
deterministic: true

# Optimization
lr0: 0.01
momentum: 0.937
weight_decay: 0.0005
warmup_epochs: 3.0

# Validation & Inference
iou: 0.7
max_det: 300
split: val

# Augmentation
mosaic: 1.0
fliplr: 0.5
auto_augment: randaugment

# Tracking & Output
tracker: botsort.yaml
save_dir: runs/detect/train2

Training outputs and intermediate artifacts were saved under runs/detect/train2/.


πŸ“Š Dataset

  • Dataset: Cauliflower Disease Detection Dataset
  • Annotation Format: YOLO
  • Classes: 5 (see Supported Classes)
  • License: CC BY 4.0

The dataset contains real-field cauliflower leaf images annotated with bounding boxes for disease localization. The dataset used during training is referenced in data above (cauli_disease-3/data.yaml).


πŸš€ Inference Usage

Using Ultralytics CLI

yolo detect predict \
  model=weights/best.pt \
  source=your_image.jpg \
  imgsz=640

Python Inference Example

from ultralytics import YOLO

model = YOLO("weights/best.pt")
results = model("image.jpg", conf=0.25)

# Display or save results
results[0].show()
results[0].save(save_dir='inference_results')

Notes:

  • Set conf (confidence) threshold to trade off precision vs. recall.
  • For batch or directory inference, pass a folder path to source.

πŸ“¦ Repository Contents (suggested)

.
β”œβ”€β”€ best.pt                # Best trained weights (model for inference)
β”œβ”€β”€ last.pt                # Final checkpoint from training
β”œβ”€β”€ args.yaml              # Training configuration 
β”œβ”€β”€ results.png            # Training curves / metrics plot
β”œβ”€β”€ README.md              # This documentation file

πŸ“ˆ Performance Notes

  • Trained with data augmentation options enabled during training.
  • Early stopping monitored with patience = 100.
  • IoU threshold set to 0.7 during validation.

Exact evaluation metrics (mAP@0.5, precision, recall) should be calculated on a held-out test set and can be added to this README once available.


🌍 Deployment Use Cases

  • Smart farming dashboards
  • Mobile crop monitoring applications
  • Drone-based field inspection
  • Agricultural advisory systems
  • Edge AI inference pipelines (ONNX / TensorRT conversions possible)

πŸ“œ License

This model and its training outputs are released under the MIT license. Attribution is required for use in publications or products.


πŸ“– Citation

If you use this model in academic or applied work, please cite the model and dataset:

@model{cauliflower_yolov8_detector,
  title={YOLO based Cauliflower Disease Detection Model},
  author={Indra Prasad Sapkota},
  year={2025},
  url={https://huggingface.co/Bishal17/plant_care}
}

🀝 Acknowledgements

  • Model trained using Ultralytics YOLOv8.
  • Dataset annotation and preprocessing assisted by Roboflow or similar annotation tools.
  • Model hosting by Hugging Face (recommended).

πŸ“¬ Contact & Contributions

Contributions are welcome (issues / PRs). Possible contributions:

  • Performance benchmarks and evaluation reports
  • Edge optimization (quantized, ONNX, TensorRT)
  • Additional datasets and annotated examples

For contributions or questions, open an issue on the repository or contact the maintainer listed on the Hugging Face project page.

Downloads last month

-

Downloads are not tracked for this model. How to track
Inference Providers NEW
This model isn't deployed by any Inference Provider. πŸ™‹ Ask for provider support

Dataset used to train indra17/plant_care