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

WIP: Preferentially serialize Buffer as bytes #3978

Closed
wants to merge 1 commit into from

Conversation

jakirkham
Copy link
Member

When using pickle, objects like NumPy arrays may be transformed to bytes resulting in an additional copy. To avoid this try to go to bytes directly when possible. This should avoid that additional copy. If that fails, we can fallback to creating a NumPy array instead.

When using pickle, objects like NumPy arrays may be transformed to
`bytes` resulting in an additional copy. To avoid this try to go to
`bytes` directly when possible. This should avoid that additional copy.
If that fails, we can fallback to creating a NumPy array instead.
@jakirkham jakirkham requested a review from a team as a code owner January 29, 2020 02:37
@jakirkham jakirkham changed the title Preferentially serialize Buffer as bytes WIP: Preferentially serialize Buffer as bytes Jan 29, 2020
@kkraus14
Copy link
Collaborator

Seems like an even bigger reason to have an rmm.HostBuffer object to be able to serialize to.

@kkraus14 kkraus14 added 3 - Ready for Review Ready for review by team 4 - Needs cuDF (Python) Reviewer Python Affects Python cuDF API. labels Jan 29, 2020
@jakirkham
Copy link
Member Author

Happy to stick with this, but have an idea where we can benefit from this idea even when bytes can't be called. Will update in a bit 🙂

@jakirkham
Copy link
Member Author

Closing this out based on this comment.

@jakirkham jakirkham closed this Feb 4, 2020
@jakirkham jakirkham deleted the pickle_via_bytes branch February 4, 2020 23:44
@vyasr vyasr added 4 - Needs Review Waiting for reviewer to review or respond and removed 4 - Needs cuDF (Python) Reviewer labels Feb 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3 - Ready for Review Ready for review by team 4 - Needs Review Waiting for reviewer to review or respond Python Affects Python cuDF API.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants