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

Cherry-picking #4742 for release #4744

Merged
merged 2 commits into from
Aug 28, 2024
Merged

Conversation

brimoor
Copy link
Contributor

@brimoor brimoor commented Aug 28, 2024

Cherry picks #4742.

Summary by CodeRabbit

  • New Features

    • Enhanced handling of dataset paths for improved flexibility with multiple dataset splits.
    • Improved processing logic for image paths, accommodating various input formats.
  • Bug Fixes

    • Increased robustness in image path extraction, allowing for better handling of both .txt files and other formats.

Copy link
Contributor

coderabbitai bot commented Aug 28, 2024

Walkthrough

The recent changes to the fiftyone/utils/yolo.py file improve the handling of dataset paths within the setup function. The logic now accommodates multiple dataset paths, allowing for more flexible input processing. The function has been refactored to iterate over potential paths, handling both .txt files and other formats, enhancing its robustness and versatility.

Changes

Files Change Summary
fiftyone/utils/yolo.py Enhanced the setup function to support multiple dataset paths and refactored the image path processing logic.

Poem

🐇 In the garden where datasets bloom,
Paths intertwine, dispelling the gloom.
With a hop and a skip, we process with ease,
Each file and each path, a delightful breeze.
So here's to the changes, both nimble and spry,
A rabbit’s delight, as we leap to the sky! 🌼✨


Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

Share
Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai generate interesting stats about this repository and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (invoked as PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 9929c04 and 007fc96.

Files selected for processing (1)
  • fiftyone/utils/yolo.py (1 hunks)
Additional comments not posted (5)
fiftyone/utils/yolo.py (5)

509-511: LGTM!

The changes improve the flexibility of handling dataset paths by allowing split_info to be a string or a list. This ensures compatibility with various input formats.

The code changes are approved.


512-514: LGTM!

The changes ensure that all dataset paths are correctly normalized, which is crucial for consistent and error-free file handling.

The code changes are approved.


517-524: LGTM!

The changes improve the robustness of the function by accommodating various input formats and enhancing its ability to process multiple dataset splits.

The code changes are approved.


527-529: LGTM!

The changes ensure that only relevant image files are processed, which improves the function's efficiency and accuracy.

The code changes are approved.


527-529: LGTM!

The changes ensure that only relevant image files are processed, which improves the function's efficiency and accuracy.

The code changes are approved.

Copy link
Contributor

@benjaminpkane benjaminpkane left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀

@brimoor brimoor merged commit b391ca3 into release/v0.25.1 Aug 28, 2024
13 checks passed
@brimoor brimoor deleted the fix-yolov5-importer branch August 28, 2024 20:55
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.

3 participants