Benchmarking YOLO Object Detectors for Blackgram Weed Detection: Accuracy, Generalization, and Deployment Trade-offs
Abstract
In blackgram (Vigna mungo (L.) Hepper) cultivation, weeds compete with the crop for nutrients, water, light, and space, reducing yield by up to 68.1% and increasing reliance on manual or chemical weed control. Manual weeding is labour-intensive, time-consuming, and increasingly impractical; hence, automated weed detection is needed to enable site-specific weed management in blackgram fields. One-stage detectors such as YOLO have emerged as leading paradigm for real-time agricultural detection; thus, a systematic benchmark of YOLO variants is needed for blackgram weed detection. This study presents a benchmark of 18 YOLO configurations (YOLOv5 to YOLO26) on a custom weed dataset collected from multiple blackgram fields. On the validation set, YOLOv9s achieved the best performance with the highest mAP@50 (0.9147) and mAP@50-95 (0.7875), followed closely by YOLOv8s and YOLOv7. Broadleaf weeds were detected more accurately than narrowleaf weeds, and narrowleaf detection was more difficult on the validation dataset. In the independent cross-field test, YOLO11s achieved the highest mAP@50-95 (0.5705), while YOLOv7 achieved the highest mAP@50 (0.7510), indicating that validation accuracy did not fully predict field generalization. In further analysis of metrics ratio with GFLOPs, YOLO26n had the best performance-per-GFLOP ratio, while YOLO11n and YOLOv9t offered strong compact-model options. Thus, YOLOv9s and YOLOv8s were better for accuracy-focused detection, whereas YOLO11n, YOLOv9t, and YOLO26n were more suitable for constrained edge-oriented blackgram weed detection. Model selection for further field evaluation requires a balance between accuracy, generalization, and computational efficiency, and this benchmark supports the preliminary selection of models for further testing.