Skip to content

Commit

Permalink
scaling for odc-stac
Browse files Browse the repository at this point in the history
  • Loading branch information
konstntokas committed Dec 3, 2024
1 parent a4ac746 commit ea6cd6c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion xcube_stac/stac_extension/raster.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ def apply_offset_scaling_odc_stac(ds: xr.Dataset, grouped_items: dict) -> xr.Dat
nodata_val = raster_bands[0].get("nodata")
if nodata_val is not None:
ds[asset_name][i] = ds[asset_name][i].where(
ds[asset_name] != nodata_val
ds[asset_name][i] != nodata_val
)
scale = raster_bands[0].get("scale", 1)
ds[asset_name][i] *= scale
Expand Down

0 comments on commit ea6cd6c

Please sign in to comment.