Skip to content

head and backbone keys missing #76

@fromtheeast710

Description

@fromtheeast710

I'm using this package on a custom dataset by me. When I run python src/model/train.py --batch 64 --data coco.yaml --device 0 the training will fail with error:

KeyError: 'backbone'

When I check the generated dataset.yaml, there's no head nor backbone key. The generated yaml file is as follow

path: /home/theeast/Documents/Education/WSU/CS3/ProfessionalExperience/final-system-pa2524/data/train/color/YOLODataset
train: images/train
val: images/val
test:

names:
    0: wombat

This is the training script I'm using

from ultralytics import YOLO

wombot_data = "data/train/color/YOLODataset/dataset.yaml"

model = YOLO(wombot_data, task="segment")
model = YOLO("asset/model/yolo11x-seg.pt")
model = YOLO(wombot_data).load("asset/model/yolo11x.pt")

results = model.train(
    data=wombot_data, epochs=100, imgsz=640
)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions