hailo-ai / hailo_model_zoo

The Hailo Model Zoo includes pre-trained models and a full building and evaluation environment
MIT License
266 stars 40 forks source link

Yolov8 custom dataset #77

Open lenam2132002 opened 9 months ago

lenam2132002 commented 9 months ago

I'm training a model yolov8 to detect fire and smoke on my custom dataset. Every thing is fine, but when I running infer to my valid dataset, the label has gone wrong! Here is example: image So, what can I do to correct the label! Thank you!

omerwer commented 8 months ago

Hi @lenam2132002, The default training dataset for the yolov8 is COCO, that have 80 classes. Your model seems to be trained perfectly to detect fire and smoke, but the labels that are used in the code are pre-fixed to be COCO 80's. If you are using the Hailo Model Zoo's eval, then you need to update coco_names.json file that is located under model_zoo/hailo_model_zoo/core/postprocessing/coco_names.json to fit the classes your model is trained on.

Regards,

lenam2132002 commented 8 months ago

Thank you for your help! I fixed it successfully

bryanjuho commented 3 months ago

Does this apply too when compiling models? I've changed coco_names.json but it seems to have no effect on my compiled model.

Hi @lenam2132002, The default training dataset for the yolov8 is COCO, that have 80 classes. Your model seems to be trained perfectly to detect fire and smoke, but the labels that are used in the code are pre-fixed to be COCO 80's. If you are using the Hailo Model Zoo's eval, then you need to update coco_names.json file that is located under model_zoo/hailo_model_zoo/core/postprocessing/coco_names.json to fit the classes your model is trained on.

Regards,