-
Notifications
You must be signed in to change notification settings - Fork 915
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
Adds explode
API
#7607
Merged
Merged
Adds explode
API
#7607
Changes from all commits
Commits
Show all changes
17 commits
Select commit
Hold shift + click to select a range
bd111e1
Passing tests
isVoid 2c543c6
Cleaning stale docstrings
isVoid 82467e4
Merge branch 'branch-0.19' of https://github.com/rapidsai/cudf into 2…
isVoid 6cc0fee
remove fillna in test code
isVoid 8768389
small doc fix
isVoid 726dec5
Merge branch 'branch-0.19' of https://github.com/rapidsai/cudf into 2…
isVoid 7aa72e4
direct passing ignore_index
isVoid 859f0f6
handling no-op case
isVoid fe085f6
Account for multi-level column names
isVoid ca419cc
Doc for _explode
isVoid 9d7e4a1
Better handling of index column
isVoid c09f815
Rev: avoid extra index copy when ignore_index=True
isVoid b33a6a0
Remove stale comments
isVoid 25409c1
style
isVoid 767d3e2
Move copy case 1-level up
isVoid 7cb25e7
Rev: _explode doc fix
isVoid 6ce751a
Rev: small docstrings bug fix
isVoid File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# Copyright (c) 2021, NVIDIA CORPORATION. | ||
|
||
from libcpp.memory cimport unique_ptr | ||
|
||
from cudf._lib.cpp.table.table cimport table | ||
from cudf._lib.cpp.table.table_view cimport table_view | ||
from cudf._lib.cpp.types cimport size_type | ||
|
||
cdef extern from "cudf/lists/explode.hpp" namespace "cudf" nogil: | ||
cdef unique_ptr[table] explode_outer( | ||
const table_view, | ||
size_type explode_column_idx, | ||
) except + |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we not have a helper function that handles all of the "gotchas" in this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Checked with @shwina, and can't think of any..
._data
is constructed insidefrom_unique_ptr
, which has no information aboutmultiindex
and_level_names.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree it's not ideal. One alternative I've considered in the past is a custom
ColumnMeta
type containing information about column names:And we pass objects of that type as arguments to
._from_unique_ptr
:Maybe a bit out of scope for this PR though.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Definitely out of scope for this PR, but I like it a lot.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is
ColumnMeta
owned and maintained by some class? Or is it a message interface that gets created on the fly and passes around classes?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good question -- I think we should have a separate discussion about this outside the context of this PR. Happy to sync offline and then raise an issue?