reVeal.fileio.read_vectors#

read_vectors(vector_src, where=None, **kwargs)[source]#

Read vector dataset in GeoParquet or pyogrio-compatible format to GeoDataFrame.

Note that if kwargs are passed such that the geometry column is not read, the returned object will be a DataFrame rather than GeoDataFrame.

Parameters:
  • vector_src (str) – Path to vector dataset.

  • where (str, optional) – Optional query string to apply to the input vector_src to subset the features included in the results. Should follow the format expr defined in pandas.DataFrame.query.

  • **kwargs (dict) – Additional keyword arguments passed on to GeoPandas read_parquet() or read_file() methods.

Returns:

[geopandas.GeoDataFrame, pandas.DataFrame – Returns GeoDataFrame of vectors. If kwargs are passed such that the geometry column is not read, the returned object will be a DataFrame rather than a GeoDataFrame.

Raises:

IOError – An IOError will be raised if the input dataset is not a supported/recognized vector data format.