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

perf: Improve rle_id iteration performance and set sorted flags #16893

Merged
merged 1 commit into from
Jun 12, 2024
Merged

Conversation

ritchie46
Copy link
Member

Faster iteration and set proper flags. closes #16887

@github-actions github-actions bot added performance Performance issues or improvements python Related to Python Polars rust Related to Rust Polars labels Jun 12, 2024
}
}

let outvals = vec![Series::from_vec("len", lengths), vals.to_owned()];
Ok(StructChunked::new("rle", &outvals)?.into_series())
Ok(StructChunked::new(s.name(), &outvals)?.into_series())
Copy link
Member Author

Choose a reason for hiding this comment

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

We should always keep names.

Copy link

codecov bot commented Jun 12, 2024

Codecov Report

Attention: Patch coverage is 94.11765% with 1 line in your changes missing coverage. Please review.

Project coverage is 81.42%. Comparing base (4c80f22) to head (aee7c79).
Report is 3 commits behind head on main.

Files Patch % Lines
crates/polars-ops/src/series/ops/rle.rs 94.11% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main   #16893   +/-   ##
=======================================
  Coverage   81.41%   81.42%           
=======================================
  Files        1425     1425           
  Lines      187964   187973    +9     
  Branches     2704     2704           
=======================================
+ Hits       153027   153053   +26     
+ Misses      34440    34423   -17     
  Partials      497      497           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@ritchie46 ritchie46 merged commit f7cca90 into main Jun 12, 2024
27 checks passed
@ritchie46 ritchie46 deleted the rle branch June 12, 2024 08:01
@stinodego stinodego changed the title perf: Improve rle_id iteration perf and set sorted flags perf: Improve rle_id iteration performance and set sorted flags Jun 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
performance Performance issues or improvements python Related to Python Polars rust Related to Rust Polars
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Polars fails to recognize the benefits of an already sorted rle_id()
1 participant