polaris.tasks.mesh.spherical.unified.coastline.build_coastline_datasets
- polaris.tasks.mesh.spherical.unified.coastline.build_coastline_datasets(ds_topo, resolution, mask_threshold=0.5, sea_level_elevation=0.0, distance_chunk_size=64, workers=1, critical_transects=None)[source]
Build coastline datasets from combined topography.
- Parameters:
ds_topo (xr.Dataset) – Combined topography on a lat-lon grid
resolution (float) – The target lat-lon resolution in degrees
mask_threshold (float, optional) – Threshold for converting remapped mask fields to binary masks
sea_level_elevation (float, optional) – Elevation threshold used to classify below-sea-level cells
distance_chunk_size (int, optional) – Number of latitude rows per signed-distance query chunk
workers (int, optional) – Number of workers to use in KD-tree queries
critical_transects (CriticalTransects, optional) – Critical land blockages and passages to rasterize before flood fill
- Returns:
ds_coastlines (dict[str, xr.Dataset]) – Coastline datasets keyed by coastline convention