-
-
Notifications
You must be signed in to change notification settings - Fork 16.7k
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
Hard coded 'val' key in val.py #4635
Comments
@robin-maillot good news 😃! Your original issue may now be fixed ✅ in PR #4642. This PR uses the safer To receive this update:
Thank you for spotting this issue and informing us of the problem. Please let us know if this update resolves the issue for you, and feel free to inform us of any other issues you discover or feature requests that come to mind. Happy trainings with YOLOv5 🚀! |
@glenn-jocher seems good but in the case that we are not training should it not be the Because later on we use the
I feel like in this case it makes sense to use something like:
Since I do not use coco anyways the fix you provided solves my issues, thanks :) I can submit a PR directly if you prefer to review it that way? |
@robin-maillot well the data dict for coco.yaml will always have a val key regardless of task = 'train|val|test', so in this line we are only trying to establish if the dataset is the official COCO dataset. The user should still be able to run |
@robin-maillot also remember sometimes task can also be set to Line 303 in fad57c2
|
@glenn-jocher makes sense, I was thinking of transfer learning cases where one might want to train/validate on some other dataset but test on coco, this might be an edge case that is better solved using the speed or study options like you mention. Thanks for taking the time to solve the bug :) |
Before submitting a bug report, please be aware that your issue must be reproducible with all of the following,
otherwise it is non-actionable, and we can not help you:
git fetch && git status -uno
to check andgit pull
to update repoIf this is a custom dataset/training question you must include your
train*.jpg
,val*.jpg
andresults.png
figures, or we can not help you. You can generate these with
utils.plot_results()
.🐛 Bug
A clear and concise description of what the bug is.
When running
val.py:run()
theis_coco
variable is calculated based on the val key and not the task key.This means when running python val.py --data data/coco128.yaml --task test
To Reproduce (REQUIRED)
Input:
python val.py --data data/coco128.yaml --task test
Output:
Expected behavior
A clear and concise description of what you expected to happen.
is_coco
should be calculated based ontask
key and not hard codedval
keyEnvironment
If applicable, add screenshots to help explain your problem.
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: