Public Member Functions | List of all members
cudf::distinct_hash_join Class Reference

Distinct hash join that builds hash table in creation and probes results in subsequent *_join member functions. More...

#include <join.hpp>

Public Member Functions

 distinct_hash_join (distinct_hash_join const &)=delete
 
 distinct_hash_join (distinct_hash_join &&)=delete
 
distinct_hash_joinoperator= (distinct_hash_join const &)=delete
 
distinct_hash_joinoperator= (distinct_hash_join &&)=delete
 
 distinct_hash_join (cudf::table_view const &build, null_equality compare_nulls=null_equality::EQUAL, rmm::cuda_stream_view stream=cudf::get_default_stream())
 Constructs a distinct hash join object for subsequent probe calls. More...
 
std::pair< std::unique_ptr< rmm::device_uvector< size_type > >, std::unique_ptr< rmm::device_uvector< size_type > > > inner_join (cudf::table_view const &probe, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref()) const
 Returns the row indices that can be used to construct the result of performing an inner join between two tables. More...
 
std::unique_ptr< rmm::device_uvector< size_type > > left_join (cudf::table_view const &probe, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref()) const
 Returns the build table indices that can be used to construct the result of performing a left join between two tables. More...
 

Detailed Description

Distinct hash join that builds hash table in creation and probes results in subsequent *_join member functions.

This class enables the distinct hash join scheme that builds hash table once, and probes as many times as needed (possibly in parallel).

Note
Behavior is undefined if the build table contains duplicates.
All NaNs are considered as equal

Definition at line 477 of file join.hpp.

Constructor & Destructor Documentation

◆ distinct_hash_join()

cudf::distinct_hash_join::distinct_hash_join ( cudf::table_view const &  build,
null_equality  compare_nulls = null_equality::EQUAL,
rmm::cuda_stream_view  stream = cudf::get_default_stream() 
)

Constructs a distinct hash join object for subsequent probe calls.

Parameters
buildThe build table that contains distinct elements
compare_nullsControls whether null join-key values should match or not
streamCUDA stream used for device memory operations and kernel launches

Member Function Documentation

◆ inner_join()

std::pair<std::unique_ptr<rmm::device_uvector<size_type> >, std::unique_ptr<rmm::device_uvector<size_type> > > cudf::distinct_hash_join::inner_join ( cudf::table_view const &  probe,
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
) const

Returns the row indices that can be used to construct the result of performing an inner join between two tables.

See also
cudf::inner_join().
Parameters
probeThe probe table, from which the keys are probed
streamCUDA stream used for device memory operations and kernel launches
mrDevice memory resource used to allocate the returned indices' device memory.
Returns
A pair of columns [probe_indices, build_indices] that can be used to construct the result of performing an inner join between two tables with build and probe as the join keys.

◆ left_join()

std::unique_ptr<rmm::device_uvector<size_type> > cudf::distinct_hash_join::left_join ( cudf::table_view const &  probe,
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
) const

Returns the build table indices that can be used to construct the result of performing a left join between two tables.

Note
For a given row index i of the probe table, the resulting build_indices[i] contains the row index of the matched row from the build table if there is a match. Otherwise, contains JoinNoneValue.
Parameters
probeThe probe table, from which the keys are probed
streamCUDA stream used for device memory operations and kernel launches
mrDevice memory resource used to allocate the returned table and columns' device memory.
Returns
A build_indices column that can be used to construct the result of performing a left join between two tables with build and probe as the join keys.

The documentation for this class was generated from the following file: