Commit c4a66281 authored by Theophile Terraz's avatar Theophile Terraz
Browse files

debug output SIN

Showing with 15 additions and 15 deletions
+15 -15
...@@ -467,21 +467,21 @@ class Mage(CommandLineSolver): ...@@ -467,21 +467,21 @@ class Mage(CommandLineSolver):
for hs in hydraulic_structures: for hs in hydraulic_structures:
if hs.input_reach.is_enable: if hs.input_reach.is_enable:
reach_id = study.river.get_edge_id(hs.input_reach) f.write('* ouvrage au pk ' +f"{hs.input_kp:>12.1f}"+ ' ' + hs.name + '\n')
params = [ for bhs in hs.basic_structures:
p.value for p in hs.basic_hydraulic_structure.param reach_id = study.river.get_edge_id(hs.input_reach)+1
]
param_str = ' '.join( param_str = ' '.join(
[ [
f'{p.value:>10.3f}' f'{p.value:>10.3f}'
for p in hs.basic_hydraulic_structure.param for p in bhs._data
] ]
) )
f.write( f.write(
f"{sin_dict[hs.basic_hydraulic_structure.type]} " + f"{sin_dict[bhs.type]} " +
f"{reach_id} {hs.kp:>12.3f} {params} " + f"{reach_id} {hs.input_kp:>12.3f} {param_str} " +
"{hs.name}\n" f"{bhs.name}\n"
) )
return files return files
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment