read_geopackage ¶
read_geopackage(
path: str | PathLike[str],
*,
layer: str | None = None,
nodata: Sequence[float | str] | None = None,
) -> boitata.PointSet | boitata.Polylines
Reads a GeoPackage feature layer as a PointSet or Polylines.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
path
|
str or Path
|
The |
required |
layer
|
str
|
Feature table to read; required when the file has more than one. |
None
|
nodata
|
sequence of float or str
|
Values read as null, as in |
None
|
Returns:
| Type | Description |
|---|---|
PointSet or Polylines
|
Point and multipoint layers give one point per member, a multipoint repeating its row; rows without a
geometry or with an empty one are dropped. Line and polygon layers give Polylines, lines as open parts and
polygon rings as closed parts without the repeated closing vertex; a row without a geometry is a feature
without parts. 2D geometries get z = 0, M values are dropped. Integer, real and boolean columns are float64,
blobs are skipped, the rest are text. The CRS is |
Raises:
| Type | Description |
|---|---|
FileError
|
When the file does not exist. |
InvalidInput
|
When the file is not a GeoPackage, |
used in