Files
orisys 4ad53f4e97 first
2026-08-21 14:51:57 +08:00

51 lines
909 B
YAML
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.
# YOLOv8 训练配置模板
# 改完后在项目根目录执行:
# yolo train cfg=train.yaml
task: detect
mode: train
model: yolov8n.pt # n/s/m/l/x,或本地 best.pt
data: 01data.yaml # 指向本项目数据集配置
epochs: 100
batch: 8 # 显存不够改 4 或 2,-1 为自动
imgsz: 640
device: 0 # 0=GPUcpu=CPU
workers: 4 # Windows 报错可改 0
amp: true
project: runs
name: yolov8_gongjian
exist_ok: true
save: true
save_period: 10
plots: true
val: true
patience: 50
optimizer: auto # auto / SGD / Adam / AdamW
lr0: 0.01
lrf: 0.01
momentum: 0.937
weight_decay: 0.0005
warmup_epochs: 3.0
cos_lr: false
close_mosaic: 10
pretrained: true
resume: false
seed: 0
hsv_h: 0.015
hsv_s: 0.7
hsv_v: 0.4
degrees: 0.0
translate: 0.1
scale: 0.5
fliplr: 0.5
mosaic: 1.0
mixup: 0.0
box: 7.5
cls: 0.5
dfl: 1.5