deduplicate.hpp
Go to the documentation of this file.
1 /*
2  * SPDX-FileCopyrightText: Copyright (c) 2025-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved.
3  * SPDX-License-Identifier: Apache-2.0
4  */
5 #pragma once
6 
7 #include <cudf/column/column.hpp>
9 #include <cudf/utilities/export.hpp>
11 
12 #include <rmm/cuda_stream_view.hpp>
13 #include <rmm/device_uvector.hpp>
14 
16 namespace CUDF_EXPORT nvtext {
40 std::unique_ptr<rmm::device_uvector<cudf::size_type>> build_suffix_array(
41  cudf::strings_column_view const& input,
42  cudf::size_type min_width,
45 
66 std::unique_ptr<cudf::column> resolve_duplicates(
67  cudf::strings_column_view const& input,
69  cudf::size_type min_width,
72 
95 std::unique_ptr<cudf::column> resolve_duplicates_pair(
96  cudf::strings_column_view const& input1,
98  cudf::strings_column_view const& input2,
100  cudf::size_type min_width,
103  // end of group
105 } // namespace CUDF_EXPORT nvtext
Given a column-view of strings type, an instance of this class provides a wrapper on this compound co...
Class definition for cudf::column.
rmm::cuda_stream_view const get_default_stream()
Get the current default stream.
rmm::device_async_resource_ref get_current_device_resource_ref()
Get the current device memory resource reference.
cuda::mr::resource_ref< cuda::mr::device_accessible > device_async_resource_ref
std::unique_ptr< rmm::device_uvector< cudf::size_type > > build_suffix_array(cudf::strings_column_view const &input, cudf::size_type min_width, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
Builds a suffix array for the input strings column.
std::unique_ptr< cudf::column > resolve_duplicates_pair(cudf::strings_column_view const &input1, cudf::device_span< cudf::size_type const > indices1, cudf::strings_column_view const &input2, cudf::device_span< cudf::size_type const > indices2, cudf::size_type min_width, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
Returns duplicate strings found from input1 found in the given input2.
std::unique_ptr< cudf::column > resolve_duplicates(cudf::strings_column_view const &input, cudf::device_span< cudf::size_type const > indices, cudf::size_type min_width, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
Returns duplicate strings found in the given input.
cuda::std::span< T, Extent > device_span
Device span is an alias of cuda::std::span.
Definition: span.hpp:296
int32_t size_type
Row index type for columns and tables.
Definition: types.hpp:84
APIs for getting and setting the current device memory resource.
NVText APIs.
Class definition for cudf::strings_column_view.