Skip to content

Comments

Add RowSelection::from_selectors_and_combine to merge RowSelectors #2994

Merged
alamb merged 5 commits intoapache:masterfrom
Ted-Jiang:ISSUE_2858
Nov 2, 2022
Merged

Add RowSelection::from_selectors_and_combine to merge RowSelectors #2994
alamb merged 5 commits intoapache:masterfrom
Ted-Jiang:ISSUE_2858

Conversation

@Ted-Jiang
Copy link
Member

Which issue does this PR close?

Closes #2858 .

Rationale for this change

What changes are included in this PR?

Are there any user-facing changes?

@github-actions github-actions bot added the parquet Changes to the parquet crate label Nov 1, 2022
Copy link
Contributor

@alamb alamb left a comment

Choose a reason for hiding this comment

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

Look good to me @Ted-Jiang -- nice work! I have one more set of tests I recommend, but otherwise this PR looks good to me 👍 thank you!

cc @tustvold

Self { selectors }
}

/// Creates a [`RowSelection`] from a slice of uncombined `RowSelector`:
Copy link
Contributor

Choose a reason for hiding this comment

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

👍 thank you for the comments

}
let first = selectors.first().unwrap();
let mut sum_rows = first.row_count;
let mut selected = first.skip;
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
let mut selected = first.skip;
let mut skip = first.skip;

Maybe it would be easier to read this code if the name of the variable is the same as the name of the field that uses it 🤔

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes 😂

Copy link
Contributor

@alamb alamb left a comment

Choose a reason for hiding this comment

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

Looks great -- thanks @Ted-Jiang

@alamb alamb changed the title Support merge RowSelectors when creating RowSelection Add RowSelection::from_selectors_and_combine to merge RowSelectors Nov 2, 2022
@alamb alamb merged commit f11372c into apache:master Nov 2, 2022
@ursabot
Copy link

ursabot commented Nov 2, 2022

Benchmark runs are scheduled for baseline = 62e878e and contender = f11372c. f11372c is a master commit associated with this PR. Results will be available as each benchmark for each run completes.
Conbench compare runs links:
[Skipped ⚠️ Benchmarking of arrow-rs-commits is not supported on ec2-t3-xlarge-us-east-2] ec2-t3-xlarge-us-east-2
[Skipped ⚠️ Benchmarking of arrow-rs-commits is not supported on test-mac-arm] test-mac-arm
[Skipped ⚠️ Benchmarking of arrow-rs-commits is not supported on ursa-i9-9960x] ursa-i9-9960x
[Skipped ⚠️ Benchmarking of arrow-rs-commits is not supported on ursa-thinkcentre-m75q] ursa-thinkcentre-m75q
Buildkite builds:
Supported benchmarks:
ec2-t3-xlarge-us-east-2: Supported benchmark langs: Python, R. Runs only benchmarks with cloud = True
test-mac-arm: Supported benchmark langs: C++, Python, R
ursa-i9-9960x: Supported benchmark langs: Python, R, JavaScript
ursa-thinkcentre-m75q: Supported benchmark langs: C++, Java

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

parquet Changes to the parquet crate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support merge RowSelectors when creating RowSelection

3 participants