Skip to content

Enable sorting on column with nulls using query-planning - #15639

Merged
rapids-bot[bot] merged 7 commits into
NVIDIA:branch-24.06from
rjzamora:handle-null-sorting
May 9, 2024
Merged

Enable sorting on column with nulls using query-planning#15639
rapids-bot[bot] merged 7 commits into
NVIDIA:branch-24.06from
rjzamora:handle-null-sorting

Conversation

@rjzamora

@rjzamora rjzamora commented May 2, 2024

Copy link
Copy Markdown
Contributor

Description

Related to #15027

Checklist

  • I am familiar with the Contributing Guidelines.
  • New or existing tests cover these changes.
  • The documentation is up to date with these changes.

@rjzamora rjzamora added bug Something isn't working non-breaking Non-breaking change labels May 2, 2024
@rjzamora rjzamora self-assigned this May 2, 2024
@github-actions github-actions Bot added the Python Affects Python cuDF API. label May 2, 2024
@rjzamora
rjzamora marked this pull request as ready for review May 2, 2024 23:12
@rjzamora
rjzamora requested a review from a team as a code owner May 2, 2024 23:12

@wence- wence- left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Minor request for a little more doc on the differences.



def _cudf_layer(self):
if hasattr(self._meta, "to_pandas"):

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

nit: this canary for whether or not we have a cudf-backed object is also true for pyarrow objects I think. I know this is a hypothetical right now, but just noting it.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Could you add a short comment about what exactly this code does differently from the upstream version such that it can handle nulls?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

nit: this canary for whether or not we have a cudf-backed object is also true for pyarrow objects I think. I know this is a hypothetical right now, but just noting it.

Yeah, sorry. This was used as a simple toggle when I was experimenting in the dask-expr code itself. If the code lives in dask-cudf, we can do an instance check.

Could you add a short comment about what exactly this code does differently from the upstream version such that it can handle nulls?

Yes. I agree that a more-thorough comment is definitely needed here.

@rjzamora rjzamora added the 2 - In Progress Currently a work in progress label May 6, 2024
@rjzamora
rjzamora marked this pull request as draft May 6, 2024 14:06
@rjzamora rjzamora changed the title Add custom cudf logic for RepartitionQuantiles in dask-expr Enable sorting on column with nulls using query-planning May 6, 2024


@xfail_dask_expr("dask-expr code path fails with nulls")
@xfail_dask_expr("missing null support", lt_version="2024.5.1")

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I'd like this test to run for anything newer than the "2024.5.0" release (including main). Not sure of the "correct" way to do this.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I think that is correct. pytest.mark.xfail(some_condition, reason="some_reason") which is what this expands to is the canonical way.

@rjzamora
rjzamora marked this pull request as ready for review May 9, 2024 13:39
@rjzamora rjzamora added 5 - Ready to Merge Testing and reviews complete, ready to merge and removed 2 - In Progress Currently a work in progress labels May 9, 2024
@rjzamora

rjzamora commented May 9, 2024

Copy link
Copy Markdown
Contributor Author

/merge

@rapids-bot
rapids-bot Bot merged commit 69fe213 into NVIDIA:branch-24.06 May 9, 2024
@rjzamora
rjzamora deleted the handle-null-sorting branch May 9, 2024 17:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

5 - Ready to Merge Testing and reviews complete, ready to merge bug Something isn't working non-breaking Non-breaking change Python Affects Python cuDF API.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants