stac_utils

stac_utils#

STAC utils

Functions

fill_common_mtd(asset, prod, **kwargs)

Fill common metadata of STAC assets or items

gdf_to_bbox(gdf)

Convert a geodataframe to a STAC bbox

gdf_to_centroid(gdf)

Convert a geodataframe to a STAC centroid

gdf_to_geometry(gdf)

Convert a geodataframe to a STAC geometry

get_media_type(band_path)

Get media type

repr_multiline_str(to_str, nof_tabs)

Format multiline string repr of a list, dict.

to_float(val)

Convert from numpy dtype (which are not JSON serializable) to standard dtype