master
Theophile Terraz 2025-12-05 16:51:39 +01:00
parent 3c3ac1f1df
commit 7c2d9891d0
2 changed files with 14 additions and 5 deletions

View File

@ -395,7 +395,10 @@ class InitialConditions(SQLSubModel):
strickler = 25.0 strickler = 25.0
if not compute_discharge: if not compute_discharge:
discharge = data_discharge[profile.rk] if profile.rk in data_discharge:
discharge = data_discharge[profile.rk]
else:
discharge = 0.0
else: else:
discharge = ( discharge = (
# ((width * 0.8) # ((width * 0.8)
@ -461,7 +464,10 @@ class InitialConditions(SQLSubModel):
strickler = 25.0 strickler = 25.0
if not compute_height: if not compute_height:
height = data_height[profile.rk] if profile.rk in data_height:
height = data_height[profile.rk]
else:
height = 0.0
else: else:
if abs(incline) <= 0: if abs(incline) <= 0:
height = 0.0 height = 0.0
@ -513,7 +519,10 @@ class InitialConditions(SQLSubModel):
for profile in profiles: for profile in profiles:
if not compute_discharge: if not compute_discharge:
d = data_discharge[profile.rk] if profile.rk in data_discharge:
d = data_discharge[profile.rk]
else:
d = 0.0
else: else:
d = discharge d = discharge
elevation = interp(profile.rk, elevation = interp(profile.rk,

View File

@ -22,7 +22,7 @@
<item> <item>
<widget class="QLabel" name="label"> <widget class="QLabel" name="label">
<property name="text"> <property name="text">
<string>Upstream height (m)</string> <string>Upstream elevation (m)</string>
</property> </property>
</widget> </widget>
</item> </item>
@ -70,7 +70,7 @@
<item> <item>
<widget class="QLabel" name="label_2"> <widget class="QLabel" name="label_2">
<property name="text"> <property name="text">
<string>Downstream height (m)</string> <string>Downstream elevation (m)</string>
</property> </property>
</widget> </widget>
</item> </item>