文件 | | 枚举成员 | 函数
连接 (Joining)

文件

文件  join.hpp
 

类  cudf::hash_join
 哈希连接 (Hash join) 在创建时构建哈希表,并在随后的 `*_join` 成员函数中探测结果。 更多...
 
类  cudf::distinct_hash_join
 去重哈希连接 (Distinct hash join) 在创建时构建哈希表,并在随后的 `*_join` 成员函数中探测结果。 更多...
 

枚举

枚举类  cudf::nullable_join : bool { YES , NO }
 用于指定任何输入连接表(`build` 表和任何后续的 `probe` 表)是否包含空值的枚举类。 更多...
 

函数

std::pair< std::unique_ptr< rmm::device_uvector< size_type > >, std::unique_ptr< rmm::device_uvector< size_type > > > cudf::inner_join (cudf::table_view const &left_keys, cudf::table_view const &right_keys, null_equality compare_nulls=null_equality::EQUAL, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 返回对应于指定表之间的内连接的行索引向量对。 更多...
 
std::pair< std::unique_ptr< rmm::device_uvector< size_type > >, std::unique_ptr< rmm::device_uvector< size_type > > > cudf::left_join (cudf::table_view const &left_keys, cudf::table_view const &right_keys, null_equality compare_nulls=null_equality::EQUAL, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 返回对应于指定表之间左连接的行索引向量对。 更多...
 
std::pair< std::unique_ptr< rmm::device_uvector< size_type > >, std::unique_ptr< rmm::device_uvector< size_type > > > cudf::full_join (cudf::table_view const &left_keys, cudf::table_view const &right_keys, null_equality compare_nulls=null_equality::EQUAL, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 返回对应于指定表之间全连接的行索引向量对。 更多...
 
std::unique_ptr< rmm::device_uvector< size_type > > cudf::left_semi_join (cudf::table_view const &left_keys, cudf::table_view const &right_keys, null_equality compare_nulls=null_equality::EQUAL, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 返回对应于指定表之间左半连接的行索引向量。 更多...
 
std::unique_ptr< rmm::device_uvector< size_type > > cudf::left_anti_join (cudf::table_view const &left_keys, cudf::table_view const &right_keys, null_equality compare_nulls=null_equality::EQUAL, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 返回对应于指定表之间左反连接的行索引向量。 更多...
 
std::unique_ptr< cudf::tablecudf::cross_join (cudf::table_view const &left, cudf::table_view const &right, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 对两个表(`left`,`right`)执行交叉连接。 更多...
 
std::pair< std::unique_ptr< rmm::device_uvector< size_type > >, std::unique_ptr< rmm::device_uvector< size_type > > > cudf::conditional_inner_join (table_view const &left, table_view const &right, ast::expression const &binary_predicate, std::optional< std::size_t > output_size={}, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 返回对应于指定表之间所有行对的行索引向量对,其中谓词评估为真。 更多...
 
std::pair< std::unique_ptr< rmm::device_uvector< size_type > >, std::unique_ptr< rmm::device_uvector< size_type > > > cudf::conditional_left_join (table_view const &left, table_view const &right, ast::expression const &binary_predicate, std::optional< std::size_t > output_size={}, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 返回对应于指定表之间所有行对的行索引向量对,其中谓词评估为真;或者对于在右表中没有匹配行的左表中的行,返回空匹配项。 更多...
 
std::pair< std::unique_ptr< rmm::device_uvector< size_type > >, std::unique_ptr< rmm::device_uvector< size_type > > > cudf::conditional_full_join (table_view const &left, table_view const &right, ast::expression const &binary_predicate, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 返回对应于指定表之间所有行对的行索引向量对,其中谓词评估为真;或者对于在另一表中没有匹配行的任一表中的行,返回空匹配项。 更多...
 
std::unique_ptr< rmm::device_uvector< size_type > > cudf::conditional_left_semi_join (table_view const &left, table_view const &right, ast::expression const &binary_predicate, std::optional< std::size_t > output_size={}, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 返回对应于左表中所有行的索引向量,这些行在右表中存在某个谓词评估为真的行。 更多...
 
std::unique_ptr< rmm::device_uvector< size_type > > cudf::conditional_left_anti_join (table_view const &left, table_view const &right, ast::expression const &binary_predicate, std::optional< std::size_t > output_size={}, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 返回对应于左表中所有行的索引向量,这些行在右表中不存在任何谓词评估为真的行。 更多...
 
std::pair< std::unique_ptr< rmm::device_uvector< size_type > >, std::unique_ptr< rmm::device_uvector< size_type > > > cudf::mixed_inner_join (table_view const &left_equality, table_view const &right_equality, table_view const &left_conditional, table_view const &right_conditional, ast::expression const &binary_predicate, null_equality compare_nulls=null_equality::EQUAL, std::optional< std::pair< std::size_t, device_span< size_type const >>> output_size_data={}, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 返回对应于指定表之间所有行对的行索引向量对,其中等值表的列相等且谓词在条件表上评估为真。 更多...
 
std::pair< std::unique_ptr< rmm::device_uvector< size_type > >, std::unique_ptr< rmm::device_uvector< size_type > > > cudf::mixed_left_join (table_view const &left_equality, table_view const &right_equality, table_view const &left_conditional, table_view const &right_conditional, ast::expression const &binary_predicate, null_equality compare_nulls=null_equality::EQUAL, std::optional< std::pair< std::size_t, device_span< size_type const >>> output_size_data={}, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 返回对应于指定表之间所有行对的行索引向量对,其中等值表的列相等且谓词在条件表上评估为真;或者对于在右表中没有匹配项的左表中的行,返回空匹配项。 更多...
 
std::pair< std::unique_ptr< rmm::device_uvector< size_type > >, std::unique_ptr< rmm::device_uvector< size_type > > > cudf::mixed_full_join (table_view const &left_equality, table_view const &right_equality, table_view const &left_conditional, table_view const &right_conditional, ast::expression const &binary_predicate, null_equality compare_nulls=null_equality::EQUAL, std::optional< std::pair< std::size_t, device_span< size_type const >>> output_size_data={}, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 返回对应于指定表之间所有行对的行索引向量对,其中等值表的列相等且谓词在条件表上评估为真;或者对于在另一对表中没有匹配项的任一对表中的行,返回空匹配项。 更多...
 
std::unique_ptr< rmm::device_uvector< size_type > > cudf::mixed_left_semi_join (table_view const &left_equality, table_view const &right_equality, table_view const &left_conditional, table_view const &right_conditional, ast::expression const &binary_predicate, null_equality compare_nulls=null_equality::EQUAL, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 返回对应于左表中所有行的索引向量,其中等值表的列相等且谓词在条件表上评估为真。 更多...
 
std::unique_ptr< rmm::device_uvector< size_type > > cudf::mixed_left_anti_join (table_view const &left_equality, table_view const &right_equality, table_view const &left_conditional, table_view const &right_conditional, ast::expression const &binary_predicate, null_equality compare_nulls=null_equality::EQUAL, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 返回对应于左表中所有行的索引向量,这些行在右表中不存在任何行,其中等值表的列相等且谓词在条件表上评估为真。 更多...
 
std::pair< std::size_t, std::unique_ptr< rmm::device_uvector< size_type > > > cudf::mixed_inner_join_size (table_view const &left_equality, table_view const &right_equality, table_view const &left_conditional, table_view const &right_conditional, ast::expression const &binary_predicate, null_equality compare_nulls=null_equality::EQUAL, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 执行混合内连接时返回精确的匹配数(行数),其中等值表的列相等且谓词在条件表上评估为真。 更多...
 
std::pair< std::size_t, std::unique_ptr< rmm::device_uvector< size_type > > > cudf::mixed_left_join_size (table_view const &left_equality, table_view const &right_equality, table_view const &left_conditional, table_view const &right_conditional, ast::expression const &binary_predicate, null_equality compare_nulls=null_equality::EQUAL, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 执行混合左连接时返回精确的匹配数(行数),其中等值表的列相等且谓词在条件表上评估为真。 更多...
 
std::size_t cudf::conditional_inner_join_size (table_view const &left, table_view const &right, ast::expression const &binary_predicate, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 执行条件内连接时返回精确的匹配数(行数),其中谓词评估为真。 更多...
 
std::size_t cudf::conditional_left_join_size (table_view const &left, table_view const &right, ast::expression const &binary_predicate, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 执行条件左连接时返回精确的匹配数(行数),其中谓词评估为真。 更多...
 
std::size_t cudf::conditional_left_semi_join_size (table_view const &left, table_view const &right, ast::expression const &binary_predicate, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 执行条件左半连接时返回精确的匹配数(行数),其中谓词评估为真。 更多...
 
std::size_t cudf::conditional_left_anti_join_size (table_view const &left, table_view const &right, ast::expression const &binary_predicate, rmm::cuda_stream_view stream=cudf::get_default_stream(), rmm::device_async_resource_ref mr=cudf::get_current_device_resource_ref())
 执行条件左反连接时返回精确的匹配数(行数),其中谓词评估为真。 更多...
 

详细描述

枚举类型文档

◆ nullable_join

枚举 cudf::nullable_join : bool
strong

用于指定任何输入连接表(`build` 表和任何后续的 `probe` 表)是否包含空值的枚举类。

这在 hash_join 对象构建时使用,用于指定所有可能的输入表中空值的存在。如果空值是否存在未知,应使用 `YES` 作为默认选项。

在文件 join.hpp290 行定义。

函数文档

◆ conditional_full_join()

std::pair<std::unique_ptr<rmm::device_uvector<size_type> >, std::unique_ptr<rmm::device_uvector<size_type> > > cudf::conditional_full_join ( table_view const &  left,
table_view const &  right,
ast::expression const &  binary_predicate,
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

返回对应于指定表之间所有行对的行索引向量对,其中谓词评估为真;或者对于在另一表中没有匹配行的任一表中的行,返回空匹配项。

返回的向量对中的值按对考虑,为以下之一:(1) 对应于左右表中匹配行的行索引,(2) 一个行索引和一个未指定的越界值,表示一个表中的行在另一个表中没有匹配项。

如果提供的谓词对一对行(左,右)返回 NULL,则该对不包含在输出中。

左表: {{0, 1, 2}}
右表: {{1, 2, 3}}
表达式: Left.Column_0 == Right.Column_0
结果: {{0, 1, 2, None}, {None, 0, 1, 2}}
左表: {{0, 1, 2}, {3, 4, 5}}
右表: {{1, 2, 3}, {4, 6, 7}}
表达式: (Left.Column_0 == Right.Column_0) AND (Left.Column_1 == Right.Column_1)
结果: {{0, 1, 2, None, None}, {None, 0, None, 1, 2}}
异常
cudf::data_type_error如果二元谓词输出非布尔结果。
参数
left左表
right右表
binary_predicate连接的条件
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
一个向量对 [`left_indices`, `right_indices`],可用于构建在两个表 `left` 和 `right` 之间执行条件全连接的结果。

◆ conditional_inner_join()

std::pair<std::unique_ptr<rmm::device_uvector<size_type> >, std::unique_ptr<rmm::device_uvector<size_type> > > cudf::conditional_inner_join ( table_view const &  left,
table_view const &  right,
ast::expression const &  binary_predicate,
std::optional< std::size_t >  output_size = {},
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

返回对应于指定表之间所有行对的行索引向量对,其中谓词评估为真。

返回的第一个向量包含在右表中有匹配项的左表的行索引(顺序不确定)。返回的第二个向量中对应的值是右表中匹配的行索引。

如果提供的谓词对一对行(左,右)返回 NULL,则该对不包含在输出中。

左表: {{0, 1, 2}}
右表: {{1, 2, 3}}
表达式: Left.Column_0 == Right.Column_0
结果: {{1, 2}, {0, 1}}
左表: {{0, 1, 2}, {3, 4, 5}}
右表: {{1, 2, 3}, {4, 6, 7}}
表达式: (Left.Column_0 == Right.Column_0) AND (Left.Column_1 == Right.Column_1)
结果: {{1}, {0}}
异常
cudf::data_type_error如果二元谓词输出非布尔结果。
参数
left左表
right右表
binary_predicate连接的条件
output_size可选值,允许用户指定精确的输出大小
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
一个向量对 [`left_indices`, `right_indices`],可用于构建在两个表 `left` 和 `right` 之间执行条件内连接的结果。

◆ conditional_inner_join_size()

std::size_t cudf::conditional_inner_join_size ( table_view const &  left,
table_view const &  right,
ast::expression const &  binary_predicate,
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

执行条件内连接时返回精确的匹配数(行数),其中谓词评估为真。

如果提供的谓词对一对行(左,右)返回 NULL,则该对不包含在输出中。

异常
cudf::data_type_error如果二元谓词输出非布尔结果。
参数
left左表
right右表
binary_predicate连接的条件
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
执行所请求的连接将产生的行数

◆ conditional_left_anti_join()

std::unique_ptr<rmm::device_uvector<size_type> > cudf::conditional_left_anti_join ( table_view const &  left,
table_view const &  right,
ast::expression const &  binary_predicate,
std::optional< std::size_t >  output_size = {},
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

返回对应于左表中所有行的索引向量,这些行在右表中不存在任何谓词评估为真的行。

如果提供的谓词对一对行(左,右)返回 NULL,则该对不包含在输出中。

左表: {{0, 1, 2}}
右表: {{1, 2, 3}}
表达式: Left.Column_0 == Right.Column_0
结果: {0}
左表: {{0, 1, 2}, {3, 4, 5}}
右表: {{1, 2, 3}, {4, 6, 7}}
表达式: (Left.Column_0 == Right.Column_0) AND (Left.Column_1 == Right.Column_1)
结果: {0, 2}
异常
cudf::data_type_error如果二元谓词输出非布尔结果。
参数
left左表
right右表
binary_predicate连接的条件
output_size可选值,允许用户指定精确的输出大小
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
一个向量 `left_indices`,可用于构建在两个表 `left` 和 `right` 之间执行条件左反连接的结果。

◆ conditional_left_anti_join_size()

std::size_t cudf::conditional_left_anti_join_size ( table_view const &  left,
table_view const &  right,
ast::expression const &  binary_predicate,
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

执行条件左反连接时返回精确的匹配数(行数),其中谓词评估为真。

如果提供的谓词对一对行(左,右)返回 NULL,则该对不包含在输出中。

异常
cudf::data_type_error如果二元谓词输出非布尔结果。
参数
left左表
right右表
binary_predicate连接的条件
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
执行所请求的连接将产生的行数

◆ conditional_left_join()

std::pair<std::unique_ptr<rmm::device_uvector<size_type> >, std::unique_ptr<rmm::device_uvector<size_type> > > cudf::conditional_left_join ( table_view const &  left,
table_view const &  right,
ast::expression const &  binary_predicate,
std::optional< std::size_t >  output_size = {},
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

返回对应于指定表之间所有行对的行索引向量对,其中谓词评估为真;或者对于在右表中没有匹配行的左表中的行,返回空匹配项。

返回的第一个向量包含左表中的所有行索引(顺序不确定)。返回的第二个向量中对应的值是 (1) 右表中匹配行的行索引(如果存在匹配项),或者 (2) 未指定的越界值。

如果提供的谓词对一对行(左,右)返回 NULL,则该对不包含在输出中。

左表: {{0, 1, 2}}
右表: {{1, 2, 3}}
表达式: Left.Column_0 == Right.Column_0
结果: {{0, 1, 2}, {None, 0, 1}}
左表: {{0, 1, 2}, {3, 4, 5}}
右表: {{1, 2, 3}, {4, 6, 7}}
表达式: (Left.Column_0 == Right.Column_0) AND (Left.Column_1 == Right.Column_1)
结果: {{0, 1, 2}, {None, 0, None}}
异常
cudf::data_type_error如果二元谓词输出非布尔结果。
参数
left左表
right右表
binary_predicate连接的条件
output_size可选值,允许用户指定精确的输出大小
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
一个向量对 [`left_indices`, `right_indices`],可用于构建在两个表 `left` 和 `right` 之间执行条件左连接的结果。

◆ conditional_left_join_size()

std::size_t cudf::conditional_left_join_size ( table_view const &  left,
table_view const &  right,
ast::expression const &  binary_predicate,
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

执行条件左连接时返回精确的匹配数(行数),其中谓词评估为真。

如果提供的谓词对一对行(左,右)返回 NULL,则该对不包含在输出中。

异常
cudf::data_type_error如果二元谓词输出非布尔结果。
参数
left左表
right右表
binary_predicate连接的条件
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
执行所请求的连接将产生的行数

◆ conditional_left_semi_join()

std::unique_ptr<rmm::device_uvector<size_type> > cudf::conditional_left_semi_join ( table_view const &  left,
table_view const &  right,
ast::expression const &  binary_predicate,
std::optional< std::size_t >  output_size = {},
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

返回对应于左表中所有行的索引向量,这些行在右表中存在某个谓词评估为真的行。

如果提供的谓词对一对行(左,右)返回 NULL,则该对不包含在输出中。

左表: {{0, 1, 2}}
右表: {{1, 2, 3}}
表达式: Left.Column_0 == Right.Column_0
结果: {1, 2}
左表: {{0, 1, 2}, {3, 4, 5}}
右表: {{1, 2, 3}, {4, 6, 7}}
表达式: (Left.Column_0 == Right.Column_0) AND (Left.Column_1 == Right.Column_1)
结果: {1}
异常
cudf::data_type_error如果二元谓词输出非布尔结果。
参数
left左表
right右表
binary_predicate连接的条件
output_size可选值,允许用户指定精确的输出大小
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
一个向量 `left_indices`,可用于构建在两个表 `left` 和 `right` 之间执行条件左半连接的结果。

◆ conditional_left_semi_join_size()

std::size_t cudf::conditional_left_semi_join_size ( table_view const &  left,
table_view const &  right,
ast::expression const &  binary_predicate,
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

执行条件左半连接时返回精确的匹配数(行数),其中谓词评估为真。

如果提供的谓词对一对行(左,右)返回 NULL,则该对不包含在输出中。

异常
cudf::data_type_error如果二元谓词输出非布尔结果。
参数
left左表
right右表
binary_predicate连接的条件
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
执行所请求的连接将产生的行数

◆ cross_join()

std::unique_ptr<cudf::table> cudf::cross_join ( cudf::table_view const &  left,
cudf::table_view const &  right,
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

对两个表(`left`,`right`)执行交叉连接

交叉连接返回每个表中行的笛卡尔积。

注意
警告:此函数容易导致内存不足错误。输出的大小等于 `left.num_rows() * right.num_rows()`。请谨慎使用。
左表 a: {0, 1, 2}
右表 b: {3, 4, 5}
结果: { a: {0, 0, 0, 1, 1, 1, 2, 2, 2}, b: {3, 4, 5, 3, 4, 5, 3, 4, 5} }
异常
cudf::logic_error如果 `left` 或 `right` 表中的列数为 0
参数
left左表
right右表
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表的设备内存的设备内存资源
返回
交叉连接 `left` 和 `right` 表的结果

◆ full_join()

std::pair<std::unique_ptr<rmm::device_uvector<size_type> >, std::unique_ptr<rmm::device_uvector<size_type> > > cudf::full_join ( cudf::table_view const &  left_keys,
cudf::table_view const &  right_keys,
null_equality  compare_nulls = null_equality::EQUAL,
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

返回对应于指定表之间全连接的行索引向量对。

返回的向量对中的值按对考虑,为以下之一:(1) 对应于左右表中匹配行的行索引,(2) 一个行索引和一个未指定的越界值,表示一个表中的行在另一个表中没有匹配项。

左表: {{0, 1, 2}}
右表: {{1, 2, 3}}
结果: {{0, 1, 2, None}, {None, 0, 1, 2}}
左表: {{0, 1, 2}, {3, 4, 5}}
右表: {{1, 2, 3}, {4, 6, 7}}
结果: {{0, 1, 2, None, None}, {None, 0, None, 1, 2}}
异常
cudf::logic_error如果 `left_keys` 或 `right_keys` 中的元素数量不匹配。
参数
[in]left_keys左表
[in]right_keys右表
[in]compare_nulls控制空连接键值是否匹配。
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
一个向量对 [`left_indices`, `right_indices`],可用于构建在两个以 `left_keys` 和 `right_keys` 作为连接键的表之间执行全连接的结果。

◆ inner_join()

std::pair<std::unique_ptr<rmm::device_uvector<size_type> >, std::unique_ptr<rmm::device_uvector<size_type> > > cudf::inner_join ( cudf::table_view const &  left_keys,
cudf::table_view const &  right_keys,
null_equality  compare_nulls = null_equality::EQUAL,
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

返回对应于指定表之间内连接的行索引向量对。

返回的第一个向量包含在右表中有匹配项的左表的行索引(顺序不确定)。返回的第二个向量中对应的值是右表中匹配的行索引。

左表: {{0, 1, 2}}
右表: {{1, 2, 3}}
结果: {{1, 2}, {0, 1}}
左表: {{0, 1, 2}, {3, 4, 5}}
右表: {{1, 2, 3}, {4, 6, 7}}
结果: {{1}, {0}}
异常
cudf::logic_error如果 `left_keys` 或 `right_keys` 中的元素数量不匹配。
参数
[in]left_keys左表
[in]right_keys右表
[in]compare_nulls控制空连接键值是否匹配。
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
一个向量对 [`left_indices`, `right_indices`],可用于构建在两个以 `left_keys` 和 `right_keys` 作为连接键的表之间执行内连接的结果。

◆ left_anti_join()

std::unique_ptr<rmm::device_uvector<size_type> > cudf::left_anti_join ( cudf::table_view const &  left_keys,
cudf::table_view const &  right_keys,
null_equality  compare_nulls = null_equality::EQUAL,
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

返回对应于指定表之间左反连接的行索引向量。

返回的向量包含在右表中没有匹配行的左表的行索引。

表A: {{0, 1, 2}}
表B: {{1, 2, 3}}
结果: {0}
异常
cudf::logic_error如果 `left_keys` 或 `right_keys` 中的列数为 0
参数
[in]left_keys左表
[in]right_keys右表
[in]compare_nulls控制空连接键值是否匹配。
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
一个列 `left_indices`,可用于构建在两个以 `left_keys` 和 `right_keys` 作为连接键的表之间执行左反连接的结果。

◆ left_join()

std::pair<std::unique_ptr<rmm::device_uvector<size_type> >, std::unique_ptr<rmm::device_uvector<size_type> > > cudf::left_join ( cudf::table_view const &  left_keys,
cudf::table_view const &  right_keys,
null_equality  compare_nulls = null_equality::EQUAL,
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

返回对应于指定表之间左连接的行索引向量对。

返回的第一个向量包含左表中的所有行索引(顺序不确定)。返回的第二个向量中对应的值是 (1) 右表中匹配行的行索引(如果存在匹配项),或者 (2) 未指定的越界值。

左表: {{0, 1, 2}}
右表: {{1, 2, 3}}
结果: {{0, 1, 2}, {None, 0, 1}}
左表: {{0, 1, 2}, {3, 4, 5}}
右表: {{1, 2, 3}, {4, 6, 7}}
结果: {{0, 1, 2}, {None, 0, None}}
异常
cudf::logic_error如果 `left_keys` 或 `right_keys` 中的元素数量不匹配。
参数
[in]left_keys左表
[in]right_keys右表
[in]compare_nulls控制空连接键值是否匹配。
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
一个向量对 [`left_indices`, `right_indices`],可用于构建在两个以 `left_keys` 和 `right_keys` 作为连接键的表之间执行左连接的结果。

◆ left_semi_join()

std::unique_ptr<rmm::device_uvector<size_type> > cudf::left_semi_join ( cudf::table_view const &  left_keys,
cudf::table_view const &  right_keys,
null_equality  compare_nulls = null_equality::EQUAL,
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

返回对应于指定表之间左半连接的行索引向量。

返回的向量包含在右表中有匹配行的左表的行索引。

表A: {{0, 1, 2}}
表B: {{1, 2, 3}}
结果: {1, 2}
参数
left_keys左表
right_keys右表
compare_nulls控制空连接键值是否匹配
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
一个向量 `left_indices`,可用于构建在两个以 `left_keys` 和 `right_keys` 作为连接键的表之间执行左半连接的结果。

◆ mixed_full_join()

std::pair<std::unique_ptr<rmm::device_uvector<size_type> >, std::unique_ptr<rmm::device_uvector<size_type> > > cudf::mixed_full_join ( table_view const &  left_equality,
table_view const &  right_equality,
table_view const &  left_conditional,
table_view const &  right_conditional,
ast::expression const &  binary_predicate,
null_equality  compare_nulls = null_equality::EQUAL,
std::optional< std::pair< std::size_t, device_span< size_type const >>>  output_size_data = {},
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

返回对应于指定表之间所有行对的行索引向量对,其中等值表的列相等且谓词在条件表上评估为真;或者对于在另一对表中没有匹配项的任一对表中的行,返回空匹配项。

返回的向量对中的值按对考虑,为以下之一:(1) 对应于左右表中匹配行的行索引,(2) 一个行索引和一个未指定的越界值,表示一个表中的行在另一个表中没有匹配项。

如果提供的谓词对一对行(左,右)返回 NULL,则该对不包含在输出中。用户有责任选择合适的 compare_nulls 值并在表达式中使用合适的空安全运算符。

如果提供的输出大小或每行计数不正确,则行为未定义。

left_equality: {{0, 1, 2}}
right_equality: {{1, 2, 3}}
left_conditional: {{4, 4, 4}}
right_conditional: {{3, 4, 5}}
表达式: Left.Column_0 > Right.Column_0
结果: {{0, 1, 2, None, None}, {None, 0, None, 1, 2}}
异常
cudf::data_type_error如果二元谓词输出非布尔结果。
cudf::logic_error如果 left_equality 和 left_conditional 中的行数不匹配。
cudf::logic_error如果 right_equality 和 right_conditional 中的行数不匹配。
参数
left_equality用于等值连接的左表
right_equality用于等值连接的右表
left_conditional用于条件连接的左表
right_conditional用于条件连接的右表
binary_predicate连接的条件
compare_nulls空值是否相互连接
output_size_data一对可选值,指示精确的输出大小和两个输入表中较大者(左或右)中每行的匹配数(可使用相应的 mixed_full_join_size API 预先计算)。
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
一个向量对 [`left_indices`, `right_indices`],可用于构建在四个输入表之间执行混合全连接的结果。

◆ mixed_inner_join()

std::pair<std::unique_ptr<rmm::device_uvector<size_type> >, std::unique_ptr<rmm::device_uvector<size_type> > > cudf::mixed_inner_join ( table_view const &  left_equality,
table_view const &  right_equality,
table_view const &  left_conditional,
table_view const &  right_conditional,
ast::expression const &  binary_predicate,
null_equality  compare_nulls = null_equality::EQUAL,
std::optional< std::pair< std::size_t, device_span< size_type const >>>  output_size_data = {},
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

返回对应于指定表之间所有行对的行索引向量对,其中等值表的列相等且谓词在条件表上评估为真。

返回的第一个向量包含在右表中有匹配项的左表的行索引(顺序不确定)。返回的第二个向量中对应的值是右表中匹配的行索引。

如果提供的谓词对一对行(左,右)返回 NULL,则该对不包含在输出中。用户有责任选择合适的 compare_nulls 值并在表达式中使用合适的空安全运算符。

如果提供的输出大小或每行计数不正确,则行为未定义。

left_equality: {{0, 1, 2}}
right_equality: {{1, 2, 3}}
left_conditional: {{4, 4, 4}}
right_conditional: {{3, 4, 5}}
表达式: Left.Column_0 > Right.Column_0
结果: {{1}, {0}}
异常
cudf::data_type_error如果二元谓词输出非布尔结果。
cudf::logic_error如果 left_equality 和 left_conditional 中的行数不匹配。
cudf::logic_error如果 right_equality 和 right_conditional 中的行数不匹配。
参数
left_equality用于等值连接的左表
right_equality用于等值连接的右表
left_conditional用于条件连接的左表
right_conditional用于条件连接的右表
binary_predicate连接的条件
compare_nulls空值是否相互连接
output_size_data一对可选值,指示精确的输出大小和两个输入表中较大者(左或右)中每行的匹配数(可使用相应的 mixed_inner_join_size API 预先计算)。
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
一个向量对 [`left_indices`, `right_indices`],可用于构建在四个输入表之间执行混合内连接的结果。

◆ mixed_inner_join_size()

std::pair<std::size_t, std::unique_ptr<rmm::device_uvector<size_type> > > cudf::mixed_inner_join_size ( table_view const &  left_equality,
table_view const &  right_equality,
table_view const &  left_conditional,
table_view const &  right_conditional,
ast::expression const &  binary_predicate,
null_equality  compare_nulls = null_equality::EQUAL,
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

执行混合内连接时返回精确的匹配数(行数),其中等值表的列相等且谓词在条件表上评估为真。

如果提供的谓词对一对行(左,右)返回 NULL,则该对不包含在输出中。用户有责任选择合适的 compare_nulls 值并在表达式中使用合适的空安全运算符。

异常
cudf::data_type_error如果二元谓词输出非布尔结果。
cudf::logic_error如果 left_equality 和 left_conditional 中的行数不匹配。
cudf::logic_error如果 right_equality 和 right_conditional 中的行数不匹配。
参数
left_equality用于等值连接的左表
right_equality用于等值连接的右表
left_conditional用于条件连接的左表
right_conditional用于条件连接的右表
binary_predicate连接的条件
compare_nulls空值是否相互连接
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
包含执行所请求的连接将产生的行数以及两个表中其中一个表中每行的匹配数对。哪个表是实现细节,不应依赖,只需将其原样传递给相应的 `mixed_inner_join` API。

◆ mixed_left_anti_join()

std::unique_ptr<rmm::device_uvector<size_type> > cudf::mixed_left_anti_join ( table_view const &  left_equality,
table_view const &  right_equality,
table_view const &  left_conditional,
table_view const &  right_conditional,
ast::expression const &  binary_predicate,
null_equality  compare_nulls = null_equality::EQUAL,
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

返回对应于左表中所有行的索引向量,这些行在右表中不存在任何行,其中等值表的列相等且谓词在条件表上评估为真。

如果提供的谓词对一对行(左,右)返回 NULL,则左行不包含在输出中。用户有责任选择合适的 compare_nulls 值并在表达式中使用合适的空安全运算符。

如果提供的输出大小或每行计数不正确,则行为未定义。

left_equality: {{0, 1, 2}}
right_equality: {{1, 2, 3}}
left_conditional: {{4, 4, 4}}
right_conditional: {{3, 4, 5}}
表达式: Left.Column_0 > Right.Column_0
结果: {0, 2}
异常
cudf::data_type_error如果二元谓词输出非布尔结果。
cudf::logic_error如果 left_equality 和 left_conditional 中的行数不匹配。
cudf::logic_error如果 right_equality 和 right_conditional 中的行数不匹配。
参数
left_equality用于等值连接的左表
right_equality用于等值连接的右表
left_conditional用于条件连接的左表
right_conditional用于条件连接的右表
binary_predicate连接的条件
compare_nulls空值是否相互连接
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
一个向量对 [`left_indices`, `right_indices`],可用于构建在四个输入表之间执行混合全连接的结果。

◆ mixed_left_join()

std::pair<std::unique_ptr<rmm::device_uvector<size_type> >, std::unique_ptr<rmm::device_uvector<size_type> > > cudf::mixed_left_join ( table_view const &  left_equality,
table_view const &  right_equality,
table_view const &  left_conditional,
table_view const &  right_conditional,
ast::expression const &  binary_predicate,
null_equality  compare_nulls = null_equality::EQUAL,
std::optional< std::pair< std::size_t, device_span< size_type const >>>  output_size_data = {},
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

返回对应于指定表之间所有行对的行索引向量对,其中等值表的列相等且谓词在条件表上评估为真;或者对于在右表中没有匹配项的左表中的行,返回空匹配项。

返回的第一个向量包含在右表中有匹配项的左表的行索引(顺序不确定)。返回的第二个向量中对应的值是 (1) 右表中匹配行的行索引,或者 (2) 未指定的越界值。

如果提供的谓词对一对行(左,右)返回 NULL,则该对不包含在输出中。用户有责任选择合适的 compare_nulls 值并在表达式中使用合适的空安全运算符。

如果提供的输出大小或每行计数不正确,则行为未定义。

left_equality: {{0, 1, 2}}
right_equality: {{1, 2, 3}}
left_conditional: {{4, 4, 4}}
right_conditional: {{3, 4, 5}}
表达式: Left.Column_0 > Right.Column_0
结果: {{0, 1, 2}, {None, 0, None}}
异常
cudf::data_type_error如果二元谓词输出非布尔结果。
cudf::logic_error如果 left_equality 和 left_conditional 中的行数不匹配。
cudf::logic_error如果 right_equality 和 right_conditional 中的行数不匹配。
参数
left_equality用于等值连接的左表
right_equality用于等值连接的右表
left_conditional用于条件连接的左表
right_conditional用于条件连接的右表
binary_predicate连接的条件
compare_nulls空值是否相互连接
output_size_data一对可选值,指示精确的输出大小和两个输入表中较大者(左或右)中每行的匹配数(可使用相应的 mixed_left_join_size API 预先计算)。
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
一个向量对 [`left_indices`, `right_indices`],可用于构建在四个输入表之间执行混合左连接的结果。

◆ mixed_left_join_size()

std::pair<std::size_t, std::unique_ptr<rmm::device_uvector<size_type> > > cudf::mixed_left_join_size ( table_view const &  left_equality,
table_view const &  right_equality,
table_view const &  left_conditional,
table_view const &  right_conditional,
ast::expression const &  binary_predicate,
null_equality  compare_nulls = null_equality::EQUAL,
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

执行混合左连接时返回精确的匹配数(行数),其中等值表的列相等且谓词在条件表上评估为真。

如果提供的谓词对一对行(左,右)返回 NULL,则该对不包含在输出中。用户有责任选择合适的 compare_nulls 值并在表达式中使用合适的空安全运算符。

异常
cudf::data_type_error如果二元谓词输出非布尔结果。
cudf::logic_error如果 left_equality 和 left_conditional 中的行数不匹配。
cudf::logic_error如果 right_equality 和 right_conditional 中的行数不匹配。
参数
left_equality用于等值连接的左表
right_equality用于等值连接的右表
left_conditional用于条件连接的左表
right_conditional用于条件连接的右表
binary_predicate连接的条件
compare_nulls空值是否相互连接
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
包含执行所请求的连接将产生的行数以及两个表中其中一个表中每行的匹配数对。哪个表是实现细节,不应依赖,只需将其原样传递给相应的 `mixed_left_join` API。

◆ mixed_left_semi_join()

std::unique_ptr<rmm::device_uvector<size_type> > cudf::mixed_left_semi_join ( table_view const &  left_equality,
table_view const &  right_equality,
table_view const &  left_conditional,
table_view const &  right_conditional,
ast::expression const &  binary_predicate,
null_equality  compare_nulls = null_equality::EQUAL,
rmm::cuda_stream_view  stream = cudf::get_default_stream(),
rmm::device_async_resource_ref  mr = cudf::get_current_device_resource_ref() 
)

返回对应于左表中所有行的索引向量,其中等值表的列相等且谓词在条件表上评估为真。

如果提供的谓词对一对行(左,右)返回 NULL,则左行不包含在输出中。用户有责任选择合适的 compare_nulls 值并在表达式中使用合适的空安全运算符。

如果提供的输出大小或每行计数不正确,则行为未定义。

left_equality: {{0, 1, 2}}
right_equality: {{1, 2, 3}}
left_conditional: {{4, 4, 4}}
right_conditional: {{3, 4, 5}}
表达式: Left.Column_0 > Right.Column_0
结果: {1}
异常
cudf::data_type_error如果二元谓词输出非布尔结果。
cudf::logic_error如果 left_equality 和 left_conditional 中的行数不匹配。
cudf::logic_error如果 right_equality 和 right_conditional 中的行数不匹配。
参数
left_equality用于等值连接的左表
right_equality用于等值连接的右表
left_conditional用于条件连接的左表
right_conditional用于条件连接的右表
binary_predicate连接的条件
compare_nulls空值是否相互连接
stream用于设备内存操作和内核启动的 CUDA 流
mr用于分配返回的表和列的设备内存的设备内存资源
返回
一个向量对 [`left_indices`, `right_indices`],可用于构建在四个输入表之间执行混合全连接的结果。