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

Fix min_items #10001

Merged
merged 1 commit into from
Nov 1, 2022
Merged

Fix min_items #10001

merged 1 commit into from
Nov 1, 2022

Conversation

glenn-jocher
Copy link
Member

@glenn-jocher glenn-jocher commented Nov 1, 2022

Signed-off-by: Glenn Jocher glenn.jocher@ultralytics.com

πŸ› οΈ PR Summary

Made with ❀️ by Ultralytics Actions

🌟 Summary

Optimization of image filtering logic in data loader.

πŸ“Š Key Changes

  • Updated the conditional check from len(x) > min_items to len(x) >= min_items for determining which images to include in a dataset.
  • Fixed the logging message to correctly display the number of images filtered from the dataset using n instead of nf.

🎯 Purpose & Impact

  • The modification ensures images with exactly min_items number of annotations will also be included in the dataset, rather than strictly more than min_items.
  • The updated logging message provides accurate feedback on the dataset filtering process, aiding in debugging and dataset understanding.
  • πŸ§‘β€πŸ’» Developers will benefit from more precise dataset creation, and πŸ“ˆ model training may improve due to the inclusion of additional valid images.
  • πŸ–ΌοΈ Users leveraging the Ultralytics YOLOv5 framework for object detection tasks may experience slightly increased dataset sizes and potentially more robust training results.

Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com>
@glenn-jocher glenn-jocher self-assigned this Nov 1, 2022
@glenn-jocher glenn-jocher merged commit 82a5585 into master Nov 1, 2022
@glenn-jocher glenn-jocher deleted the glenn-jocher-patch-2 branch November 1, 2022 15:41
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

Successfully merging this pull request may close these issues.

None yet

1 participant