spatialdata.unpad_raster

Contents

spatialdata.unpad_raster#

spatialdata.unpad_raster(raster)#

Remove padding from a raster type that was eventually added by the rotation component of a transformation.

Parameters:

raster (DataArray | DataTree) – The raster to unpad. Contiguous zero values are considered padding.

Return type:

DataArray | DataTree

Returns:

: The unpadded raster.