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

add Rerun integrations doc #5255

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from
Open

add Rerun integrations doc #5255

wants to merge 3 commits into from

Conversation

sashankaryal
Copy link
Contributor

@sashankaryal sashankaryal commented Dec 11, 2024

What changes are proposed in this pull request?

Add a dedicated integration doc for Rerun. Note that a new integration category (Visualization) has been added.

Release Notes

Is this a user-facing change that should be mentioned in the release notes?

  • No. You can skip the rest of this section.
  • Yes. Give a description of this change to be included in the release
    notes for FiftyOne users.

What areas of FiftyOne does this PR affect?

  • App: FiftyOne application changes
  • Build: Build and test infrastructure changes
  • Core: Core fiftyone Python library changes
  • Documentation: FiftyOne documentation changes
  • Other

Summary by CodeRabbit

  • New Features

    • Introduced a new integration card for "Rerun" in the FiftyOne documentation.
    • Added a dedicated section for "Rerun Integration" with setup and workflow instructions.
    • Included example usage for integrating .rrd files with FiftyOne datasets.
  • Documentation

    • Enhanced the documentation structure with a new entry in the table of contents for "Rerun".

@sashankaryal sashankaryal requested a review from brimoor December 11, 2024 02:34
@sashankaryal sashankaryal self-assigned this Dec 11, 2024
Copy link
Contributor

coderabbitai bot commented Dec 11, 2024

Walkthrough

The changes introduce a new integration card for "Rerun" in the FiftyOne documentation, enhancing the existing tutorial cards. A dedicated documentation file (rerun.rst) is also added, detailing the integration process for visualizing Rerun data files within the FiftyOne framework. This includes setup instructions, workflow integration for .rrd files, and an example usage section referencing the NuScenes dataset. The modifications ensure that users can easily access and implement the Rerun integration.

Changes

File Path Change Summary
docs/source/integrations/index.rst Added a custom integration card for "Rerun" with header, description, link, image, and tags.
docs/source/integrations/rerun.rst Created new documentation for Rerun integration, including setup instructions, workflow, and usage examples.

Possibly related PRs

  • Add documentation for Elasticsearch vector DB integration #4431: The changes in this PR also involve adding a new custom card to the docs/source/integrations/index.rst file, similar to the main PR's addition of the "Rerun" card, indicating a related effort to enhance the documentation for integrations within FiftyOne.

Suggested labels

documentation

Suggested reviewers

  • mwoodson1
  • brimoor

Poem

In the garden of code, a new card does bloom,
Rerun's bright colors dispel all the gloom.
With steps laid out clear, and examples so bright,
Visualizing data brings joy and delight!
Hopping through docs, we find our way,
FiftyOne and Rerun, together they play! 🐇✨


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>, please review it.
    • 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 gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @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 using 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 generate docstrings to generate docstrings for this PR. (Experiment)
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

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

🧹 Outside diff range and nitpick comments (5)
docs/source/integrations/rerun.rst (5)

22-26: Consider adding version requirements

It would be helpful to specify minimum version requirements for both FiftyOne and Rerun SDK packages.


51-61: Enhance code example with error handling and path clarification

Consider:

  1. Adding error handling for file operations
  2. Clarifying that the path should be absolute or relative
  3. Adding a note about supported file formats
 # create a new recording
 recording = rr.new_recording(application_id="my_dataset", recording_id="my_scene.rrd")

 # log example data
-recording.log("my_points", rr.Points3D(positions, colors=colors, radii=0.5))
+try:
+    recording.log("my_points", rr.Points3D(positions, colors=colors, radii=0.5))
+    # Use os.path for cross-platform compatibility
+    recording.save(os.path.abspath("/path/to/my_scene.rrd"))
+except Exception as e:
+    print(f"Error logging data: {e}")
-recording.save("/path/to/my_scene.rrd")

73-79: Enhance dataset example with concrete use case

