Apiarist Honey-Bee Detector (YOLOv8s)

A custom-trained YOLOv8s specialist detector for honeycomb frame inspection. Built as part of Apiarist, a fully-offline AI hive inspector for backyard beekeepers, made for the Build Small Hackathon.

Classes

Trained on the hendricks_ricky bee-project dataset (3,308 labeled images, including 892 queen-bee examples). Four classes:

  • Queen, queen bee (larger, elongated abdomen)
  • Worker, worker / forager bees (the majority class)
  • Drone, male / drone bees
  • Varroa, varroa destructor mites visible on bees or comb

Usage

from ultralytics import YOLO
from PIL import Image

model = YOLO("honey_bee_detector.pt")
results = model(Image.open("hive_frame.jpg"), conf=0.10, device="cpu")
for box in results[0].boxes:
    cls = model.names[int(box.cls.item())]
    conf = float(box.conf.item())
    print(f"{cls}: {conf:.0%}")

Recommended per-class confidence thresholds (tuned empirically on real frame photos):

PER_CLASS_CONF = {
    "Worker": 0.25,
    "Drone": 0.55, # higher, drones false-positive on fingers, shadows
    "Varroa": 0.30, # mites are small
    "Queen": 0.15, # lower, try harder to find her
}

Training

  • Base weights: yolov8s.pt
  • Epochs: 60
  • Image size: 640ร—640
  • Batch size: 32
  • Hardware: 1ร— NVIDIA T4 (Modal)
  • Cost: ~$0.40 of free hackathon credit

Limitations

The training set includes ~892 queen images, which is far more than the typical bee-detection dataset but still limited compared to the millions of bees in worker class. Queen detection precision is moderate, when the model labels a queen, verify visually. Use as a candidate flag, not as ground truth.

Varroa mite detection works on close-up frames where mites are visible on the dorsal side of bees or in cells, but will miss mites hidden under abdomens.

License

Apache 2.0. Trained on data released under CC BY 4.0 by the original dataset authors.

Citation

If you use this model, please credit:

  • This work: Apiarist (Build Small Hackathon entry, 2026)
  • Training data: hendricks_ricky/bee-project, Roboflow Universe
Downloads last month
98
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Space using maryammeda/apiarist-honey-bee-detector 1