From 5160e7efb2e498a19c90cae4b1f9766071cf81a2 Mon Sep 17 00:00:00 2001 From: veenstrajelmer Date: Fri, 15 Sep 2023 03:24:57 +0200 Subject: [PATCH] fixed rasterize shape typo --- dfm_tools/get_nc.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dfm_tools/get_nc.py b/dfm_tools/get_nc.py index 1b085c19a..67ec46fbb 100644 --- a/dfm_tools/get_nc.py +++ b/dfm_tools/get_nc.py @@ -493,7 +493,7 @@ def rasterize_ugrid(uds:xu.UgridDataset, ds_like:xr.Dataset = None, resolution:f regy = np.arange(ymin + 0.5 * d, ymax, d) ds_like = xr.DataArray(np.empty((len(regy), len(regx))), {"y": regy, "x": regx}, ["y", "x"]) - print(f'>> rasterizing ugrid {face_str} to shape=({len(ds_like.y)},{len(ds_like.y)}): ',end='') + print(f'>> rasterizing ugrid {face_str} to shape=({len(ds_like.y)},{len(ds_like.x)}): ',end='') dtstart = dt.datetime.now() ds = uds.ugrid.rasterize_like(other=ds_like) print(f'{(dt.datetime.now()-dtstart).total_seconds():.2f} sec')