Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

数据集训练lable问题 #5

Open
libaitian-oss opened this issue Sep 2, 2024 · 6 comments
Open

数据集训练lable问题 #5

libaitian-oss opened this issue Sep 2, 2024 · 6 comments

Comments

@libaitian-oss
Copy link

你好作者,为什么我在训练时会报错Can not train without labels,显示在数据集目录下的images.cache没有标签数据

@mkang315
Copy link
Owner

mkang315 commented Sep 2, 2024

This error is because none of your images have labels/annotations. Make sure the data path is correct. To train correctly, the label format for images must be in YOLO format (.txt), otherwise there is nothing for YOLO to learn.

@libaitian-oss
Copy link
Author

Is the txt text of this lable file something I have to write myself? I didn't find the lable folder inside the file linked to your dataset.

@mkang315
Copy link
Owner

mkang315 commented Sep 5, 2024

Yes. I suppose you can find a source code on GitHub for converting the original labels to any format if they are not YOLO format.

@libaitian-oss
Copy link
Author

thank you

@libaitian-oss
Copy link
Author

Why do I keep getting an error after converting the XML format to the YOLO format, saying that "labels" cannot be found?

@mkang315
Copy link
Owner

mkang315 commented Sep 5, 2024

You need to specify the correct label paths. See the custom training tutorial to get started, and follow the example:
https://docs.ultralytics.com/yolov5/tutorials/train_custom_data

I suggest you'd better try your dataset using the original YOLOv5/7/8 models and find whether it works with them. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants