Skip to content

Make pylibcudf.Column.from_rmm_buffer a Python staticmethod #18521

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

Open
wants to merge 4 commits into
base: branch-25.06
Choose a base branch
from

Conversation

mroeschke
Copy link
Contributor

@mroeschke mroeschke commented Apr 17, 2025

Description

Add discussed offline with @vyasr, Column.from_rmm_buffer could allow users to create an invalid Column representation based on the passed dtype and the corresponding buffer and children. Additionally (for now), we want users to have a Python interface first when passing an rmm Buffer.

This turns from_rmm_buffer from a cdef function to a Python function and add some validation to ensure that buff and children are compatible with the dtype.

This PR also undos the changes to from_libcudf in #18502 since this is no longer a cdef method.

Checklist

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

@mroeschke mroeschke added improvement Improvement / enhancement to an existing function non-breaking Non-breaking change pylibcudf Issues specific to the pylibcudf package labels Apr 17, 2025
@mroeschke mroeschke self-assigned this Apr 17, 2025
@mroeschke mroeschke requested a review from a team as a code owner April 17, 2025 21:43
@github-actions github-actions bot added the Python Affects Python cuDF API. label Apr 17, 2025
@mroeschke mroeschke changed the title Add verify=True keyword to pylibcudf.Column.from_rmm_buffer Make pylibcudf.Column.from_rmm_buffer a Python staticmethod Apr 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
improvement Improvement / enhancement to an existing function non-breaking Non-breaking change pylibcudf Issues specific to the pylibcudf package Python Affects Python cuDF API.
Projects
Status: No status
Development

Successfully merging this pull request may close these issues.

1 participant