mirror of https://gitlab.com/pamhyr/pamhyr2
Mage: Minor code style refactoring.
parent
58300b8c1a
commit
ffbd2e2413
|
|
@ -442,14 +442,9 @@ class Mage(CommandLineSolver):
|
||||||
|
|
||||||
sin_dict = {
|
sin_dict = {
|
||||||
"ND": "*",
|
"ND": "*",
|
||||||
"S1": "D",
|
"S1": "D", "S2": "T", "S3": "T",
|
||||||
"S2": "T",
|
"OR": "O", "OC": "B", "OV": "F",
|
||||||
"S3": "T",
|
"V1": "V", "V2": "W",
|
||||||
"OR": "O",
|
|
||||||
"OC": "B",
|
|
||||||
"OV": "F",
|
|
||||||
"V1": "V",
|
|
||||||
"V2": "W",
|
|
||||||
"BO": "A",
|
"BO": "A",
|
||||||
"UD": "X",
|
"UD": "X",
|
||||||
"PO": "P",
|
"PO": "P",
|
||||||
|
|
@ -466,7 +461,9 @@ class Mage(CommandLineSolver):
|
||||||
files.append(f"{name}.SIN")
|
files.append(f"{name}.SIN")
|
||||||
|
|
||||||
for hs in hydraulic_structures:
|
for hs in hydraulic_structures:
|
||||||
if hs.input_reach.is_enable:
|
if not hs.input_reach.is_enable():
|
||||||
|
continue
|
||||||
|
|
||||||
f.write(
|
f.write(
|
||||||
'* ouvrage au pk ' +
|
'* ouvrage au pk ' +
|
||||||
f"{hs.input_kp:>12.1f}" + ' ' +
|
f"{hs.input_kp:>12.1f}" + ' ' +
|
||||||
|
|
@ -491,7 +488,7 @@ class Mage(CommandLineSolver):
|
||||||
return files
|
return files
|
||||||
|
|
||||||
def _export_SIN_parameters(self, bhs):
|
def _export_SIN_parameters(self, bhs):
|
||||||
res = [9999.999]*5
|
res = [9999.999] * 5
|
||||||
|
|
||||||
if len(bhs) == 5:
|
if len(bhs) == 5:
|
||||||
res = self._export_SIN_parameters_5(bhs)
|
res = self._export_SIN_parameters_5(bhs)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue