geopyspark.geotrellis.euclidean_distance module

geopyspark.geotrellis.euclidean_distance.euclidean_distance(geometry, source_crs, zoom, cell_type=<CellType.FLOAT64: 'float64'>)

Calculates the Euclidean distance of a Shapely geometry.

Parameters:
  • geometry (shapely.geometry) – The input geometry to compute the Euclidean distance for.
  • source_crs (str or int) – The CRS of the input geometry.
  • zoom (int) – The zoom level of the output raster.
  • cell_type (str or CellType, optional) – The data type of the cells for the new layer. If not specified, then CellType.FLOAT64 is used.

Note

This function may run very slowly for polygonal inputs if they cover many cells of the output raster.

Returns:TiledRasterLayer