The example could be more helpful with:

  1. A concrete dataset initialization example
  2. Proper path handling
  3. Error handling for file existence
-dataset = fo.Dataset(...)
+# Example with a concrete dataset
+dataset = fo.Dataset("my_dataset")
+
 for sample in dataset:
-    rrd_path = "/path/to/my_scene.rrd"
+    rrd_path = os.path.join(data_dir, f"{sample.id}.rrd")
+    if not os.path.exists(rrd_path):
+        print(f"Warning: RRD file not found: {rrd_path}")
+        continue
     sample["rerun"] = RrdFile(rrd_path)

81-93: Add troubleshooting section for common server issues

Consider adding a troubleshooting section addressing:

  1. Common connection issues
  2. Port conflicts
  3. Network accessibility problems

114-123: Enhance example usage section with more context

Consider:

  1. Adding a brief overview of what the example demonstrates
  2. Listing prerequisites for running the example
  3. Including expected outcomes
📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL

📥 Commits

Reviewing files that changed from the base of the PR and between 81db334 and 7b7a338.

⛔ Files ignored due to path filters (1)
  • docs/source/_static/images/integrations/rerun.jpeg is excluded by !**/*.jpeg
📒 Files selected for processing (2)
  • docs/source/integrations/index.rst (2 hunks)
  • docs/source/integrations/rerun.rst (1 hunks)
🔇 Additional comments (2)
docs/source/integrations/rerun.rst (1)

1-14: Well-structured introduction!

The introduction clearly explains what Rerun is and how it integrates with FiftyOne.

docs/source/integrations/index.rst (1)

184-189: Integration card properly added!

The Rerun integration card follows the established format and is correctly added to both the cards section and toctree.

Also applies to: 230-230

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

🧹 Outside diff range and nitpick comments (6)
docs/source/integrations/rerun.rst (6)

26-26: Consider specifying version requirements

For better reproducibility and compatibility, consider specifying minimum required versions for both packages.

-    $ pip install fiftyone rerun-sdk
+    $ pip install "fiftyone>=0.22.0" "rerun-sdk>=0.9.0"

20-23: Add system requirements section

Consider adding system requirements or prerequisites before the installation steps, such as:

  • Supported Python versions
  • Operating system compatibility
  • Hardware requirements (if any)

75-79: Add error handling to the code example

Consider enhancing the code example with error handling for common scenarios:

 for sample in dataset:
-    rrd_path = "/path/to/my_scene.rrd"
-    sample["rerun"] = RrdFile(rrd_path)
+    rrd_path = "/path/to/my_scene.rrd"
+    try:
+        if os.path.exists(rrd_path):
+            sample["rerun"] = RrdFile(rrd_path)
+        else:
+            logger.warning(f"RRD file not found: {rrd_path}")
+    except Exception as e:
+        logger.error(f"Failed to process {rrd_path}: {e}")

87-88: Add server configuration details

Consider adding information about:

  • How to configure a different port
  • Network configuration for remote access
  • Troubleshooting common connection issues

117-123: Enhance the example section

Consider adding:

  • A brief overview of what users will learn from the example
  • Screenshots or diagrams showing the expected visualization
  • Key features demonstrated in the example

108-109: Add a troubleshooting section

Consider adding a "Troubleshooting" section that covers:

  • Common issues and their solutions
  • FAQ
  • Known limitations
  • Best practices for optimal performance
📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL

📥 Commits

Reviewing files that changed from the base of the PR and between 7b7a338 and 1639be0.

📒 Files selected for processing (1)
  • docs/source/integrations/rerun.rst (1 hunks)
🔇 Additional comments (1)
docs/source/integrations/rerun.rst (1)

1-14: LGTM! Well-structured documentation header

The file structure follows RST best practices with proper reference anchors and formatting. The overview effectively communicates the purpose and value proposition of the Rerun integration.

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.

1 participant