train.py 227 B

12345
  1. from ultralytics import YOLO
  2. if __name__ == "__main__":
  3. model = YOLO("yolov8n.pt") # 创建一个模型,加载预训练的算子(coco数据集,imagenet数据集,voc)
  4. model.train(data="dataset.yaml", epochs=100)