Skip to content

Conversation

glenn-jocher
Copy link
Member

@glenn-jocher glenn-jocher commented Jun 7, 2022

πŸ› οΈ PR Summary

Made with ❀️ by Ultralytics Actions

🌟 Summary

Improved code organization and enhanced dataset statistics functionality in YOLOv5 dataloaders.

πŸ“Š Key Changes

  • 🧹 Code Cleanup: Comments have been updated to reflect the reorganization (utils.datasets -> utils.dataloaders).
  • πŸ” Improving Dataset Unzipping: Added assertions to the _unzip function for better error handling and clarity.
  • πŸ”„ Refactoring Helper Functions: Private function naming (prefixed with _) for utility functions such as _round_labels, _find_yaml, and _hub_ops.
  • 🧐 Enhanced Dataset Stats: The dataset_stats function now includes assertions to ensure proper .yaml file finding and handling multiple .yaml files.

🎯 Purpose & Impact

  • πŸ—‚ Better Organization: Helps maintain clean codebase by correctly referencing the updated file structure, which is helpful for new contributors.
  • πŸ›  Error Handling Improvements: Makes unzipping more robust and error-proof, giving users clearer feedback if something goes wrong.
  • πŸš€ Function Clarity: The privatization of helper functions enforces better practice in code structure and usage.
  • πŸ“ˆ Detailed Stats: Provides users with more accurate and reliable dataset statistics, which is critical for data analysis and model performance understanding.

@glenn-jocher glenn-jocher self-assigned this Jun 7, 2022
@glenn-jocher glenn-jocher changed the title Update dataloaders.py Improved dataset_stats() YAML checks Jun 7, 2022
@glenn-jocher
Copy link
Member Author

@kalenmike here are the dataset_stats() yaml check improvements I mentioned.

@glenn-jocher glenn-jocher merged commit c23a441 into master Jun 11, 2022
@glenn-jocher glenn-jocher deleted the update/comments branch June 11, 2022 17:30
ctjanuhowski pushed a commit to ctjanuhowski/yolov5 that referenced this pull request Sep 8, 2022
* Update dataloaders.py

* Update dataloaders.py

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
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.

2 participants