Skip to content

ClipPostprocessor

Bases: GeodataPostprocessor

Geodata postprocessor that clips the polygons based on the mask extent

PARAMETER DESCRIPTION
mask

geodataframe of the mask (may contain multiple polygons)

TYPE: gpd.GeoDataFrame

from_config classmethod

Creates a clip postprocessor from the configuration.

PARAMETER DESCRIPTION
config

configuration

TYPE: ClipPostprocessorConfig

RETURNS DESCRIPTION
ClipPostprocessor

clip postprocessor

__call__

Postprocesses the geodata by clipping the polygons based on the mask extent.

PARAMETER DESCRIPTION
gdf

geodataframe

TYPE: gpd.GeoDataFrame

RETURNS DESCRIPTION
gpd.GeoDataFrame

postprocessed geodataframe


ClipPostprocessorConfig

Bases: pydantic.BaseModel

Configuration for the from_config class method of ClipPostprocessor

ATTRIBUTE DESCRIPTION
mask

path to the geodataframe of the mask (may contain multiple polygons)

TYPE: Path