types¶
arro3.core.types ¶
ArrayInput
module-attribute
¶
ArrayInput = Union[ArrowArrayExportable, Buffer]
Accepted input as an Arrow array.
Buffer protocol input (such as numpy arrays) will be interpreted zero-copy except in the case of boolean-typed input, which must be copied to the Arrow format.
ArrowArrayExportable ¶
Bases: Protocol
An object with an __arrow_c_array__ method implementing the Arrow C Data Interface
interface via the
Arrow PyCapsule
Interface.
Such objects include:
- arro3
ArrayorRecordBatchobjects. - pyarrow
ArrayorRecordBatchobjects
This allows for zero-copy Arrow data interchange across libraries.
ArrowSchemaExportable ¶
Bases: Protocol
An object with an __arrow_c_schema__ method implementing the Arrow C Data Interface
interface via the
Arrow PyCapsule
Interface.
Such objects include:
This allows for zero-copy Arrow data interchange across libraries.
ArrowStreamExportable ¶
Bases: Protocol
An object with an __arrow_c_stream__ method implementing the Arrow C Stream
interface via the
Arrow PyCapsule
Interface.
Supported objects include:
- arro3
Table,RecordBatchReader,ChunkedArray, orArrayReaderobjects. - Polars
SeriesorDataFrameobjects (polars v1.2 or higher) - DuckDB table-like objects, such as
DuckDBPyRelationorDuckDBPyConnection. - pyarrow
RecordBatchReader,Table, orChunkedArrayobjects (pyarrow v14 or higher) - pandas
DataFrames (pandas v2.2 or higher) - ibis
Tableobjects.
This allows for zero-copy Arrow data interchange across libraries.
For an up to date list of supported objects, see this issue.