Skip to content

GeoTable

geoarrow.rust.core

GeoTable

A spatially-enabled table.

This is a table, or DataFrame, consisting of named columns with the same length. One of these columns contains a chunked geometry array.

This is similar to a GeoPandas GeoDataFrame.

geometry

geometry: ChunkedPointArray | ChunkedLineStringArray | ChunkedPolygonArray | ChunkedMultiPointArray | ChunkedMultiLineStringArray | ChunkedMultiPolygonArray | ChunkedMixedGeometryArray | ChunkedGeometryCollectionArray = <attribute 'geometry' of 'geoarrow.rust.core._rust.GeoTable' objects>

num_columns

num_columns: int = <attribute 'num_columns' of 'geoarrow.rust.core._rust.GeoTable' objects>

Number of columns in this table.

__arrow_c_stream__ method descriptor

__arrow_c_stream__(_requested_schema=None) -> object

An implementation of the Arrow PyCapsule Interface. This dunder method should not be called directly, but enables zero-copy data transfer to other Python libraries that understand Arrow memory.

For example, you can call pyarrow.table() to convert this array into a pyarrow table, without copying memory.

explode method descriptor

explode() -> Self

Explode a table.

This is intended to be equivalent to the explode function in GeoPandas.

Returns:

  • Self

    A new table with multi-part geometries exploded to separate rows.

from_arrow builtin

from_arrow(input: ArrowStreamExportable) -> Self

Construct this object from existing Arrow data

Parameters:

Returns:

from_geopandas builtin

from_geopandas(input: gpd.GeoDataFrame) -> Self

Create a GeoArrow Table from a GeoPandas GeoDataFrame.

Notes:
  • Currently this will always generate a non-chunked GeoArrow array. This is partly because pyarrow.Table.from_pandas always creates a single batch.
  • This requires pyarrow version 14 or later.

Parameters:

Returns:

  • Self

    A GeoArrow Table

to_geopandas method descriptor

to_geopandas() -> gpd.GeoDataFrame

Convert this GeoArrow Table to a GeoPandas GeoDataFrame.

Notes:
  • This requires [pyarrow][pyarrow] version 14 or later.

Returns: