From 8ce85e5d23be66b889983641d11a55313e5e27f1 Mon Sep 17 00:00:00 2001 From: Theophile Terraz <theophile.terraz@inrae.fr> Date: Wed, 18 Sep 2024 09:20:57 +0200 Subject: [PATCH] debugs --- src/Meshing/Mage.py | 2 -- src/View/BoundaryCondition/Edit/Window.py | 4 ++++ src/View/Results/PlotH.py | 4 ++-- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/Meshing/Mage.py b/src/Meshing/Mage.py index dce49464..fb591292 100644 --- a/src/Meshing/Mage.py +++ b/src/Meshing/Mage.py @@ -381,8 +381,6 @@ class MeshingWithMageMailleurTT(AMeshingTool): st_file = self.export_reach_to_st(reach, tmp) m_file = st_file.rsplit(".ST", 1)[0] + ".M" - os.sync() - proc = QProcess() proc.setWorkingDirectory(tmp) diff --git a/src/View/BoundaryCondition/Edit/Window.py b/src/View/BoundaryCondition/Edit/Window.py index 67ff4476..7a1dae2c 100644 --- a/src/View/BoundaryCondition/Edit/Window.py +++ b/src/View/BoundaryCondition/Edit/Window.py @@ -355,6 +355,8 @@ class EditBoundaryConditionWindow(PamhyrWindow): q = [((profile.wet_width(z_min + h) * 0.8) * strickler * (h ** (5/3)) * (abs(incline) ** (0.5))) for h in height] + for i in range(len(height)): + height[i] += z_min self._table.replace_data(height, q) return @@ -372,5 +374,7 @@ class EditBoundaryConditionWindow(PamhyrWindow): q = [sqrt(9.81 * (profile.wet_area(z_min + h) ** 3) / profile.wet_width(z_min + h)) for h in height] + for i in range(len(height)): + height[i] += z_min self._table.replace_data(height, q) return diff --git a/src/View/Results/PlotH.py b/src/View/Results/PlotH.py index 90aa6674..5920d837 100644 --- a/src/View/Results/PlotH.py +++ b/src/View/Results/PlotH.py @@ -174,12 +174,12 @@ class PlotH(PamhyrPlot): self._line.set_data(x, y) self._current.set_data( - self._current_timestamp, + [self._current_timestamp, self._current_timestamp], self.canvas.axes.get_ylim() ) def update_current(self): self._current.set_data( - self._current_timestamp, + [self._current_timestamp, self._current_timestamp], self.canvas.axes.get_ylim() ) -- GitLab