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 a How-to guide for the dataframe API #7727

Merged
merged 6 commits into from
Oct 15, 2024
Merged

Conversation

abey79
Copy link
Member

@abey79 abey79 commented Oct 14, 2024

What

This PR introduces a How-to guid for the dataframe API which includes:

  • a reference-style coverage of all dataframe api features
  • recipes to ingest data in a pyarrow table, pandas df, polars df, or duckdb relation

Needs this to pass CI:

Checklist

  • I have read and agree to Contributor Guide and the Code of Conduct
  • I've included a screenshot or gif (if applicable)
  • I have tested the web demo (if applicable):
  • The PR title and labels are set such as to maximize their usefulness for the next release's CHANGELOG
  • If applicable, add a new check to the release checklist!
  • If have noted any breaking changes to the log API in CHANGELOG.md and the migration guide

To run all checks from main, comment on the PR with @rerun-bot full-check.

Copy link

github-actions bot commented Oct 14, 2024

Deployed docs

Commit Link
28295e9 https://landing-ga0pzhtzp-rerun.vercel.app/docs

@abey79 abey79 added 📖 documentation Improvements or additions to documentation include in changelog labels Oct 14, 2024
Copy link
Member

@emilk emilk left a comment

Choose a reason for hiding this comment

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

Very nice ⭐

docs/content/howto/dataframe-api.md Outdated Show resolved Hide resolved
docs/content/howto/dataframe-api.md Outdated Show resolved Hide resolved
docs/content/howto/dataframe-api.md Outdated Show resolved Hide resolved
docs/content/howto/dataframe-api.md Outdated Show resolved Hide resolved
docs/content/howto/dataframe-api.md Show resolved Hide resolved
docs/content/howto/dataframe-api.md Show resolved Hide resolved
Comment on lines +113 to +114
# only keep rows where a position is available for the robot
view = view.filter_is_not_null(rr.dataframe.ComponentColumnSelector("/world/robot", "Position3D"))
Copy link
Member

Choose a reason for hiding this comment

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

it would be so nice if this could be written as

# only keep rows where a position is available for the robot
view = view.filter_is_not_null("/world/robot:Position3D")

Copy link
Member

Choose a reason for hiding this comment

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

We have the code for this kind of parsing in crates/store/re_log_types/src/path/parse_path.rs (ComponentPath::from_str)

Copy link
Member

Choose a reason for hiding this comment

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

When I started looking into this it got hung up on questions like whether

"world/camera/**:[Image,Transform3D,Pinhole]"

is a legal expression.

docs/content/howto/dataframe-api.md Outdated Show resolved Hide resolved
@Wumpf Wumpf self-assigned this Oct 15, 2024
"/world/scene": ["Text"],
})
```

Copy link
Member

Choose a reason for hiding this comment

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

I'm following along with a code editor and at this point I'm wondering a lot what I can do with a view to get data. Should probably go here somewhere

view = view.filter_range_sequence(0, 10)
```

This API exists for both temporal and sequence timeline, and for various units:
Copy link
Member

Choose a reason for hiding this comment

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

all of these should be api links?

Copy link
Member

Choose a reason for hiding this comment

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

hmm maybe not yet because we haven't document all of them that well yet

@Wumpf Wumpf merged commit 6535073 into main Oct 15, 2024
31 of 32 checks passed
@Wumpf Wumpf deleted the antoine/dataframe-api-howto branch October 15, 2024 15:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
📖 documentation Improvements or additions to documentation include in changelog
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants