stg.range_lin_interp and stg.M_profile_fine are convert from list to array
parent
a62895d8ad
commit
5ec2d0f97f
|
|
@ -1128,8 +1128,8 @@ class SedimentCalibrationTab(QWidget):
|
|||
self.ax_Mfine.set_xlabel("Concentration fine sediments (g/L)")
|
||||
self.ax_Mfine.set_ylabel("Depth (m)")
|
||||
|
||||
if stg.M_profile_fine:
|
||||
self.ax_Mfine.plot(stg.M_profile_fine, [-r for r in stg.range_lin_interp],
|
||||
if stg.M_profile_fine.any():
|
||||
self.ax_Mfine.plot(stg.M_profile_fine, -stg.range_lin_interp,
|
||||
marker="*", mfc="b", mec="b", ms=8, ls="None")
|
||||
|
||||
def interpolate_Mfine_profile(self):
|
||||
|
|
@ -1167,9 +1167,9 @@ class SedimentCalibrationTab(QWidget):
|
|||
range_cells=stg.depth[self.combobox_acoustic_data_choice.currentIndex()][self.combobox_freq2.currentIndex(), :],
|
||||
r_bottom=stg.depth_bottom[self.combobox_acoustic_data_choice.currentIndex()]))
|
||||
print(f"1 M_profile_fine : {stg.M_profile_fine}")
|
||||
stg.range_lin_interp = stg.range_lin_interp.tolist()
|
||||
stg.M_profile_fine = stg.M_profile_fine.tolist()
|
||||
stg.M_profile_fine = stg.M_profile_fine[:len(stg.range_lin_interp)]
|
||||
stg.range_lin_interp = stg.range_lin_interp
|
||||
stg.M_profile_fine = stg.M_profile_fine
|
||||
stg.M_profile_fine = stg.M_profile_fine[:stg.range_lin_interp.shape[0]]
|
||||
print(f"2 M_profile_fine : {stg.M_profile_fine}")
|
||||
|
||||
self.plot_profile_of_concentration_fine()
|
||||
|
|
@ -2146,7 +2146,7 @@ class SedimentCalibrationTab(QWidget):
|
|||
def compute_zeta(self):
|
||||
|
||||
# --- Compute zeta ---
|
||||
if len(stg.M_profile_fine) == 0:
|
||||
if stg.M_profile_fine.shape == (0,):
|
||||
|
||||
msgBox = QMessageBox()
|
||||
msgBox.setWindowTitle("Zeta computation error")
|
||||
|
|
|
|||
Loading…
Reference in New Issue