From 463ae0c15d9d500a2e103f6d051dce28429cb84a Mon Sep 17 00:00:00 2001 From: RuudHurkmans Date: Mon, 20 Jun 2022 11:57:55 +0200 Subject: [PATCH] Added deafult profile locations --- delft3dfmpy/core/dfm.py | 9 ++++++++- delft3dfmpy/io/dflowfmwriter.py | 2 +- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/delft3dfmpy/core/dfm.py b/delft3dfmpy/core/dfm.py index b876ba2..f7c903d 100644 --- a/delft3dfmpy/core/dfm.py +++ b/delft3dfmpy/core/dfm.py @@ -360,6 +360,7 @@ def __init__(self, dflowfmmodel): self.dflowfmmodel = dflowfmmodel self.default_definition = None + self.default_locations = None self.default_definition_shift = 0.0 self.get_roughnessname = self.dflowfmmodel.network.get_roughness_description @@ -373,7 +374,13 @@ def set_default_definition(self, definition, shift=0.0): self.default_definition = definition self.default_definition_shift = shift - + def set_default_locations(self, locations): + """ + Add default profile locations + """ + + self.default_locations = locations + def add_yz_definition(self, yz=None, thalweg=None, roughnesstype=None, roughnessvalue=None, name=None): """ Add xyz crosssection diff --git a/delft3dfmpy/io/dflowfmwriter.py b/delft3dfmpy/io/dflowfmwriter.py index 7d79e12..64031c4 100644 --- a/delft3dfmpy/io/dflowfmwriter.py +++ b/delft3dfmpy/io/dflowfmwriter.py @@ -49,7 +49,7 @@ def __init__(self, dflowfmmodel, output_dir, name): with open(os.path.join(self.output_dir, 'boundaries.bc'), 'w') as f: self._write_header(f, 'boundConds', 1.01, extra_linebreak=False) - def write_all(self, add_default_crosssections=None): # write all fm files from HyDAMO + def write_all(self): # write all fm files from HyDAMO """ Wrapper to write all components to DFM. Remove existing files and create new ones. Note that the old format ext-file is not used anymore,. """