From 1f5f399137380c56cf579ca69c4ca53022d827e5 Mon Sep 17 00:00:00 2001 From: Fyrebolt700 Date: Wed, 29 Jul 2026 17:10:54 -0400 Subject: [PATCH] Added initial YOLOv11 training script --- .../yolo_object_detection_training.py | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 autonomy/perception/perception/yolo_object_detection_training.py diff --git a/autonomy/perception/perception/yolo_object_detection_training.py b/autonomy/perception/perception/yolo_object_detection_training.py new file mode 100644 index 00000000..a311d779 --- /dev/null +++ b/autonomy/perception/perception/yolo_object_detection_training.py @@ -0,0 +1,24 @@ +#Trains a YOLO11n model for badminton shuttlecock detection. + +from ultralytics import YOLO + + +def main() -> None: + model = YOLO("yolo11n.pt") + + model.train( + # Need to update path after dataset is added + data="path/to/badminton.yaml", + epochs=75, + imgsz=960, + batch=8, + device=0, + project="runs/detect", + name="yolo11n_shuttlecock", + pretrained=True, + single_cls=True, + ) + + +if __name__ == "__main__": + main() \ No newline at end of file