Skip to content

VectorExporter

Tiles processor that exports a vector channel

The vector data is exported to a geopackage.

Notes
  • Exporting a channel by its name assumes the time step is None
  • Requires a vector channel

Implements the TilesProcessor protocol.

PARAMETER DESCRIPTION
channel_key

Channel name or channel name and time step combination

TYPE: ChannelName | str | ChannelKey

epsg_code

EPSG code

TYPE: EPSGCode | None

dir_path

Path to the directory

TYPE: Path

gpkg_name

Name of the geopackage (.gpkg file)

TYPE: str

remove_channel

If True, the channel is removed

TYPE: bool DEFAULT: True

from_config classmethod

Creates a vector exporter from the configuration.

PARAMETER DESCRIPTION
config

Configuration

TYPE: VectorExporterConfig

RETURNS DESCRIPTION
VectorExporter

Vector exporter

__call__

Exports the vector channel.

PARAMETER DESCRIPTION
tiles

Tiles

TYPE: Tiles

RETURNS DESCRIPTION
Tiles

Tiles


VectorExporterConfig

Bases: pydantic.BaseModel

Configuration for the from_config class method of VectorExporter

Create the configuration from a config file
  • Use null instead of None
  • Use false or true instead of False or True
Example

You can create the configuration from a config file.

config.yaml
package: 'aviary'
name: 'VectorExporter'
config:
  channel_key: 'my_channel'
  epsg_code: 25832
  dir_path: 'path/to/my/directory'
  gpkg_name: 'my_channel.gpkg'
  remove_channel: true
ATTRIBUTE DESCRIPTION
channel_key

Channel name or channel name and time step combination

TYPE: ChannelName | str | ChannelKey

epsg_code

EPSG code

TYPE: EPSGCode | None

dir_path

Path to the directory

TYPE: Path

gpkg_name

Name of the geopackage (.gpkg file)

TYPE: str

remove_channel

If True, the channel is removed - defaults to True

TYPE: bool