Files
zjsh_yolov11/ultralytics_yolo11-main/train_point_main.py
2025-09-01 14:14:18 +08:00

20 lines
503 B
Python
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

from ultralytics import YOLO
if __name__ == '__main__':
# ✅ 使用官方支持的关键点模型YOLOv11
model = YOLO(r'ultralytics/cfg/models/11/yolo11-pose.yaml') # 或
results = model.train(
data='point_data.yaml',
imgsz=1280,
epochs=300,
batch=4,
workers=10,
device='0',
project='runs/train/point',
name='exp_pose',
exist_ok=False,
optimizer='AdamW',
lr0=0.001,
patience=100,
)