mirror of https://gitlab.com/pamhyr/pamhyr2
Solver: Mage: Check is node is enable before BC export.
parent
fd1b2b1041
commit
07761716e4
|
|
@ -282,6 +282,9 @@ class Mage(CommandLineSolver):
|
||||||
if bound.node is None:
|
if bound.node is None:
|
||||||
continue
|
continue
|
||||||
|
|
||||||
|
if not study.river.is_enable_node(bound.node):
|
||||||
|
continue
|
||||||
|
|
||||||
if bound.bctype == "ZD":
|
if bound.bctype == "ZD":
|
||||||
AVA.append(bound)
|
AVA.append(bound)
|
||||||
elif bound.bctype == "TD" or bound.bctype == "PC":
|
elif bound.bctype == "TD" or bound.bctype == "PC":
|
||||||
|
|
@ -357,13 +360,7 @@ class Mage(CommandLineSolver):
|
||||||
with mage_file_open(os.path.join(repertory, f"{name}.RUG"), "w+") as f:
|
with mage_file_open(os.path.join(repertory, f"{name}.RUG"), "w+") as f:
|
||||||
files.append(f"{name}.RUG")
|
files.append(f"{name}.RUG")
|
||||||
|
|
||||||
edges = study.river.edges()
|
edges = study.river.enable_edges()
|
||||||
edges = list(
|
|
||||||
filter(
|
|
||||||
lambda e: e.is_enable(),
|
|
||||||
edges
|
|
||||||
)
|
|
||||||
)
|
|
||||||
|
|
||||||
id = 1
|
id = 1
|
||||||
for edge in edges:
|
for edge in edges:
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue