Im using a pretrained model(yolov8 (ultralytics)) which is trained on COCO dataset.(COCO has 80 classes). Now I am validating it on medical-pills dataset which has only 1 class.
After running this code,
from ultralytics import YOLO
Load YOLOv8 pose model
model = YOLO(“yolov8n.pt”)
Validate on the hand keypoints dataset
metrics = model.val(data=“/content/medical-pills.yaml”, save_json=True)
Print results
print(metrics)
Im getting all evaluation metrics and also val_batch0_labels.jpg and val_batch0_pred.jpg
In val_batch0_labels.jpg i am getting pills images all with bounding boxes detected as person(which is the first class in COCO)
and in val_batch0_pred.jpg
i am getting pills images as cup,cake,dining table,bottle(which all are classes of COCO dataset)
Why its taking pill as person,instead of taking it as pill.
Is there any class mismatch? Or is the code taking yaml file of COCO?