Skip to content

Commit 7c16b17

Browse files
committed
fixed mesh2d_waterdepth variable name
1 parent f8a4483 commit 7c16b17

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

mhkit/river/io/d3d.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -321,7 +321,7 @@ def get_layer_data(
321321
}
322322
bottom_depth = data["mesh2d_waterdepth"].values[time_index, :]
323323
waterlevel = data["mesh2d_s1"].values[time_index, :]
324-
coords = list(data["waterdepth"].coords)
324+
coords = list(data["mesh2d_waterdepth"].coords)
325325
elif str(list(data[variable].coords)) == "['FlowElem_xcc', 'FlowElem_ycc', 'time']" or \
326326
str(list(data[variable].coords)) == "['FlowLink_xu', 'FlowLink_yu', 'time']":
327327
cords_to_layers = {
@@ -561,7 +561,7 @@ def create_points(
561561
# pylint: disable=too-many-arguments
562562
# pylint: disable=too-many-positional-arguments
563563
def variable_interpolation(
564-
data: netCDF4.Dataset,
564+
data: Union[netCDF4.Dataset, xr.Dataset],
565565
variables: List[str],
566566
points: Union[str, pd.DataFrame, xr.Dataset] = "cells",
567567
edges: str = "none",
@@ -762,7 +762,7 @@ def get_all_data_points(
762762
}
763763
bottom_depth = data["mesh2d_waterdepth"].values[time_index, :]
764764
waterlevel = data["mesh2d_s1"].values[time_index, :]
765-
coords = list(data["waterdepth"].coords)
765+
coords = list(data["mesh2d_waterdepth"].coords)
766766
elif str(list(data[variable].coords)) == "['FlowElem_xcc', 'FlowElem_ycc', 'time']" or \
767767
str(list(data[variable].coords)) == "['FlowLink_xu', 'FlowLink_yu', 'time']":
768768
cords_to_layers = {

0 commit comments

Comments
 (0)