2023-DnB-Project/train.py
2023-06-29 23:49:53 +08:00

8 lines
256 B
Python

from ultralytics import YOLO
# Load a model
model = YOLO('../../project/runs/detect/train3/weights/best.pt') # load a pretrained model (recommended for training)
# Train the model
model.train(data='../datasets/zcxv.v2i.yolov8/data.yaml', device="cuda")