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

Image not found error #12917

Closed
1 task done
Cho-Hong-Seok opened this issue Apr 14, 2024 · 2 comments
Closed
1 task done

Image not found error #12917

Cho-Hong-Seok opened this issue Apr 14, 2024 · 2 comments
Labels
question Further information is requested Stale

Comments

@Cho-Hong-Seok
Copy link

Cho-Hong-Seok commented Apr 14, 2024

Search before asking

Question

I want to custom train yolov6-seg, but I keep getting an error that the image file was not found. I set all paths to absolute.

I'm running it on google colab, I've mounted the drive, and I've checked that the image files exist in the image path, so what could be the problem?

Could this be because my dataset is not in a subfolder of the YOLOv6 folder?
I noticed that 'Train_custom_data.md' says it should be in the YOLOv6 folder.

This is train code.

!python tools/train.py --batch 32 --conf /content/YOLOv6/configs/yolov6s_seg.py --epochs 50 --img-size 416 --data /content/drive/MyDrive/[DILab_data]/Computer_Vision/Fire_detection/FST1/FST1/data.yaml --device 0

This is data.yaml file.

train: /content/drive/MyDrive/[DILab_data]/Computer_Vision/Fire_detection/FST1/FST1/train/images
val: /content/drive/MyDrive/[DILab_data]/Computer_Vision/Fire_detection/FST1/FST1/valid/images
test: /content/drive/MyDrive/[DILab_data]/Computer_Vision/Fire_detection/FST1/FST1/test/images

nc: 2
names: ['fire', 'smoke']

v6_1
v6_2

Additional

No response

@Cho-Hong-Seok Cho-Hong-Seok added the question Further information is requested label Apr 14, 2024
@glenn-jocher
Copy link
Member

Hey there! 🚀

It seems like you're encountering a "image not found" issue during your custom training on Colab with YOLOv6-seg. Here are a few suggestions to troubleshoot this:

  1. Make sure the paths in your data.yaml are correctly pointing to the locations where your dataset resides. Since you are using absolute paths and confirm the files exist, this is likely not the issue but always good to double-check.
  2. Verify that the filepath does not contain any special characters or spaces that might not be properly interpreted in the command line or by the script. Sometimes, characters like [ or ] can cause issues.
  3. Although you mentioned your dataset is not in a subfolder of the YOLOv6 folder and referred to a specific training guide, I'd like to clarify that your dataset can be outside the YOLOv6 directory, as long as the paths in data.yaml are correct. However, since this error persists, try moving your dataset into a subfolder within the YOLOv6 directory if feasible, just to rule out any permission/access issues, especially on Colab.
  4. Since you're running this on Google Colab, ensure that the runtime hasn't reset (which can sometimes disconnect your mounted drive) by re-checking the drive's mount status and the existence of your data files from the notebook.

Unfortunately, I must clarify that your question mentions YOLOv6, but as an expert from the Ultralytics YOLOv5 GitHub repo, my guidance is primarily for YOLOv5. While the advice above is quite general and could be applied across various YOLO versions, specific YOLOv6 issues might need insights from the relevant repository or community.

If you're working with YOLOv5 and facing similar problems, feel free to adapt these suggestions accordingly. If you're indeed looking for YOLOv6-related support, reaching out to the respective repo might yield more precise guidance.

Hope this nudges you in the right direction! Keep experimenting and don't hesitate to reach out with more YOLOv5 related queries. 💡

Copy link
Contributor

👋 Hello there! We wanted to give you a friendly reminder that this issue has not had any recent activity and may be closed soon, but don't worry - you can always reopen it if needed. If you still have any questions or concerns, please feel free to let us know how we can help.

For additional resources and information, please see the links below:

Feel free to inform us of any other issues you discover or feature requests that come to mind in the future. Pull Requests (PRs) are also always welcomed!

Thank you for your contributions to YOLO 🚀 and Vision AI ⭐

@github-actions github-actions bot added the Stale label May 15, 2024
@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale May 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested Stale
Projects
None yet
Development

No branches or pull requests

2 participants