Skip to content

Commit 23a2b40

Browse files
author
Emma Ai
committed
flexible to the case that numpy change convention
1 parent 4d0732b commit 23a2b40

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

odc/stats/plugins/_base.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ def native_transform(self, xx: xr.Dataset) -> xr.Dataset:
5353
xx[var].attrs.get("nodata") is None
5454
and np.dtype(xx[var].dtype).kind == "f"
5555
):
56-
xx[var].attrs["nodata"] = np.nan
56+
xx[var].attrs["nodata"] = xx[var].dtype.type(None)
5757
return xx
5858

5959
def fuser(self, xx: xr.Dataset) -> xr.Dataset:

0 commit comments

Comments
 (0)