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

[REVIEW] Define and implement new stream compaction APIs copy_if, drop_nulls, apply_boolean_mask, drop_duplicate and unique_count. #3303

Merged
merged 49 commits into from
Nov 21, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
49 commits
Select commit Hold shift + click to select a range
86b05ec
changes
rgsl888prabhu Oct 31, 2019
470d7a2
Merge branch 'branch-0.11' of https://github.com/rapidsai/cudf into 2…
rgsl888prabhu Oct 31, 2019
0c6ad10
primary changes
rgsl888prabhu Nov 1, 2019
8331791
files are compiling
rgsl888prabhu Nov 4, 2019
f46ae31
changes for test cases
rgsl888prabhu Nov 4, 2019
d055987
merge 0.11
rgsl888prabhu Nov 4, 2019
216b367
changes to filter
rgsl888prabhu Nov 5, 2019
26b1b32
changes to return column
rgsl888prabhu Nov 5, 2019
8e755fb
ahh working
rgsl888prabhu Nov 5, 2019
b743175
All set
rgsl888prabhu Nov 5, 2019
7cfccc1
documentation
rgsl888prabhu Nov 5, 2019
a0d0e61
code changes and test cases
rgsl888prabhu Nov 5, 2019
a72ebe7
CHANGELOG
rgsl888prabhu Nov 5, 2019
ca97b2e
adding apply_boolean_mask
rgsl888prabhu Nov 7, 2019
8a1cea6
Adding apply_boolean_mask with test case
rgsl888prabhu Nov 7, 2019
8dd75d8
documentation
rgsl888prabhu Nov 7, 2019
664afea
review changes
rgsl888prabhu Nov 7, 2019
8c4f556
changes
rgsl888prabhu Nov 7, 2019
eb457ed
Merge branch 'branch-0.11' into 2948_adding_copy_if
harrism Nov 8, 2019
f15905a
unique_count and test cases
rgsl888prabhu Nov 11, 2019
4f710c7
added string test for unique count
rgsl888prabhu Nov 11, 2019
07d48c5
Added drop_duplicate test cases
rgsl888prabhu Nov 11, 2019
f75ad3a
documentation
rgsl888prabhu Nov 11, 2019
fa74c22
merge
rgsl888prabhu Nov 11, 2019
2ae0095
documentation
rgsl888prabhu Nov 11, 2019
3801ddd
cosmetic changes
rgsl888prabhu Nov 12, 2019
a544d09
doc changes
rgsl888prabhu Nov 12, 2019
00a6c6f
review changes including wrapper
rgsl888prabhu Nov 12, 2019
b20edc9
drop_duplicate to use vector of index values as keys
rgsl888prabhu Nov 13, 2019
0ffbf41
Changes apart from scatter in copy_if
rgsl888prabhu Nov 13, 2019
257b07d
documentation
rgsl888prabhu Nov 13, 2019
e076c09
addressed final set of review comments
rgsl888prabhu Nov 14, 2019
4551a99
review changes
rgsl888prabhu Nov 15, 2019
1fad669
code changes to support string in copy_if
rgsl888prabhu Nov 15, 2019
eb0641f
merge with 0.11
rgsl888prabhu Nov 15, 2019
3bb2666
missed changes
rgsl888prabhu Nov 15, 2019
c5d2f9f
merge with 0.11
rgsl888prabhu Nov 18, 2019
e9d3298
review changes
rgsl888prabhu Nov 18, 2019
653799f
specialization for gather
rgsl888prabhu Nov 18, 2019
703221a
removing the factory method
rgsl888prabhu Nov 18, 2019
856794d
review changes
rgsl888prabhu Nov 18, 2019
df0d9aa
review changes
rgsl888prabhu Nov 19, 2019
8a77cfb
review changes
rgsl888prabhu Nov 19, 2019
a1e1259
Merge branch 'branch-0.11' into 2948_adding_copy_if
harrism Nov 20, 2019
f5687b2
string test for drop_duplicates
rgsl888prabhu Nov 20, 2019
4129ed5
adding string test for cudf::gather
rgsl888prabhu Nov 21, 2019
91ef036
review changes
rgsl888prabhu Nov 21, 2019
ae85f57
Merge branch 'branch-0.11' of https://github.com/rapidsai/cudf into 2…
rgsl888prabhu Nov 21, 2019
5e64ad3
review changes
rgsl888prabhu Nov 21, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,8 @@
- PR #3380 Concatenate columns of strings
- PR #3382 Add fill function for strings column
- PR #3391 Move device_atomics_tests.cu files to legacy
- PR #3303 Define and implement new stream compaction APIs `copy_if`, `drop_nulls`,
`apply_boolean_mask`, `drop_duplicate` and `unique_count`.
- PR #3387 Strings column gather function
- PR #3389 Move quantiles.hpp + group_quantiles.hpp files to legacy
- PR #3398 Move reshape.hpp files to legacy
Expand Down
1 change: 1 addition & 0 deletions conda/recipes/libcudf/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ test:
- test -f $PREFIX/include/cudf/legacy/replace.hpp
- test -f $PREFIX/include/cudf/legacy/rolling.hpp
- test -f $PREFIX/include/cudf/legacy/search.hpp
- test -f $PREFIX/include/cudf/stream_compaction.hpp
- test -f $PREFIX/include/cudf/legacy/stream_compaction.hpp
- test -f $PREFIX/include/cudf/transpose.hpp
- test -f $PREFIX/include/cudf/legacy/transform.hpp
Expand Down
3 changes: 3 additions & 0 deletions cpp/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -394,6 +394,9 @@ add_library(cudf
src/transform/legacy/nans_to_nulls.cu
src/transform/transform.cpp
src/bitmask/legacy/bitmask_ops.cu
src/stream_compaction/apply_boolean_mask.cu
src/stream_compaction/drop_nulls.cu
src/stream_compaction/drop_duplicates.cu
src/stream_compaction/legacy/apply_boolean_mask.cu
src/stream_compaction/legacy/drop_nulls.cu
src/stream_compaction/legacy/drop_duplicates.cu
Expand Down
8 changes: 4 additions & 4 deletions cpp/include/cudf/copying.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ enum class mask_allocation_policy {
* @param[in] input Immutable view of input column to emulate
* @return std::unique_ptr<column> An empty column of same type as `input`
*/
std::unique_ptr<column> empty_like(column_view input);
std::unique_ptr<column> empty_like(column_view const& input);

/**
* @brief Creates an uninitialized new column of the same size and type as the `input`.
Expand All @@ -83,7 +83,7 @@ std::unique_ptr<column> empty_like(column_view input);
* @param[in] mr Optional, The resource to use for all allocations
* @return std::unique_ptr<column> A column with sufficient uninitialized capacity to hold the same number of elements as `input` of the same type as `input.type()`
*/
std::unique_ptr<column> allocate_like(column_view input,
std::unique_ptr<column> allocate_like(column_view const& input,
mask_allocation_policy mask_alloc = mask_allocation_policy::RETAIN,
rmm::mr::device_memory_resource *mr =
rmm::mr::get_default_resource());
Expand All @@ -98,7 +98,7 @@ std::unique_ptr<column> allocate_like(column_view input,
* @param[in] mr Optional, The resource to use for all allocations
* @return std::unique_ptr<column> A column with sufficient uninitialized capacity to hold the specified number of elements as `input` of the same type as `input.type()`
*/
std::unique_ptr<column> allocate_like(column_view input, size_type size,
std::unique_ptr<column> allocate_like(column_view const& input, size_type size,
mask_allocation_policy mask_alloc = mask_allocation_policy::RETAIN,
rmm::mr::device_memory_resource *mr =
rmm::mr::get_default_resource());
Expand All @@ -112,7 +112,7 @@ std::unique_ptr<column> allocate_like(column_view input, size_type size,
* @param[in] input_table Immutable view of input table to emulate
* @return std::unique_ptr<table> A table of empty columns with the same types as the columns in `input_table`
*/
std::unique_ptr<table> empty_like(table_view input_table);
std::unique_ptr<table> empty_like(table_view const& input_table);

/**
* @brief Slices a `column_view` into a set of `column_view`s according to a set of indices.
Expand Down
6 changes: 3 additions & 3 deletions cpp/include/cudf/detail/copy.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ ColumnView slice(ColumnView const& input,
* @param[in] stream Optional CUDA stream on which to execute kernels
* @return std::unique_ptr<column> An empty column of same type as `input`
*/
std::unique_ptr<column> empty_like(column_view input, cudaStream_t stream = 0);
std::unique_ptr<column> empty_like(column_view const& input, cudaStream_t stream = 0);

/**
* @brief Creates an uninitialized new column of the specified size and same type as the `input`.
Expand All @@ -83,7 +83,7 @@ std::unique_ptr<column> empty_like(column_view input, cudaStream_t stream = 0);
* @param[in] stream Optional CUDA stream on which to execute kernels
* @return std::unique_ptr<column> A column with sufficient uninitialized capacity to hold the specified number of elements as `input` of the same type as `input.type()`
*/
std::unique_ptr<column> allocate_like(column_view input, size_type size,
std::unique_ptr<column> allocate_like(column_view const& input, size_type size,
mask_allocation_policy mask_alloc =
mask_allocation_policy::RETAIN,
rmm::mr::device_memory_resource *mr =
Expand All @@ -100,7 +100,7 @@ std::unique_ptr<column> allocate_like(column_view input, size_type size,
* @param[in] stream Optional CUDA stream on which to execute kernels
* @return std::unique_ptr<table> A table of empty columns with the same types as the columns in `input_table`
*/
std::unique_ptr<table> empty_like(table_view input_table, cudaStream_t stream = 0);
std::unique_ptr<table> empty_like(table_view const& input_table, cudaStream_t stream = 0);

/**
* @brief Returns a new column, where each element is selected from either @p lhs or
Expand Down
Loading