Avro#

class pylibcudf.io.avro.AvroReaderOptions#

用于 read_avro 的设置。详情请参阅 cudf::io::avro_reader_options

方法

builder(SourceInfo source)

创建一个 AvroReaderOptionsBuilder 对象

set_columns(self, list col_names)

设置要读取的列的名称。

static builder(SourceInfo source)#

创建一个 AvroReaderOptionsBuilder 对象

详情请参阅 cudf::io::avro_reader_options::builder()

参数:
sourceSourceInfo

用于读取 Avro 文件的源。

返回:
AvroReaderOptionsBuilder

用于构建 AvroReaderOptions 的构建器

set_columns(self, list col_names) void#

设置要读取的列的名称。

参数:
col_nameslist[str]

列名列表

返回:
None
pylibcudf.io.avro.read_avro(AvroReaderOptions options, Stream stream=None) TableWithMetadata#

从 Avro 格式读取。

要读取的源和选项封装在 options 对象中。

详情请参阅 read_avro()

参数:
options: AvroReaderOptions

控制读取行为的设置

stream: Stream

用于设备内存操作和内核启动的 CUDA 流