绘制了<数据精对齐>的界面
导入了<数据精对齐>的相关工具包
This commit is contained in:
465
func/utils/precisely_align_util.py
Normal file
465
func/utils/precisely_align_util.py
Normal file
@ -0,0 +1,465 @@
|
|||||||
|
import os
|
||||||
|
import shutil
|
||||||
|
import pandas as pd
|
||||||
|
|
||||||
|
from resampy import resample
|
||||||
|
from scipy import signal
|
||||||
|
|
||||||
|
|
||||||
|
import numpy as np
|
||||||
|
import matplotlib.pyplot as plt
|
||||||
|
|
||||||
|
def read_data(root):
|
||||||
|
orgBCGpath = os.path.join(root, 'raw_org.txt')
|
||||||
|
BCGpath = os.path.join(root, 'DSbcg_sig_1000hz3.txt')
|
||||||
|
ECGpath = os.path.join(root, 'filter_ecg.txt')
|
||||||
|
Jpeakspath = os.path.join(root, 'Jpeak.txt')
|
||||||
|
Rpeakspath = os.path.join(root, 'final_Rpeak.txt')
|
||||||
|
|
||||||
|
orgBCG = np.array(pd.read_csv(orgBCGpath, header=None)).reshape(-1)
|
||||||
|
# B, A = signal.butter(4, np.array([2,8])*2/1000, 'bandpass')
|
||||||
|
# BCG = signal.filtfilt(B, A, orgBCG)
|
||||||
|
BCG = np.array(pd.read_csv(BCGpath)).reshape(-1)
|
||||||
|
ECG = np.array(pd.read_csv(ECGpath, header=None)).reshape(-1)
|
||||||
|
|
||||||
|
|
||||||
|
Jpeaks = np.loadtxt(Jpeakspath).astype(int)
|
||||||
|
Rpeaks = np.loadtxt(Rpeakspath).astype(int)
|
||||||
|
|
||||||
|
return orgBCG, BCG, ECG, Jpeaks, Rpeaks
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
def Align_two_way(Jpeaks, Rpeaks, fs=1000):
|
||||||
|
def get_info(Jpeaks, Rpeaks):
|
||||||
|
"""
|
||||||
|
|
||||||
|
:param Jpeaks:
|
||||||
|
:param Rpeaks:
|
||||||
|
:return:
|
||||||
|
"""
|
||||||
|
RRIs = np.diff(Rpeaks)
|
||||||
|
JJIs = np.diff(Jpeaks)
|
||||||
|
RRIVs = np.diff(RRIs)
|
||||||
|
JJIVs = np.diff(JJIs)
|
||||||
|
|
||||||
|
N_JJIV = get_area(Jpeaks, JJIVs, Rpeaks, RRIVs, title='JJIV')
|
||||||
|
N_RRIV = get_area(Rpeaks, RRIVs, Jpeaks, JJIVs, N_JJIV=N_JJIV[0], title='RRIV')
|
||||||
|
JJIs_cut = JJIs[N_JJIV[1, 0]: N_JJIV[1, 1]]
|
||||||
|
RRIs_cut = RRIs[N_RRIV[1, 0]: N_RRIV[1, 1]]
|
||||||
|
Rpeaks_cut = Rpeaks[N_RRIV[1, 0]:N_RRIV[1, 1] + 2]
|
||||||
|
Jpeaks_cut = Jpeaks[N_JJIV[1, 0]:N_JJIV[1, 1] + 2]
|
||||||
|
RRI = np.diff(Rpeaks_cut)
|
||||||
|
# shift = get_IIV_shift(JJIs_cut, RRIs_cut)
|
||||||
|
shift, correlation_IIV, correlation_II, total_time_ratio = get_IIV_shift(JJIs_cut, RRIs_cut)
|
||||||
|
offset_interval = np.sum(RRI[:shift]) - (Jpeaks_cut[0] - Rpeaks_cut[0]) # BCG 相对于ECG的偏移量
|
||||||
|
anchor_R = Rpeaks[N_RRIV[1, 0] + shift]
|
||||||
|
anchor_J = Jpeaks[N_JJIV[1, 0]]
|
||||||
|
|
||||||
|
# info = {'N_JJIV':N_JJIV, 'N_RRIV':N_RRIV, 'shift':shift, 'offset_interval':offset_interval, 'anchors':[anchor_R, anchor_J]}
|
||||||
|
info = {'N_JJIV': N_JJIV, 'N_RRIV': N_RRIV, 'correlation_IIV': correlation_IIV,
|
||||||
|
'correlation_II': correlation_II, 'shift': shift, 'total_time_ratio': total_time_ratio,
|
||||||
|
'offset_interval': offset_interval, 'anchors': [anchor_R, anchor_J]}
|
||||||
|
return info
|
||||||
|
|
||||||
|
info1 = get_info(Jpeaks, Rpeaks)
|
||||||
|
offset_interval1 = info1['offset_interval']
|
||||||
|
anchor1 = info1['anchors']
|
||||||
|
offset_interval1_T = offset_interval1 / fs # 前端偏移时间量,大于0
|
||||||
|
print("前端对齐的偏移量为:{}s".format(offset_interval1_T))
|
||||||
|
|
||||||
|
# while True:
|
||||||
|
info2 = get_info(Jpeaks, Rpeaks)
|
||||||
|
anchor2 = info2['anchors']
|
||||||
|
offset_interval2 = info2['offset_interval']
|
||||||
|
offset_interval2_T = offset_interval2 / fs # 后端偏移时间量,大于0
|
||||||
|
print("后端对齐的偏移量为:{}s".format(offset_interval2_T))
|
||||||
|
|
||||||
|
orgfs = (int(anchor2[1]) - int(anchor1[1])) * fs / (int(anchor2[0]) - int(anchor1[0]))
|
||||||
|
|
||||||
|
offset_anchor = anchor1[0] - anchor1[1]
|
||||||
|
info = {'1': info1, '2': info2, 'offset_anchor': offset_anchor, 'orgfs': orgfs}
|
||||||
|
|
||||||
|
return info
|
||||||
|
|
||||||
|
|
||||||
|
################################################ Align utils #############################################################
|
||||||
|
def get_area(peaks1_, data1, peaks2_, data2, fs=1000, N_JJIV=None, title='JJIV'):
|
||||||
|
global N, line0, line1
|
||||||
|
|
||||||
|
peaks1 = peaks1_[:-2] / fs
|
||||||
|
peaks2 = peaks2_[:-2] / fs
|
||||||
|
ylim = [-500, 500]
|
||||||
|
|
||||||
|
'''手动选择区域'''
|
||||||
|
N = np.array([]).astype(int)
|
||||||
|
fig, ax = plt.subplots(nrows=2, ncols=1, sharex=True, sharey=True)
|
||||||
|
ax0, ax1 = ax[0], ax[1]
|
||||||
|
ax0.set_title(title)
|
||||||
|
ax0.stem(peaks1, data1, markerfmt='C0.')
|
||||||
|
line0, = ax0.plot(peaks1, data1, 'o', c='b', markersize=2, picker=True, pickradius=5)
|
||||||
|
line1, = ax0.plot(peaks1[N], data1[N] + 1, 'v', c='r', picker=True, pickradius=5)
|
||||||
|
ax0.set_ylim(ylim[0], ylim[1])
|
||||||
|
ax0.grid()
|
||||||
|
ax1.stem(peaks2, data2, markerfmt='C0.')
|
||||||
|
if N_JJIV is not None:
|
||||||
|
N_JJIV2 = np.copy(N_JJIV)
|
||||||
|
N_JJIV2 = N_JJIV2 / fs
|
||||||
|
ax1.plot([N_JJIV2[0], N_JJIV2[0]], [ylim[0], ylim[1]], 'k--')
|
||||||
|
ax1.plot([N_JJIV2[1], N_JJIV2[1]], [ylim[0], ylim[1]], 'k--')
|
||||||
|
ax1.set_ylim(ylim[0], ylim[1])
|
||||||
|
|
||||||
|
def onpick(event):
|
||||||
|
global line0, line1
|
||||||
|
global N
|
||||||
|
thisline = event.artist
|
||||||
|
xdata = thisline.get_xdata()
|
||||||
|
ind = event.ind[-1]
|
||||||
|
MM = ind
|
||||||
|
if thisline == line0:
|
||||||
|
if len(N) < 2:
|
||||||
|
N = np.append(N, MM)
|
||||||
|
N.sort()
|
||||||
|
elif thisline == line1:
|
||||||
|
N = np.delete(N, int(ind))
|
||||||
|
|
||||||
|
xlime = ax0.get_xlim()
|
||||||
|
ylime = ax0.get_ylim()
|
||||||
|
ax0.clear()
|
||||||
|
ax0.set_title(title)
|
||||||
|
ax0.stem(peaks1, data1, markerfmt='C0.')
|
||||||
|
line0, = ax0.plot(peaks1, data1, 'o', c='b', markersize=2, picker=True, pickradius=5)
|
||||||
|
line1, = ax0.plot(peaks1[N], data1[N] + 1, 'v', c='r', picker=True, pickradius=5)
|
||||||
|
ax0.set_xlim(xlime)
|
||||||
|
ax0.set_ylim(ylime)
|
||||||
|
ax0.grid()
|
||||||
|
plt.draw()
|
||||||
|
|
||||||
|
fig.canvas.mpl_connect('pick_event', onpick)
|
||||||
|
plt.show()
|
||||||
|
|
||||||
|
if len(N) == 0:
|
||||||
|
N = np.array([0, len(data1) - 1]).astype(int)
|
||||||
|
|
||||||
|
N_peak = peaks1_[N]
|
||||||
|
N_out = np.asarray([N_peak[:2], N[:2]]).astype(int)
|
||||||
|
|
||||||
|
return N_out
|
||||||
|
|
||||||
|
|
||||||
|
def get_IIV_shift(JJIs, RRIs):
|
||||||
|
global shift, line0
|
||||||
|
|
||||||
|
RRIVs = np.diff(RRIs)
|
||||||
|
JJIVs = np.diff(JJIs)
|
||||||
|
corre_ = np.correlate(RRIVs, JJIVs, 'valid')
|
||||||
|
|
||||||
|
'''手动选择偏移'''
|
||||||
|
corre = np.copy(corre_)
|
||||||
|
shift = np.argmax(corre)
|
||||||
|
RRIVs_cut = RRIVs[shift:shift + len(JJIVs)]
|
||||||
|
RRIs_cut = RRIs[shift:shift + len(JJIs)]
|
||||||
|
|
||||||
|
correlation = np.corrcoef(RRIVs_cut, JJIVs)
|
||||||
|
correlation_IIV = (correlation[0, 1] + correlation[1, 0]) / 2
|
||||||
|
|
||||||
|
correlation = np.corrcoef(RRIs_cut, JJIs)
|
||||||
|
correlation_II = (correlation[0, 1] + correlation[1, 0]) / 2
|
||||||
|
|
||||||
|
tmp = RRIVs_cut * JJIVs
|
||||||
|
same_sign_rate = np.sum(tmp > 0) / len(JJIVs)
|
||||||
|
total_time_ratio = np.sum(JJIs) / np.sum(RRIs[shift:shift + len(JJIs)])
|
||||||
|
fig, ax = plt.subplots(2, 1)
|
||||||
|
ax0, ax1 = ax[0], ax[1]
|
||||||
|
ax0.set_title(
|
||||||
|
"corre_IIV: {}, corre_II: {}\n same_sign_rate:{}, total_time_ratio: {}\n shift: {}".format(correlation_IIV,
|
||||||
|
correlation_II,
|
||||||
|
same_sign_rate,
|
||||||
|
total_time_ratio,
|
||||||
|
shift))
|
||||||
|
ax0.stem(corre, markerfmt='C0.', label='corre(RRIV, JJIV)')
|
||||||
|
line0, = ax0.plot(corre, 'o', c='b', markersize=2, picker=True, pickradius=5)
|
||||||
|
ax0.plot(shift, corre[shift] + 1, 'v', c='r', picker=True, pickradius=5)
|
||||||
|
ax0.legend()
|
||||||
|
ax0.grid()
|
||||||
|
ax1.stem(RRIVs, markerfmt='b.', label='RRIV')
|
||||||
|
ax1.stem(np.arange(shift, shift + len(JJIVs)), JJIVs, markerfmt='ko', label='JJIV')
|
||||||
|
ax1.legend()
|
||||||
|
|
||||||
|
def onpick(event):
|
||||||
|
global line0
|
||||||
|
global shift
|
||||||
|
thisline = event.artist
|
||||||
|
xdata = thisline.get_xdata()
|
||||||
|
ind = event.ind[-1]
|
||||||
|
shift = int(xdata[ind])
|
||||||
|
RRIVs_cut = RRIVs[shift:shift + len(JJIVs)]
|
||||||
|
RRIs_cut = RRIs[shift:shift + len(JJIs)]
|
||||||
|
|
||||||
|
correlation = np.corrcoef(RRIVs_cut, JJIVs)
|
||||||
|
correlation_IIV = (correlation[0, 1] + correlation[1, 0]) / 2
|
||||||
|
|
||||||
|
correlation = np.corrcoef(RRIs_cut, JJIs)
|
||||||
|
correlation_II = (correlation[0, 1] + correlation[1, 0]) / 2
|
||||||
|
|
||||||
|
tmp = RRIVs_cut * JJIVs
|
||||||
|
same_sign_rate = np.sum(tmp > 0) / len(JJIVs)
|
||||||
|
total_time_ratio = np.sum(JJIs) / np.sum(RRIs[shift:shift + len(JJIs)])
|
||||||
|
|
||||||
|
xlime = ax0.get_xlim()
|
||||||
|
ylime = ax0.get_ylim()
|
||||||
|
ax0.clear()
|
||||||
|
ax0.set_title(
|
||||||
|
"corre_IIV: {}, corre_II: {}\n same_sign_rate:{}, total_time_ratio: {}\n shift: {}".format(correlation_IIV,
|
||||||
|
correlation_II,
|
||||||
|
same_sign_rate,
|
||||||
|
total_time_ratio,
|
||||||
|
shift))
|
||||||
|
ax0.stem(corre, markerfmt='C0.', label='corre(RRIV, JJIV)')
|
||||||
|
line0, = ax0.plot(corre, 'o', c='b', markersize=2, picker=True, pickradius=5)
|
||||||
|
ax0.plot(shift, corre[shift] + 1, 'v', c='r', picker=True, pickradius=5)
|
||||||
|
ax0.legend()
|
||||||
|
ax0.grid()
|
||||||
|
ax0.set_xlim(xlime)
|
||||||
|
ax0.set_ylim(ylime)
|
||||||
|
xlime = ax1.get_xlim()
|
||||||
|
ylime = ax1.get_ylim()
|
||||||
|
ax1.clear()
|
||||||
|
ax1.stem(RRIVs, markerfmt='b.', label='RRIV')
|
||||||
|
ax1.stem(np.arange(shift, shift + len(JJIVs)), JJIVs, markerfmt='ko', label='JJIV')
|
||||||
|
ax1.legend()
|
||||||
|
ax1.set_xlim(xlime)
|
||||||
|
ax1.set_ylim(ylime)
|
||||||
|
plt.draw()
|
||||||
|
|
||||||
|
fig.canvas.mpl_connect('pick_event', onpick)
|
||||||
|
plt.show()
|
||||||
|
|
||||||
|
# return shift
|
||||||
|
return shift, correlation_IIV, correlation_II, total_time_ratio
|
||||||
|
|
||||||
|
|
||||||
|
def main():
|
||||||
|
def offset_correct(BCG, ECG, anchors):
|
||||||
|
global line0, line1, N, M
|
||||||
|
a = np.max([np.max(ECG), np.max(BCG)])
|
||||||
|
b = np.min([np.min(ECG), np.min(BCG)])
|
||||||
|
peaks_ECG, _ = signal.find_peaks(ECG)
|
||||||
|
peaks_BCG, _ = signal.find_peaks(BCG)
|
||||||
|
N, M = np.array([]).astype(int), np.array([]).astype(int)
|
||||||
|
fig, ax = plt.subplots()
|
||||||
|
ax.set_title("offset correct")
|
||||||
|
ax.plot(ECG)
|
||||||
|
ax.plot(BCG)
|
||||||
|
ax.plot([anchors[0], anchors[0]], [b, a], 'k--')
|
||||||
|
ax.plot([anchors[1], anchors[1]], [b, a], 'k--')
|
||||||
|
ax.plot(N, ECG[N] + 1, 'rv')
|
||||||
|
ax.plot(M, BCG[M] + 1, 'yv')
|
||||||
|
line0, = ax.plot(peaks_ECG, ECG[peaks_ECG], 'o', markersize=2, c='g', picker=True, pickradius=5)
|
||||||
|
line1, = ax.plot(peaks_BCG, BCG[peaks_BCG], 'o', markersize=2, c='g', picker=True, pickradius=5)
|
||||||
|
ax.grid()
|
||||||
|
|
||||||
|
def onpick(event):
|
||||||
|
global line0, line1, N, M
|
||||||
|
thisline = event.artist
|
||||||
|
xdata = thisline.get_xdata()
|
||||||
|
ind = event.ind[-1]
|
||||||
|
nm = int(xdata[ind])
|
||||||
|
if thisline == line0:
|
||||||
|
if nm in N:
|
||||||
|
idx = np.where(N == nm)[0]
|
||||||
|
N = np.delete(N, idx)
|
||||||
|
elif len(N) < 2:
|
||||||
|
N = np.append(N, nm)
|
||||||
|
elif thisline == line1:
|
||||||
|
if nm in M:
|
||||||
|
idx = np.where(M == nm)[0]
|
||||||
|
M = np.delete(M, idx)
|
||||||
|
elif len(M) < 2:
|
||||||
|
M = np.append(M, nm)
|
||||||
|
|
||||||
|
xlime = ax.get_xlim()
|
||||||
|
ylime = ax.get_ylim()
|
||||||
|
ax.clear()
|
||||||
|
ax.set_title("offset correct")
|
||||||
|
ax.plot(ECG)
|
||||||
|
ax.plot(BCG)
|
||||||
|
ax.plot([anchors[0], anchors[0]], [b, a], 'k--')
|
||||||
|
ax.plot([anchors[1], anchors[1]], [b, a], 'k--')
|
||||||
|
ax.plot(N, ECG[N] + 1, 'rv')
|
||||||
|
ax.plot(M, BCG[M] + 1, 'yv')
|
||||||
|
line0, = ax.plot(peaks_ECG, ECG[peaks_ECG], 'o', markersize=2, c='g', picker=True, pickradius=5)
|
||||||
|
line1, = ax.plot(peaks_BCG, BCG[peaks_BCG], 'o', markersize=2, c='g', picker=True, pickradius=5)
|
||||||
|
ax.grid()
|
||||||
|
ax.set_xlim(xlime)
|
||||||
|
ax.set_ylim(ylime)
|
||||||
|
plt.draw()
|
||||||
|
|
||||||
|
fig.canvas.mpl_connect('pick_event', onpick)
|
||||||
|
plt.show()
|
||||||
|
|
||||||
|
if len(N) == 0 or len(M) == 0:
|
||||||
|
off = 0
|
||||||
|
else:
|
||||||
|
M.sort()
|
||||||
|
N.sort()
|
||||||
|
off = round(((int(N[1]) - int(M[1])) + (int(N[0]) - int(M[0]))) / 2)
|
||||||
|
|
||||||
|
return off
|
||||||
|
|
||||||
|
'''输入信息(如数据路径、采样频率)'''
|
||||||
|
fs = 1000
|
||||||
|
root = r"E:\data_annotation\pratice_data\282" # E:\BCG_data\703
|
||||||
|
|
||||||
|
saveroot = os.path.join(root, 'Align')
|
||||||
|
if not os.path.exists(saveroot):
|
||||||
|
os.mkdir(saveroot)
|
||||||
|
else:
|
||||||
|
shutil.rmtree(saveroot)
|
||||||
|
os.mkdir(saveroot)
|
||||||
|
|
||||||
|
'''获取数据(BCG、ECG、J_peak、R_peak)'''
|
||||||
|
raw_org_, DSbcg_sig_1000hz3_, filter_ecg_, Jpeak_, final_Rpeak_ = read_data(root)
|
||||||
|
|
||||||
|
orgBCG = raw_org_
|
||||||
|
BCG = DSbcg_sig_1000hz3_
|
||||||
|
ECG = filter_ecg_
|
||||||
|
Rpeaks = final_Rpeak_
|
||||||
|
Jpeaks = Jpeak_
|
||||||
|
|
||||||
|
orgbcg_len = len(BCG)
|
||||||
|
argmax_bcg = np.argmax(BCG)
|
||||||
|
orgecg_len = len(ECG)
|
||||||
|
argmax_ecg = np.argmax(ECG)
|
||||||
|
|
||||||
|
# plt.figure()
|
||||||
|
# plt.subplot(2,1,1)
|
||||||
|
# plt.plot(BCG[:3600000])
|
||||||
|
# plt.subplot(2,1,2)
|
||||||
|
# plt.plot(ECG)
|
||||||
|
|
||||||
|
info = Align_two_way(Jpeaks, Rpeaks, fs=fs)
|
||||||
|
|
||||||
|
print(info)
|
||||||
|
|
||||||
|
anchor0 = info['1']['anchors']
|
||||||
|
anchor1 = info['2']['anchors']
|
||||||
|
|
||||||
|
off = info['offset_anchor']
|
||||||
|
orgfs = info['orgfs']
|
||||||
|
|
||||||
|
if off > 0:
|
||||||
|
ECG = ECG[off:]
|
||||||
|
anchor0[0] = anchor0[0] - off
|
||||||
|
anchor1[0] = anchor1[0] - off
|
||||||
|
idxs = np.where(Rpeaks > off)[0]
|
||||||
|
Rpeaks = Rpeaks[idxs] - off
|
||||||
|
else:
|
||||||
|
BCG = BCG[-off:]
|
||||||
|
orgBCG = orgBCG[-off:]
|
||||||
|
anchor0[1] = anchor0[1] + off
|
||||||
|
anchor1[1] = anchor1[1] + off
|
||||||
|
|
||||||
|
BCG_res = resample(BCG, orgfs, fs)
|
||||||
|
orgBCG_res = resample(orgBCG, orgfs, fs)
|
||||||
|
|
||||||
|
# ————————————————————————————————————————————————————————————————
|
||||||
|
anchor0[1] = round(int(anchor0[1]) * fs / orgfs)
|
||||||
|
anchor1[1] = round(int(anchor1[1]) * fs / orgfs)
|
||||||
|
off = anchor1[0] - anchor1[1]
|
||||||
|
if off > 0:
|
||||||
|
ECG = ECG[off:]
|
||||||
|
anchor0[0] = anchor0[0] - off
|
||||||
|
anchor1[0] = anchor1[0] - off
|
||||||
|
idxs = np.where(Rpeaks > off)[0]
|
||||||
|
Rpeaks = Rpeaks[idxs] - off
|
||||||
|
else:
|
||||||
|
BCG_res = BCG_res[-off:]
|
||||||
|
orgBCG_res = orgBCG_res[-off:]
|
||||||
|
anchor0[1] = anchor0[1] + off
|
||||||
|
anchor1[1] = anchor1[1] + off
|
||||||
|
|
||||||
|
datalen = np.min([len(ECG), len(BCG_res)])
|
||||||
|
ECG = ECG[:datalen]
|
||||||
|
BCG_res = BCG_res[:datalen]
|
||||||
|
orgBCG_res = orgBCG_res[:datalen]
|
||||||
|
|
||||||
|
idxs = np.where(Rpeaks < datalen)[0]
|
||||||
|
Rpeaks = Rpeaks[idxs]
|
||||||
|
|
||||||
|
# ——————————————————————————————————————————————————————————————————
|
||||||
|
off = offset_correct(BCG_res, ECG, [anchor0[0], anchor1[0]])
|
||||||
|
if off > 0:
|
||||||
|
ECG = ECG[off:]
|
||||||
|
anchor0[0] = anchor0[0] - off
|
||||||
|
anchor1[0] = anchor1[0] - off
|
||||||
|
idxs = np.where(Rpeaks > off)[0]
|
||||||
|
Rpeaks = Rpeaks[idxs] - off
|
||||||
|
else:
|
||||||
|
BCG_res = BCG_res[-off:]
|
||||||
|
orgBCG_res = orgBCG_res[-off:]
|
||||||
|
anchor0[1] = anchor0[1] + off
|
||||||
|
anchor1[1] = anchor1[1] + off
|
||||||
|
|
||||||
|
info['offset_correct'] = off
|
||||||
|
|
||||||
|
datalen = np.min([len(ECG), len(BCG_res)])
|
||||||
|
ECG = ECG[:datalen]
|
||||||
|
BCG_res = BCG_res[:datalen]
|
||||||
|
orgBCG_res = orgBCG_res[:datalen]
|
||||||
|
|
||||||
|
idxs = np.where(Rpeaks < datalen)[0]
|
||||||
|
Rpeaks = Rpeaks[idxs]
|
||||||
|
|
||||||
|
Jpeaks = []
|
||||||
|
peaks, _ = signal.find_peaks(BCG_res)
|
||||||
|
for i in Rpeaks:
|
||||||
|
tmp = np.abs(peaks - i)
|
||||||
|
idx = np.argmin(tmp)
|
||||||
|
Jpeaks.append(peaks[idx])
|
||||||
|
Jpeaks = np.asarray(Jpeaks).astype(int)
|
||||||
|
|
||||||
|
# ----------------2024.4.17 CYS 新增计算BCG与ECG前后两端切割的横坐标----------------
|
||||||
|
orgfs = info['orgfs'] # 原始数据采样频率
|
||||||
|
frontcut_index_bcg = int((argmax_bcg - np.argmax(BCG_res) / 1000 * orgfs))
|
||||||
|
backcut_index_bcg = int((len(BCG_res) / 1000 * orgfs + argmax_bcg - np.argmax(BCG_res) / 1000 * orgfs))
|
||||||
|
|
||||||
|
frontcut_index_ecg = argmax_ecg - np.argmax(ECG)
|
||||||
|
backcut_index_ecg = len(ECG) + argmax_ecg - np.argmax(ECG)
|
||||||
|
|
||||||
|
print("1. BCG前段被切割的坐标值为:", frontcut_index_bcg)
|
||||||
|
print("1. BCG后段被切割的坐标值为:", backcut_index_bcg)
|
||||||
|
print("2. ECG前段被切割的坐标值为:", frontcut_index_ecg)
|
||||||
|
print("2. ECG后段被切割的坐标值为:", backcut_index_ecg)
|
||||||
|
info = {'0': info, 'frontcut_index_bcg': frontcut_index_bcg, 'backcut_index_bcg': backcut_index_bcg,
|
||||||
|
'frontcut_index_ecg': frontcut_index_ecg, 'backcut_index_ecg': backcut_index_ecg}
|
||||||
|
# ------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
plt.figure()
|
||||||
|
plt.plot(ECG, label='ECG')
|
||||||
|
plt.plot(BCG_res, label='BCG')
|
||||||
|
plt.plot(Rpeaks, ECG[Rpeaks], 'ko', label='Rpeaks')
|
||||||
|
plt.plot(Jpeaks, BCG_res[Jpeaks], 'rv', label='Jpeaks')
|
||||||
|
# plt.legend()
|
||||||
|
plt.show()
|
||||||
|
|
||||||
|
savepath = os.path.join(saveroot, 'Align_info.npy')
|
||||||
|
np.save(savepath, info)
|
||||||
|
savepath = os.path.join(saveroot, 'Align_info.txt')
|
||||||
|
with open(savepath, 'w') as file:
|
||||||
|
file.write(str(info))
|
||||||
|
|
||||||
|
savepath = os.path.join(saveroot, 'orgData_sync.txt')
|
||||||
|
pd.DataFrame(np.round(orgBCG_res, 4)).to_csv(savepath, index=None, header=None)
|
||||||
|
savepath = os.path.join(saveroot, 'BCG_sync.txt')
|
||||||
|
pd.DataFrame(np.round(BCG_res, 4)).to_csv(savepath, index=None, header=None)
|
||||||
|
savepath = os.path.join(saveroot, 'ECG_sync.txt')
|
||||||
|
pd.DataFrame(ECG).to_csv(savepath, index=None, header=None)
|
||||||
|
savepath = os.path.join(saveroot, 'Jpeaks_sync.txt')
|
||||||
|
pd.DataFrame(Jpeaks).to_csv(savepath, index=None, header=None)
|
||||||
|
savepath = os.path.join(saveroot, 'Rpeaks_sync.txt')
|
||||||
|
pd.DataFrame(Rpeaks).to_csv(savepath, index=None, header=None)
|
||||||
|
|
||||||
|
|
||||||
|
if __name__ == "__main__":
|
||||||
|
main()
|
||||||
@ -19,7 +19,7 @@ from PySide6.QtWidgets import (QAbstractSpinBox, QApplication, QGridLayout, QGro
|
|||||||
QHBoxLayout, QHeaderView, QLabel, QLineEdit,
|
QHBoxLayout, QHeaderView, QLabel, QLineEdit,
|
||||||
QMainWindow, QPushButton, QRadioButton, QSizePolicy,
|
QMainWindow, QPushButton, QRadioButton, QSizePolicy,
|
||||||
QSpacerItem, QSpinBox, QStatusBar, QTableWidget,
|
QSpacerItem, QSpinBox, QStatusBar, QTableWidget,
|
||||||
QTableWidgetItem, QVBoxLayout, QWidget)
|
QTableWidgetItem, QTextBrowser, QVBoxLayout, QWidget)
|
||||||
|
|
||||||
class Ui_MainWindow_artifact_label(object):
|
class Ui_MainWindow_artifact_label(object):
|
||||||
def setupUi(self, MainWindow_artifact_label):
|
def setupUi(self, MainWindow_artifact_label):
|
||||||
@ -391,6 +391,18 @@ class Ui_MainWindow_artifact_label(object):
|
|||||||
|
|
||||||
self.verticalLayout_2.addWidget(self.pushButton)
|
self.verticalLayout_2.addWidget(self.pushButton)
|
||||||
|
|
||||||
|
self.groupBox_4 = QGroupBox(self.groupBox_left)
|
||||||
|
self.groupBox_4.setObjectName(u"groupBox_4")
|
||||||
|
self.verticalLayout_6 = QVBoxLayout(self.groupBox_4)
|
||||||
|
self.verticalLayout_6.setObjectName(u"verticalLayout_6")
|
||||||
|
self.textBrowser_info = QTextBrowser(self.groupBox_4)
|
||||||
|
self.textBrowser_info.setObjectName(u"textBrowser_info")
|
||||||
|
|
||||||
|
self.verticalLayout_6.addWidget(self.textBrowser_info)
|
||||||
|
|
||||||
|
|
||||||
|
self.verticalLayout_2.addWidget(self.groupBox_4)
|
||||||
|
|
||||||
self.verticalLayout_2.setStretch(0, 1)
|
self.verticalLayout_2.setStretch(0, 1)
|
||||||
self.verticalLayout_2.setStretch(1, 1)
|
self.verticalLayout_2.setStretch(1, 1)
|
||||||
self.verticalLayout_2.setStretch(2, 3)
|
self.verticalLayout_2.setStretch(2, 3)
|
||||||
@ -690,6 +702,7 @@ class Ui_MainWindow_artifact_label(object):
|
|||||||
self.label_6.setText(QCoreApplication.translate("MainWindow_artifact_label", u"\u6700\u5927\u8303\u56f4", None))
|
self.label_6.setText(QCoreApplication.translate("MainWindow_artifact_label", u"\u6700\u5927\u8303\u56f4", None))
|
||||||
self.label_8.setText(QCoreApplication.translate("MainWindow_artifact_label", u"\u79fb\u52a8\u95f4\u9694(ms)", None))
|
self.label_8.setText(QCoreApplication.translate("MainWindow_artifact_label", u"\u79fb\u52a8\u95f4\u9694(ms)", None))
|
||||||
self.pushButton.setText(QCoreApplication.translate("MainWindow_artifact_label", u"\u5bfc\u51fa\u6807\u7b7e", None))
|
self.pushButton.setText(QCoreApplication.translate("MainWindow_artifact_label", u"\u5bfc\u51fa\u6807\u7b7e", None))
|
||||||
|
self.groupBox_4.setTitle(QCoreApplication.translate("MainWindow_artifact_label", u"\u65e5\u5fd7", None))
|
||||||
self.groupBox_right.setTitle(QCoreApplication.translate("MainWindow_artifact_label", u"\u6807\u6ce8\u64cd\u4f5c\u548c\u4fe1\u606f", None))
|
self.groupBox_right.setTitle(QCoreApplication.translate("MainWindow_artifact_label", u"\u6807\u6ce8\u64cd\u4f5c\u548c\u4fe1\u606f", None))
|
||||||
self.pushButton_type_1.setText(QCoreApplication.translate("MainWindow_artifact_label", u"\u5267\u70c8\u4f53\u52a8", None))
|
self.pushButton_type_1.setText(QCoreApplication.translate("MainWindow_artifact_label", u"\u5267\u70c8\u4f53\u52a8", None))
|
||||||
self.label_13.setText(QCoreApplication.translate("MainWindow_artifact_label", u"\u4e2a\u6570&\u7d2f\u8ba1\u65f6\u957f(ms)", None))
|
self.label_13.setText(QCoreApplication.translate("MainWindow_artifact_label", u"\u4e2a\u6570&\u7d2f\u8ba1\u65f6\u957f(ms)", None))
|
||||||
|
|||||||
@ -42,7 +42,7 @@
|
|||||||
<property name="title">
|
<property name="title">
|
||||||
<string>体动标注</string>
|
<string>体动标注</string>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_2" stretch="1,1,3,1,6,1,1">
|
<layout class="QVBoxLayout" name="verticalLayout_2" stretch="1,1,3,1,6,1,1,0">
|
||||||
<item>
|
<item>
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||||
<item>
|
<item>
|
||||||
@ -676,6 +676,18 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QGroupBox" name="groupBox_4">
|
||||||
|
<property name="title">
|
||||||
|
<string>日志</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_6">
|
||||||
|
<item>
|
||||||
|
<widget class="QTextBrowser" name="textBrowser_info"/>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
|||||||
@ -19,7 +19,8 @@ from PySide6.QtWidgets import (QAbstractSpinBox, QApplication, QCheckBox, QDoubl
|
|||||||
QGridLayout, QGroupBox, QHBoxLayout, QHeaderView,
|
QGridLayout, QGroupBox, QHBoxLayout, QHeaderView,
|
||||||
QLabel, QMainWindow, QPushButton, QRadioButton,
|
QLabel, QMainWindow, QPushButton, QRadioButton,
|
||||||
QSizePolicy, QSpacerItem, QSpinBox, QStatusBar,
|
QSizePolicy, QSpacerItem, QSpinBox, QStatusBar,
|
||||||
QTableWidget, QTableWidgetItem, QVBoxLayout, QWidget)
|
QTableWidget, QTableWidgetItem, QTextBrowser, QVBoxLayout,
|
||||||
|
QWidget)
|
||||||
|
|
||||||
class Ui_MainWindow(object):
|
class Ui_MainWindow(object):
|
||||||
def setupUi(self, MainWindow):
|
def setupUi(self, MainWindow):
|
||||||
@ -351,6 +352,18 @@ class Ui_MainWindow(object):
|
|||||||
|
|
||||||
self.verticalLayout_2.addLayout(self.horizontalLayout_3)
|
self.verticalLayout_2.addLayout(self.horizontalLayout_3)
|
||||||
|
|
||||||
|
self.groupBox_4 = QGroupBox(self.groupBox_left)
|
||||||
|
self.groupBox_4.setObjectName(u"groupBox_4")
|
||||||
|
self.verticalLayout_6 = QVBoxLayout(self.groupBox_4)
|
||||||
|
self.verticalLayout_6.setObjectName(u"verticalLayout_6")
|
||||||
|
self.textBrowser_info = QTextBrowser(self.groupBox_4)
|
||||||
|
self.textBrowser_info.setObjectName(u"textBrowser_info")
|
||||||
|
|
||||||
|
self.verticalLayout_6.addWidget(self.textBrowser_info)
|
||||||
|
|
||||||
|
|
||||||
|
self.verticalLayout_2.addWidget(self.groupBox_4)
|
||||||
|
|
||||||
self.verticalLayout_2.setStretch(0, 1)
|
self.verticalLayout_2.setStretch(0, 1)
|
||||||
self.verticalLayout_2.setStretch(1, 1)
|
self.verticalLayout_2.setStretch(1, 1)
|
||||||
self.verticalLayout_2.setStretch(2, 1)
|
self.verticalLayout_2.setStretch(2, 1)
|
||||||
@ -485,6 +498,7 @@ class Ui_MainWindow(object):
|
|||||||
self.label_8.setText(QCoreApplication.translate("MainWindow", u"\u79fb\u52a8\u95f4\u9694(ms)", None))
|
self.label_8.setText(QCoreApplication.translate("MainWindow", u"\u79fb\u52a8\u95f4\u9694(ms)", None))
|
||||||
self.checkBox.setText(QCoreApplication.translate("MainWindow", u"\u7ed8\u5236\u53c2\u8003\u7ebf", None))
|
self.checkBox.setText(QCoreApplication.translate("MainWindow", u"\u7ed8\u5236\u53c2\u8003\u7ebf", None))
|
||||||
self.pushButton.setText(QCoreApplication.translate("MainWindow", u"\u5bfc\u51fa\u6807\u7b7e", None))
|
self.pushButton.setText(QCoreApplication.translate("MainWindow", u"\u5bfc\u51fa\u6807\u7b7e", None))
|
||||||
|
self.groupBox_4.setTitle(QCoreApplication.translate("MainWindow", u"\u65e5\u5fd7", None))
|
||||||
self.groupBox_right.setTitle(QCoreApplication.translate("MainWindow", u"\u5cf0\u503c\u5750\u6807\u548c\u4fe1\u606f", None))
|
self.groupBox_right.setTitle(QCoreApplication.translate("MainWindow", u"\u5cf0\u503c\u5750\u6807\u548c\u4fe1\u606f", None))
|
||||||
self.label_9.setText(QCoreApplication.translate("MainWindow", u"\u6570\u636e\u957f\u5ea6(\u70b9\u6570)", None))
|
self.label_9.setText(QCoreApplication.translate("MainWindow", u"\u6570\u636e\u957f\u5ea6(\u70b9\u6570)", None))
|
||||||
self.label_11.setText(QCoreApplication.translate("MainWindow", u"\u7ea0\u6b63\u524d\u5cf0\u503c\u4e2a\u6570", None))
|
self.label_11.setText(QCoreApplication.translate("MainWindow", u"\u7ea0\u6b63\u524d\u5cf0\u503c\u4e2a\u6570", None))
|
||||||
|
|||||||
@ -42,7 +42,7 @@
|
|||||||
<property name="title">
|
<property name="title">
|
||||||
<string>人工纠正</string>
|
<string>人工纠正</string>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_2" stretch="1,1,1,1,6,1,1">
|
<layout class="QVBoxLayout" name="verticalLayout_2" stretch="1,1,1,1,6,1,1,0">
|
||||||
<item>
|
<item>
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||||
<item>
|
<item>
|
||||||
@ -603,6 +603,18 @@
|
|||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QGroupBox" name="groupBox_4">
|
||||||
|
<property name="title">
|
||||||
|
<string>日志</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_6">
|
||||||
|
<item>
|
||||||
|
<widget class="QTextBrowser" name="textBrowser_info"/>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
|||||||
@ -80,13 +80,13 @@ class Ui_Signal_Label(object):
|
|||||||
|
|
||||||
self.verticalLayout.addLayout(self.horizontalLayout)
|
self.verticalLayout.addLayout(self.horizontalLayout)
|
||||||
|
|
||||||
self.pushButton_2 = QPushButton(self.centralwidget)
|
self.pushButton_approximately_align = QPushButton(self.centralwidget)
|
||||||
self.pushButton_2.setObjectName(u"pushButton_2")
|
self.pushButton_approximately_align.setObjectName(u"pushButton_approximately_align")
|
||||||
sizePolicy.setHeightForWidth(self.pushButton_2.sizePolicy().hasHeightForWidth())
|
sizePolicy.setHeightForWidth(self.pushButton_approximately_align.sizePolicy().hasHeightForWidth())
|
||||||
self.pushButton_2.setSizePolicy(sizePolicy)
|
self.pushButton_approximately_align.setSizePolicy(sizePolicy)
|
||||||
self.pushButton_2.setFont(font)
|
self.pushButton_approximately_align.setFont(font)
|
||||||
|
|
||||||
self.verticalLayout.addWidget(self.pushButton_2)
|
self.verticalLayout.addWidget(self.pushButton_approximately_align)
|
||||||
|
|
||||||
self.horizontalLayout_2 = QHBoxLayout()
|
self.horizontalLayout_2 = QHBoxLayout()
|
||||||
self.horizontalLayout_2.setObjectName(u"horizontalLayout_2")
|
self.horizontalLayout_2.setObjectName(u"horizontalLayout_2")
|
||||||
@ -132,64 +132,64 @@ class Ui_Signal_Label(object):
|
|||||||
|
|
||||||
self.horizontalLayout_6 = QHBoxLayout()
|
self.horizontalLayout_6 = QHBoxLayout()
|
||||||
self.horizontalLayout_6.setObjectName(u"horizontalLayout_6")
|
self.horizontalLayout_6.setObjectName(u"horizontalLayout_6")
|
||||||
self.pushButton_7 = QPushButton(self.centralwidget)
|
self.pushButton_label_check_BCG = QPushButton(self.centralwidget)
|
||||||
self.pushButton_7.setObjectName(u"pushButton_7")
|
self.pushButton_label_check_BCG.setObjectName(u"pushButton_label_check_BCG")
|
||||||
sizePolicy.setHeightForWidth(self.pushButton_7.sizePolicy().hasHeightForWidth())
|
sizePolicy.setHeightForWidth(self.pushButton_label_check_BCG.sizePolicy().hasHeightForWidth())
|
||||||
self.pushButton_7.setSizePolicy(sizePolicy)
|
self.pushButton_label_check_BCG.setSizePolicy(sizePolicy)
|
||||||
self.pushButton_7.setFont(font)
|
self.pushButton_label_check_BCG.setFont(font)
|
||||||
|
|
||||||
self.horizontalLayout_6.addWidget(self.pushButton_7)
|
self.horizontalLayout_6.addWidget(self.pushButton_label_check_BCG)
|
||||||
|
|
||||||
self.pushButton_8 = QPushButton(self.centralwidget)
|
self.pushButton_label_check_ECG = QPushButton(self.centralwidget)
|
||||||
self.pushButton_8.setObjectName(u"pushButton_8")
|
self.pushButton_label_check_ECG.setObjectName(u"pushButton_label_check_ECG")
|
||||||
sizePolicy.setHeightForWidth(self.pushButton_8.sizePolicy().hasHeightForWidth())
|
sizePolicy.setHeightForWidth(self.pushButton_label_check_ECG.sizePolicy().hasHeightForWidth())
|
||||||
self.pushButton_8.setSizePolicy(sizePolicy)
|
self.pushButton_label_check_ECG.setSizePolicy(sizePolicy)
|
||||||
self.pushButton_8.setFont(font)
|
self.pushButton_label_check_ECG.setFont(font)
|
||||||
|
|
||||||
self.horizontalLayout_6.addWidget(self.pushButton_8)
|
self.horizontalLayout_6.addWidget(self.pushButton_label_check_ECG)
|
||||||
|
|
||||||
|
|
||||||
self.verticalLayout.addLayout(self.horizontalLayout_6)
|
self.verticalLayout.addLayout(self.horizontalLayout_6)
|
||||||
|
|
||||||
self.pushButton_10 = QPushButton(self.centralwidget)
|
self.pushButton_precisely_align = QPushButton(self.centralwidget)
|
||||||
self.pushButton_10.setObjectName(u"pushButton_10")
|
self.pushButton_precisely_align.setObjectName(u"pushButton_precisely_align")
|
||||||
sizePolicy.setHeightForWidth(self.pushButton_10.sizePolicy().hasHeightForWidth())
|
sizePolicy.setHeightForWidth(self.pushButton_precisely_align.sizePolicy().hasHeightForWidth())
|
||||||
self.pushButton_10.setSizePolicy(sizePolicy)
|
self.pushButton_precisely_align.setSizePolicy(sizePolicy)
|
||||||
self.pushButton_10.setFont(font)
|
self.pushButton_precisely_align.setFont(font)
|
||||||
|
|
||||||
self.verticalLayout.addWidget(self.pushButton_10)
|
self.verticalLayout.addWidget(self.pushButton_precisely_align)
|
||||||
|
|
||||||
self.pushButton_9 = QPushButton(self.centralwidget)
|
self.pushButton_artifact_label = QPushButton(self.centralwidget)
|
||||||
self.pushButton_9.setObjectName(u"pushButton_9")
|
self.pushButton_artifact_label.setObjectName(u"pushButton_artifact_label")
|
||||||
sizePolicy.setHeightForWidth(self.pushButton_9.sizePolicy().hasHeightForWidth())
|
sizePolicy.setHeightForWidth(self.pushButton_artifact_label.sizePolicy().hasHeightForWidth())
|
||||||
self.pushButton_9.setSizePolicy(sizePolicy)
|
self.pushButton_artifact_label.setSizePolicy(sizePolicy)
|
||||||
self.pushButton_9.setFont(font)
|
self.pushButton_artifact_label.setFont(font)
|
||||||
|
|
||||||
self.verticalLayout.addWidget(self.pushButton_9)
|
self.verticalLayout.addWidget(self.pushButton_artifact_label)
|
||||||
|
|
||||||
self.pushButton_11 = QPushButton(self.centralwidget)
|
self.pushButton_bcg_quality_label = QPushButton(self.centralwidget)
|
||||||
self.pushButton_11.setObjectName(u"pushButton_11")
|
self.pushButton_bcg_quality_label.setObjectName(u"pushButton_bcg_quality_label")
|
||||||
sizePolicy.setHeightForWidth(self.pushButton_11.sizePolicy().hasHeightForWidth())
|
sizePolicy.setHeightForWidth(self.pushButton_bcg_quality_label.sizePolicy().hasHeightForWidth())
|
||||||
self.pushButton_11.setSizePolicy(sizePolicy)
|
self.pushButton_bcg_quality_label.setSizePolicy(sizePolicy)
|
||||||
self.pushButton_11.setFont(font)
|
self.pushButton_bcg_quality_label.setFont(font)
|
||||||
|
|
||||||
self.verticalLayout.addWidget(self.pushButton_11)
|
self.verticalLayout.addWidget(self.pushButton_bcg_quality_label)
|
||||||
|
|
||||||
self.pushButton_12 = QPushButton(self.centralwidget)
|
self.pushButton_resp_quality_label = QPushButton(self.centralwidget)
|
||||||
self.pushButton_12.setObjectName(u"pushButton_12")
|
self.pushButton_resp_quality_label.setObjectName(u"pushButton_resp_quality_label")
|
||||||
sizePolicy.setHeightForWidth(self.pushButton_12.sizePolicy().hasHeightForWidth())
|
sizePolicy.setHeightForWidth(self.pushButton_resp_quality_label.sizePolicy().hasHeightForWidth())
|
||||||
self.pushButton_12.setSizePolicy(sizePolicy)
|
self.pushButton_resp_quality_label.setSizePolicy(sizePolicy)
|
||||||
self.pushButton_12.setFont(font)
|
self.pushButton_resp_quality_label.setFont(font)
|
||||||
|
|
||||||
self.verticalLayout.addWidget(self.pushButton_12)
|
self.verticalLayout.addWidget(self.pushButton_resp_quality_label)
|
||||||
|
|
||||||
self.pushButton_13 = QPushButton(self.centralwidget)
|
self.pushButton_SA_label = QPushButton(self.centralwidget)
|
||||||
self.pushButton_13.setObjectName(u"pushButton_13")
|
self.pushButton_SA_label.setObjectName(u"pushButton_SA_label")
|
||||||
sizePolicy.setHeightForWidth(self.pushButton_13.sizePolicy().hasHeightForWidth())
|
sizePolicy.setHeightForWidth(self.pushButton_SA_label.sizePolicy().hasHeightForWidth())
|
||||||
self.pushButton_13.setSizePolicy(sizePolicy)
|
self.pushButton_SA_label.setSizePolicy(sizePolicy)
|
||||||
self.pushButton_13.setFont(font)
|
self.pushButton_SA_label.setFont(font)
|
||||||
|
|
||||||
self.verticalLayout.addWidget(self.pushButton_13)
|
self.verticalLayout.addWidget(self.pushButton_SA_label)
|
||||||
|
|
||||||
self.verticalLayout.setStretch(0, 1)
|
self.verticalLayout.setStretch(0, 1)
|
||||||
self.verticalLayout.setStretch(1, 1)
|
self.verticalLayout.setStretch(1, 1)
|
||||||
@ -218,17 +218,17 @@ class Ui_Signal_Label(object):
|
|||||||
Signal_Label.setWindowTitle(QCoreApplication.translate("Signal_Label", u"Signal_Label", None))
|
Signal_Label.setWindowTitle(QCoreApplication.translate("Signal_Label", u"Signal_Label", None))
|
||||||
self.label.setText(QCoreApplication.translate("Signal_Label", u"\u6570\u636e\u6839\u76ee\u5f55\uff1a", None))
|
self.label.setText(QCoreApplication.translate("Signal_Label", u"\u6570\u636e\u6839\u76ee\u5f55\uff1a", None))
|
||||||
self.pushButton_open.setText(QCoreApplication.translate("Signal_Label", u"\u6253\u5f00", None))
|
self.pushButton_open.setText(QCoreApplication.translate("Signal_Label", u"\u6253\u5f00", None))
|
||||||
self.pushButton_2.setText(QCoreApplication.translate("Signal_Label", u"\u6570\u636e\u7c97\u540c\u6b65", None))
|
self.pushButton_approximately_align.setText(QCoreApplication.translate("Signal_Label", u"\u6570\u636e\u7c97\u540c\u6b65", None))
|
||||||
self.pushButton_preprocess_BCG.setText(QCoreApplication.translate("Signal_Label", u"BCG\u7684\u9884\u5904\u7406", None))
|
self.pushButton_preprocess_BCG.setText(QCoreApplication.translate("Signal_Label", u"BCG\u7684\u9884\u5904\u7406", None))
|
||||||
self.pushButton_preprocess_ECG.setText(QCoreApplication.translate("Signal_Label", u"ECG\u7684\u9884\u5904\u7406", None))
|
self.pushButton_preprocess_ECG.setText(QCoreApplication.translate("Signal_Label", u"ECG\u7684\u9884\u5904\u7406", None))
|
||||||
self.pushButton_detect_Jpeak.setText(QCoreApplication.translate("Signal_Label", u"BCG\u7684J\u5cf0\u7b97\u6cd5\u5b9a\u4f4d", None))
|
self.pushButton_detect_Jpeak.setText(QCoreApplication.translate("Signal_Label", u"BCG\u7684J\u5cf0\u7b97\u6cd5\u5b9a\u4f4d", None))
|
||||||
self.pushButton_detect_Rpeak.setText(QCoreApplication.translate("Signal_Label", u"ECG\u7684R\u5cf0\u7b97\u6cd5\u5b9a\u4f4d", None))
|
self.pushButton_detect_Rpeak.setText(QCoreApplication.translate("Signal_Label", u"ECG\u7684R\u5cf0\u7b97\u6cd5\u5b9a\u4f4d", None))
|
||||||
self.pushButton_7.setText(QCoreApplication.translate("Signal_Label", u"BCG\u7684J\u5cf0\u4eba\u5de5\u7ea0\u6b63", None))
|
self.pushButton_label_check_BCG.setText(QCoreApplication.translate("Signal_Label", u"BCG\u7684J\u5cf0\u4eba\u5de5\u7ea0\u6b63", None))
|
||||||
self.pushButton_8.setText(QCoreApplication.translate("Signal_Label", u"ECG\u7684R\u5cf0\u4eba\u5de5\u7ea0\u6b63", None))
|
self.pushButton_label_check_ECG.setText(QCoreApplication.translate("Signal_Label", u"ECG\u7684R\u5cf0\u4eba\u5de5\u7ea0\u6b63", None))
|
||||||
self.pushButton_10.setText(QCoreApplication.translate("Signal_Label", u"\u6570\u636e\u7cbe\u540c\u6b65", None))
|
self.pushButton_precisely_align.setText(QCoreApplication.translate("Signal_Label", u"\u6570\u636e\u7cbe\u540c\u6b65", None))
|
||||||
self.pushButton_9.setText(QCoreApplication.translate("Signal_Label", u"\u4f53\u52a8\u6807\u6ce8", None))
|
self.pushButton_artifact_label.setText(QCoreApplication.translate("Signal_Label", u"\u4f53\u52a8\u6807\u6ce8", None))
|
||||||
self.pushButton_11.setText(QCoreApplication.translate("Signal_Label", u"BCG\u7684\u8d28\u91cf\u6807\u6ce8", None))
|
self.pushButton_bcg_quality_label.setText(QCoreApplication.translate("Signal_Label", u"BCG\u7684\u8d28\u91cf\u6807\u6ce8", None))
|
||||||
self.pushButton_12.setText(QCoreApplication.translate("Signal_Label", u"\u547c\u5438\u53ef\u7528\u6027\u53ca\u95f4\u671f\u6807\u6ce8", None))
|
self.pushButton_resp_quality_label.setText(QCoreApplication.translate("Signal_Label", u"\u547c\u5438\u53ef\u7528\u6027\u53ca\u95f4\u671f\u6807\u6ce8", None))
|
||||||
self.pushButton_13.setText(QCoreApplication.translate("Signal_Label", u"\u7761\u7720\u547c\u5438\u6682\u505c\u4e8b\u4ef6\u6807\u6ce8", None))
|
self.pushButton_SA_label.setText(QCoreApplication.translate("Signal_Label", u"\u7761\u7720\u547c\u5438\u6682\u505c\u4e8b\u4ef6\u6807\u6ce8", None))
|
||||||
# retranslateUi
|
# retranslateUi
|
||||||
|
|
||||||
|
|||||||
@ -85,7 +85,7 @@
|
|||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QPushButton" name="pushButton_2">
|
<widget class="QPushButton" name="pushButton_approximately_align">
|
||||||
<property name="sizePolicy">
|
<property name="sizePolicy">
|
||||||
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
||||||
<horstretch>0</horstretch>
|
<horstretch>0</horstretch>
|
||||||
@ -185,7 +185,7 @@
|
|||||||
<item>
|
<item>
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_6">
|
<layout class="QHBoxLayout" name="horizontalLayout_6">
|
||||||
<item>
|
<item>
|
||||||
<widget class="QPushButton" name="pushButton_7">
|
<widget class="QPushButton" name="pushButton_label_check_BCG">
|
||||||
<property name="sizePolicy">
|
<property name="sizePolicy">
|
||||||
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
||||||
<horstretch>0</horstretch>
|
<horstretch>0</horstretch>
|
||||||
@ -203,7 +203,7 @@
|
|||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QPushButton" name="pushButton_8">
|
<widget class="QPushButton" name="pushButton_label_check_ECG">
|
||||||
<property name="sizePolicy">
|
<property name="sizePolicy">
|
||||||
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
||||||
<horstretch>0</horstretch>
|
<horstretch>0</horstretch>
|
||||||
@ -223,7 +223,7 @@
|
|||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QPushButton" name="pushButton_10">
|
<widget class="QPushButton" name="pushButton_precisely_align">
|
||||||
<property name="sizePolicy">
|
<property name="sizePolicy">
|
||||||
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
||||||
<horstretch>0</horstretch>
|
<horstretch>0</horstretch>
|
||||||
@ -241,7 +241,7 @@
|
|||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QPushButton" name="pushButton_9">
|
<widget class="QPushButton" name="pushButton_artifact_label">
|
||||||
<property name="sizePolicy">
|
<property name="sizePolicy">
|
||||||
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
||||||
<horstretch>0</horstretch>
|
<horstretch>0</horstretch>
|
||||||
@ -259,7 +259,7 @@
|
|||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QPushButton" name="pushButton_11">
|
<widget class="QPushButton" name="pushButton_bcg_quality_label">
|
||||||
<property name="sizePolicy">
|
<property name="sizePolicy">
|
||||||
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
||||||
<horstretch>0</horstretch>
|
<horstretch>0</horstretch>
|
||||||
@ -277,7 +277,7 @@
|
|||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QPushButton" name="pushButton_12">
|
<widget class="QPushButton" name="pushButton_resp_quality_label">
|
||||||
<property name="sizePolicy">
|
<property name="sizePolicy">
|
||||||
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
||||||
<horstretch>0</horstretch>
|
<horstretch>0</horstretch>
|
||||||
@ -295,7 +295,7 @@
|
|||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QPushButton" name="pushButton_13">
|
<widget class="QPushButton" name="pushButton_SA_label">
|
||||||
<property name="sizePolicy">
|
<property name="sizePolicy">
|
||||||
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
|
||||||
<horstretch>0</horstretch>
|
<horstretch>0</horstretch>
|
||||||
|
|||||||
368
ui/MainWindow/MainWindow_precisely_align.py
Normal file
368
ui/MainWindow/MainWindow_precisely_align.py
Normal file
@ -0,0 +1,368 @@
|
|||||||
|
# -*- coding: utf-8 -*-
|
||||||
|
|
||||||
|
################################################################################
|
||||||
|
## Form generated from reading UI file 'MainWindow_precisely_align.ui'
|
||||||
|
##
|
||||||
|
## Created by: Qt User Interface Compiler version 6.8.2
|
||||||
|
##
|
||||||
|
## WARNING! All changes made in this file will be lost when recompiling UI file!
|
||||||
|
################################################################################
|
||||||
|
|
||||||
|
from PySide6.QtCore import (QCoreApplication, QDate, QDateTime, QLocale,
|
||||||
|
QMetaObject, QObject, QPoint, QRect,
|
||||||
|
QSize, QTime, QUrl, Qt)
|
||||||
|
from PySide6.QtGui import (QAction, QBrush, QColor, QConicalGradient,
|
||||||
|
QCursor, QFont, QFontDatabase, QGradient,
|
||||||
|
QIcon, QImage, QKeySequence, QLinearGradient,
|
||||||
|
QPainter, QPalette, QPixmap, QRadialGradient,
|
||||||
|
QTransform)
|
||||||
|
from PySide6.QtWidgets import (QAbstractSpinBox, QApplication, QGridLayout, QGroupBox,
|
||||||
|
QHBoxLayout, QLabel, QMainWindow, QPushButton,
|
||||||
|
QSizePolicy, QSpacerItem, QSpinBox, QStatusBar,
|
||||||
|
QTextBrowser, QVBoxLayout, QWidget)
|
||||||
|
|
||||||
|
class Ui_MainWindow_detect_Jpeak(object):
|
||||||
|
def setupUi(self, MainWindow_detect_Jpeak):
|
||||||
|
if not MainWindow_detect_Jpeak.objectName():
|
||||||
|
MainWindow_detect_Jpeak.setObjectName(u"MainWindow_detect_Jpeak")
|
||||||
|
MainWindow_detect_Jpeak.setEnabled(True)
|
||||||
|
MainWindow_detect_Jpeak.resize(1920, 1080)
|
||||||
|
sizePolicy = QSizePolicy(QSizePolicy.Policy.Ignored, QSizePolicy.Policy.Preferred)
|
||||||
|
sizePolicy.setHorizontalStretch(0)
|
||||||
|
sizePolicy.setVerticalStretch(0)
|
||||||
|
sizePolicy.setHeightForWidth(MainWindow_detect_Jpeak.sizePolicy().hasHeightForWidth())
|
||||||
|
MainWindow_detect_Jpeak.setSizePolicy(sizePolicy)
|
||||||
|
font = QFont()
|
||||||
|
font.setPointSize(12)
|
||||||
|
MainWindow_detect_Jpeak.setFont(font)
|
||||||
|
self.action_selectPath = QAction(MainWindow_detect_Jpeak)
|
||||||
|
self.action_selectPath.setObjectName(u"action_selectPath")
|
||||||
|
font1 = QFont()
|
||||||
|
font1.setFamilies([u"\u9ed1\u4f53"])
|
||||||
|
font1.setPointSize(14)
|
||||||
|
self.action_selectPath.setFont(font1)
|
||||||
|
self.action = QAction(MainWindow_detect_Jpeak)
|
||||||
|
self.action.setObjectName(u"action")
|
||||||
|
self.action.setFont(font1)
|
||||||
|
self.centralwidget = QWidget(MainWindow_detect_Jpeak)
|
||||||
|
self.centralwidget.setObjectName(u"centralwidget")
|
||||||
|
self.gridLayout = QGridLayout(self.centralwidget)
|
||||||
|
self.gridLayout.setObjectName(u"gridLayout")
|
||||||
|
self.groupBox_canvas = QGroupBox(self.centralwidget)
|
||||||
|
self.groupBox_canvas.setObjectName(u"groupBox_canvas")
|
||||||
|
font2 = QFont()
|
||||||
|
font2.setPointSize(10)
|
||||||
|
self.groupBox_canvas.setFont(font2)
|
||||||
|
self.verticalLayout_7 = QVBoxLayout(self.groupBox_canvas)
|
||||||
|
self.verticalLayout_7.setObjectName(u"verticalLayout_7")
|
||||||
|
self.verticalLayout_canvas = QVBoxLayout()
|
||||||
|
self.verticalLayout_canvas.setObjectName(u"verticalLayout_canvas")
|
||||||
|
|
||||||
|
self.verticalLayout_7.addLayout(self.verticalLayout_canvas)
|
||||||
|
|
||||||
|
|
||||||
|
self.gridLayout.addWidget(self.groupBox_canvas, 0, 1, 1, 1)
|
||||||
|
|
||||||
|
self.groupBox_left = QGroupBox(self.centralwidget)
|
||||||
|
self.groupBox_left.setObjectName(u"groupBox_left")
|
||||||
|
self.groupBox_left.setFont(font2)
|
||||||
|
self.verticalLayout = QVBoxLayout(self.groupBox_left)
|
||||||
|
self.verticalLayout.setObjectName(u"verticalLayout")
|
||||||
|
self.horizontalLayout_4 = QHBoxLayout()
|
||||||
|
self.horizontalLayout_4.setObjectName(u"horizontalLayout_4")
|
||||||
|
self.pushButton_input_setting = QPushButton(self.groupBox_left)
|
||||||
|
self.pushButton_input_setting.setObjectName(u"pushButton_input_setting")
|
||||||
|
sizePolicy1 = QSizePolicy(QSizePolicy.Policy.Minimum, QSizePolicy.Policy.Minimum)
|
||||||
|
sizePolicy1.setHorizontalStretch(0)
|
||||||
|
sizePolicy1.setVerticalStretch(0)
|
||||||
|
sizePolicy1.setHeightForWidth(self.pushButton_input_setting.sizePolicy().hasHeightForWidth())
|
||||||
|
self.pushButton_input_setting.setSizePolicy(sizePolicy1)
|
||||||
|
self.pushButton_input_setting.setFont(font)
|
||||||
|
|
||||||
|
self.horizontalLayout_4.addWidget(self.pushButton_input_setting)
|
||||||
|
|
||||||
|
self.pushButton_input = QPushButton(self.groupBox_left)
|
||||||
|
self.pushButton_input.setObjectName(u"pushButton_input")
|
||||||
|
sizePolicy1.setHeightForWidth(self.pushButton_input.sizePolicy().hasHeightForWidth())
|
||||||
|
self.pushButton_input.setSizePolicy(sizePolicy1)
|
||||||
|
self.pushButton_input.setFont(font)
|
||||||
|
|
||||||
|
self.horizontalLayout_4.addWidget(self.pushButton_input)
|
||||||
|
|
||||||
|
|
||||||
|
self.verticalLayout.addLayout(self.horizontalLayout_4)
|
||||||
|
|
||||||
|
self.groupBox_args = QGroupBox(self.groupBox_left)
|
||||||
|
self.groupBox_args.setObjectName(u"groupBox_args")
|
||||||
|
self.verticalLayout_5 = QVBoxLayout(self.groupBox_args)
|
||||||
|
self.verticalLayout_5.setObjectName(u"verticalLayout_5")
|
||||||
|
self.groupBox_2 = QGroupBox(self.groupBox_args)
|
||||||
|
self.groupBox_2.setObjectName(u"groupBox_2")
|
||||||
|
self.verticalLayout_2 = QVBoxLayout(self.groupBox_2)
|
||||||
|
self.verticalLayout_2.setObjectName(u"verticalLayout_2")
|
||||||
|
self.horizontalLayout_2 = QHBoxLayout()
|
||||||
|
self.horizontalLayout_2.setObjectName(u"horizontalLayout_2")
|
||||||
|
self.label_3 = QLabel(self.groupBox_2)
|
||||||
|
self.label_3.setObjectName(u"label_3")
|
||||||
|
self.label_3.setFont(font)
|
||||||
|
self.label_3.setAlignment(Qt.AlignmentFlag.AlignCenter)
|
||||||
|
|
||||||
|
self.horizontalLayout_2.addWidget(self.label_3)
|
||||||
|
|
||||||
|
self.spinBox_BCG_front_1 = QSpinBox(self.groupBox_2)
|
||||||
|
self.spinBox_BCG_front_1.setObjectName(u"spinBox_BCG_front_1")
|
||||||
|
self.spinBox_BCG_front_1.setFont(font)
|
||||||
|
self.spinBox_BCG_front_1.setButtonSymbols(QAbstractSpinBox.ButtonSymbols.NoButtons)
|
||||||
|
self.spinBox_BCG_front_1.setMinimum(0)
|
||||||
|
self.spinBox_BCG_front_1.setMaximum(1000000000)
|
||||||
|
|
||||||
|
self.horizontalLayout_2.addWidget(self.spinBox_BCG_front_1)
|
||||||
|
|
||||||
|
self.label_4 = QLabel(self.groupBox_2)
|
||||||
|
self.label_4.setObjectName(u"label_4")
|
||||||
|
self.label_4.setFont(font)
|
||||||
|
self.label_4.setAlignment(Qt.AlignmentFlag.AlignCenter)
|
||||||
|
|
||||||
|
self.horizontalLayout_2.addWidget(self.label_4)
|
||||||
|
|
||||||
|
self.spinBox_BCG_front_2 = QSpinBox(self.groupBox_2)
|
||||||
|
self.spinBox_BCG_front_2.setObjectName(u"spinBox_BCG_front_2")
|
||||||
|
self.spinBox_BCG_front_2.setFont(font)
|
||||||
|
self.spinBox_BCG_front_2.setButtonSymbols(QAbstractSpinBox.ButtonSymbols.NoButtons)
|
||||||
|
self.spinBox_BCG_front_2.setMinimum(0)
|
||||||
|
self.spinBox_BCG_front_2.setMaximum(1000000000)
|
||||||
|
|
||||||
|
self.horizontalLayout_2.addWidget(self.spinBox_BCG_front_2)
|
||||||
|
|
||||||
|
|
||||||
|
self.verticalLayout_2.addLayout(self.horizontalLayout_2)
|
||||||
|
|
||||||
|
self.horizontalLayout_5 = QHBoxLayout()
|
||||||
|
self.horizontalLayout_5.setObjectName(u"horizontalLayout_5")
|
||||||
|
self.label_5 = QLabel(self.groupBox_2)
|
||||||
|
self.label_5.setObjectName(u"label_5")
|
||||||
|
self.label_5.setFont(font)
|
||||||
|
self.label_5.setAlignment(Qt.AlignmentFlag.AlignCenter)
|
||||||
|
|
||||||
|
self.horizontalLayout_5.addWidget(self.label_5)
|
||||||
|
|
||||||
|
self.spinBox_ECG_front_1 = QSpinBox(self.groupBox_2)
|
||||||
|
self.spinBox_ECG_front_1.setObjectName(u"spinBox_ECG_front_1")
|
||||||
|
self.spinBox_ECG_front_1.setFont(font)
|
||||||
|
self.spinBox_ECG_front_1.setButtonSymbols(QAbstractSpinBox.ButtonSymbols.NoButtons)
|
||||||
|
self.spinBox_ECG_front_1.setMinimum(0)
|
||||||
|
self.spinBox_ECG_front_1.setMaximum(1000000000)
|
||||||
|
|
||||||
|
self.horizontalLayout_5.addWidget(self.spinBox_ECG_front_1)
|
||||||
|
|
||||||
|
self.label_6 = QLabel(self.groupBox_2)
|
||||||
|
self.label_6.setObjectName(u"label_6")
|
||||||
|
self.label_6.setFont(font)
|
||||||
|
self.label_6.setAlignment(Qt.AlignmentFlag.AlignCenter)
|
||||||
|
|
||||||
|
self.horizontalLayout_5.addWidget(self.label_6)
|
||||||
|
|
||||||
|
self.spinBox_ECG_front_2 = QSpinBox(self.groupBox_2)
|
||||||
|
self.spinBox_ECG_front_2.setObjectName(u"spinBox_ECG_front_2")
|
||||||
|
self.spinBox_ECG_front_2.setFont(font)
|
||||||
|
self.spinBox_ECG_front_2.setButtonSymbols(QAbstractSpinBox.ButtonSymbols.NoButtons)
|
||||||
|
self.spinBox_ECG_front_2.setMinimum(0)
|
||||||
|
self.spinBox_ECG_front_2.setMaximum(1000000000)
|
||||||
|
|
||||||
|
self.horizontalLayout_5.addWidget(self.spinBox_ECG_front_2)
|
||||||
|
|
||||||
|
|
||||||
|
self.verticalLayout_2.addLayout(self.horizontalLayout_5)
|
||||||
|
|
||||||
|
|
||||||
|
self.verticalLayout_5.addWidget(self.groupBox_2)
|
||||||
|
|
||||||
|
self.groupBox_3 = QGroupBox(self.groupBox_args)
|
||||||
|
self.groupBox_3.setObjectName(u"groupBox_3")
|
||||||
|
self.verticalLayout_3 = QVBoxLayout(self.groupBox_3)
|
||||||
|
self.verticalLayout_3.setObjectName(u"verticalLayout_3")
|
||||||
|
self.horizontalLayout_6 = QHBoxLayout()
|
||||||
|
self.horizontalLayout_6.setObjectName(u"horizontalLayout_6")
|
||||||
|
self.label_7 = QLabel(self.groupBox_3)
|
||||||
|
self.label_7.setObjectName(u"label_7")
|
||||||
|
self.label_7.setFont(font)
|
||||||
|
self.label_7.setAlignment(Qt.AlignmentFlag.AlignCenter)
|
||||||
|
|
||||||
|
self.horizontalLayout_6.addWidget(self.label_7)
|
||||||
|
|
||||||
|
self.spinBox_BCG_back_1 = QSpinBox(self.groupBox_3)
|
||||||
|
self.spinBox_BCG_back_1.setObjectName(u"spinBox_BCG_back_1")
|
||||||
|
self.spinBox_BCG_back_1.setFont(font)
|
||||||
|
self.spinBox_BCG_back_1.setButtonSymbols(QAbstractSpinBox.ButtonSymbols.NoButtons)
|
||||||
|
self.spinBox_BCG_back_1.setMinimum(0)
|
||||||
|
self.spinBox_BCG_back_1.setMaximum(1000000000)
|
||||||
|
|
||||||
|
self.horizontalLayout_6.addWidget(self.spinBox_BCG_back_1)
|
||||||
|
|
||||||
|
self.label_8 = QLabel(self.groupBox_3)
|
||||||
|
self.label_8.setObjectName(u"label_8")
|
||||||
|
self.label_8.setFont(font)
|
||||||
|
self.label_8.setAlignment(Qt.AlignmentFlag.AlignCenter)
|
||||||
|
|
||||||
|
self.horizontalLayout_6.addWidget(self.label_8)
|
||||||
|
|
||||||
|
self.spinBox_BCG_back_2 = QSpinBox(self.groupBox_3)
|
||||||
|
self.spinBox_BCG_back_2.setObjectName(u"spinBox_BCG_back_2")
|
||||||
|
self.spinBox_BCG_back_2.setFont(font)
|
||||||
|
self.spinBox_BCG_back_2.setButtonSymbols(QAbstractSpinBox.ButtonSymbols.NoButtons)
|
||||||
|
self.spinBox_BCG_back_2.setMinimum(0)
|
||||||
|
self.spinBox_BCG_back_2.setMaximum(1000000000)
|
||||||
|
|
||||||
|
self.horizontalLayout_6.addWidget(self.spinBox_BCG_back_2)
|
||||||
|
|
||||||
|
|
||||||
|
self.verticalLayout_3.addLayout(self.horizontalLayout_6)
|
||||||
|
|
||||||
|
self.horizontalLayout_7 = QHBoxLayout()
|
||||||
|
self.horizontalLayout_7.setObjectName(u"horizontalLayout_7")
|
||||||
|
self.label_9 = QLabel(self.groupBox_3)
|
||||||
|
self.label_9.setObjectName(u"label_9")
|
||||||
|
self.label_9.setFont(font)
|
||||||
|
self.label_9.setAlignment(Qt.AlignmentFlag.AlignCenter)
|
||||||
|
|
||||||
|
self.horizontalLayout_7.addWidget(self.label_9)
|
||||||
|
|
||||||
|
self.spinBox_ECG_back_1 = QSpinBox(self.groupBox_3)
|
||||||
|
self.spinBox_ECG_back_1.setObjectName(u"spinBox_ECG_back_1")
|
||||||
|
self.spinBox_ECG_back_1.setFont(font)
|
||||||
|
self.spinBox_ECG_back_1.setButtonSymbols(QAbstractSpinBox.ButtonSymbols.NoButtons)
|
||||||
|
self.spinBox_ECG_back_1.setMinimum(0)
|
||||||
|
self.spinBox_ECG_back_1.setMaximum(1000000000)
|
||||||
|
|
||||||
|
self.horizontalLayout_7.addWidget(self.spinBox_ECG_back_1)
|
||||||
|
|
||||||
|
self.label_10 = QLabel(self.groupBox_3)
|
||||||
|
self.label_10.setObjectName(u"label_10")
|
||||||
|
self.label_10.setFont(font)
|
||||||
|
self.label_10.setAlignment(Qt.AlignmentFlag.AlignCenter)
|
||||||
|
|
||||||
|
self.horizontalLayout_7.addWidget(self.label_10)
|
||||||
|
|
||||||
|
self.spinBox_ECG_back_2 = QSpinBox(self.groupBox_3)
|
||||||
|
self.spinBox_ECG_back_2.setObjectName(u"spinBox_ECG_back_2")
|
||||||
|
self.spinBox_ECG_back_2.setFont(font)
|
||||||
|
self.spinBox_ECG_back_2.setButtonSymbols(QAbstractSpinBox.ButtonSymbols.NoButtons)
|
||||||
|
self.spinBox_ECG_back_2.setMinimum(0)
|
||||||
|
self.spinBox_ECG_back_2.setMaximum(1000000000)
|
||||||
|
|
||||||
|
self.horizontalLayout_7.addWidget(self.spinBox_ECG_back_2)
|
||||||
|
|
||||||
|
|
||||||
|
self.verticalLayout_3.addLayout(self.horizontalLayout_7)
|
||||||
|
|
||||||
|
|
||||||
|
self.verticalLayout_5.addWidget(self.groupBox_3)
|
||||||
|
|
||||||
|
|
||||||
|
self.verticalLayout.addWidget(self.groupBox_args)
|
||||||
|
|
||||||
|
self.verticalSpacer = QSpacerItem(20, 40, QSizePolicy.Policy.Minimum, QSizePolicy.Policy.Expanding)
|
||||||
|
|
||||||
|
self.verticalLayout.addItem(self.verticalSpacer)
|
||||||
|
|
||||||
|
self.horizontalLayout_8 = QHBoxLayout()
|
||||||
|
self.horizontalLayout_8.setObjectName(u"horizontalLayout_8")
|
||||||
|
self.pushButton_calculate_correlation = QPushButton(self.groupBox_left)
|
||||||
|
self.pushButton_calculate_correlation.setObjectName(u"pushButton_calculate_correlation")
|
||||||
|
sizePolicy1.setHeightForWidth(self.pushButton_calculate_correlation.sizePolicy().hasHeightForWidth())
|
||||||
|
self.pushButton_calculate_correlation.setSizePolicy(sizePolicy1)
|
||||||
|
self.pushButton_calculate_correlation.setFont(font)
|
||||||
|
|
||||||
|
self.horizontalLayout_8.addWidget(self.pushButton_calculate_correlation)
|
||||||
|
|
||||||
|
self.pushButton_correlation_align = QPushButton(self.groupBox_left)
|
||||||
|
self.pushButton_correlation_align.setObjectName(u"pushButton_correlation_align")
|
||||||
|
sizePolicy1.setHeightForWidth(self.pushButton_correlation_align.sizePolicy().hasHeightForWidth())
|
||||||
|
self.pushButton_correlation_align.setSizePolicy(sizePolicy1)
|
||||||
|
self.pushButton_correlation_align.setFont(font)
|
||||||
|
|
||||||
|
self.horizontalLayout_8.addWidget(self.pushButton_correlation_align)
|
||||||
|
|
||||||
|
|
||||||
|
self.verticalLayout.addLayout(self.horizontalLayout_8)
|
||||||
|
|
||||||
|
self.horizontalLayout_3 = QHBoxLayout()
|
||||||
|
self.horizontalLayout_3.setObjectName(u"horizontalLayout_3")
|
||||||
|
self.pushButton_precise_align = QPushButton(self.groupBox_left)
|
||||||
|
self.pushButton_precise_align.setObjectName(u"pushButton_precise_align")
|
||||||
|
sizePolicy1.setHeightForWidth(self.pushButton_precise_align.sizePolicy().hasHeightForWidth())
|
||||||
|
self.pushButton_precise_align.setSizePolicy(sizePolicy1)
|
||||||
|
self.pushButton_precise_align.setFont(font)
|
||||||
|
|
||||||
|
self.horizontalLayout_3.addWidget(self.pushButton_precise_align)
|
||||||
|
|
||||||
|
self.pushButton_save = QPushButton(self.groupBox_left)
|
||||||
|
self.pushButton_save.setObjectName(u"pushButton_save")
|
||||||
|
sizePolicy1.setHeightForWidth(self.pushButton_save.sizePolicy().hasHeightForWidth())
|
||||||
|
self.pushButton_save.setSizePolicy(sizePolicy1)
|
||||||
|
self.pushButton_save.setFont(font)
|
||||||
|
|
||||||
|
self.horizontalLayout_3.addWidget(self.pushButton_save)
|
||||||
|
|
||||||
|
|
||||||
|
self.verticalLayout.addLayout(self.horizontalLayout_3)
|
||||||
|
|
||||||
|
self.groupBox = QGroupBox(self.groupBox_left)
|
||||||
|
self.groupBox.setObjectName(u"groupBox")
|
||||||
|
self.verticalLayout_6 = QVBoxLayout(self.groupBox)
|
||||||
|
self.verticalLayout_6.setObjectName(u"verticalLayout_6")
|
||||||
|
self.textBrowser_info = QTextBrowser(self.groupBox)
|
||||||
|
self.textBrowser_info.setObjectName(u"textBrowser_info")
|
||||||
|
|
||||||
|
self.verticalLayout_6.addWidget(self.textBrowser_info)
|
||||||
|
|
||||||
|
|
||||||
|
self.verticalLayout.addWidget(self.groupBox)
|
||||||
|
|
||||||
|
self.verticalLayout.setStretch(0, 1)
|
||||||
|
self.verticalLayout.setStretch(1, 7)
|
||||||
|
self.verticalLayout.setStretch(2, 3)
|
||||||
|
self.verticalLayout.setStretch(3, 1)
|
||||||
|
self.verticalLayout.setStretch(4, 1)
|
||||||
|
self.verticalLayout.setStretch(5, 5)
|
||||||
|
|
||||||
|
self.gridLayout.addWidget(self.groupBox_left, 0, 0, 1, 1)
|
||||||
|
|
||||||
|
self.gridLayout.setColumnStretch(0, 2)
|
||||||
|
self.gridLayout.setColumnStretch(1, 8)
|
||||||
|
MainWindow_detect_Jpeak.setCentralWidget(self.centralwidget)
|
||||||
|
self.statusbar = QStatusBar(MainWindow_detect_Jpeak)
|
||||||
|
self.statusbar.setObjectName(u"statusbar")
|
||||||
|
MainWindow_detect_Jpeak.setStatusBar(self.statusbar)
|
||||||
|
|
||||||
|
self.retranslateUi(MainWindow_detect_Jpeak)
|
||||||
|
|
||||||
|
QMetaObject.connectSlotsByName(MainWindow_detect_Jpeak)
|
||||||
|
# setupUi
|
||||||
|
|
||||||
|
def retranslateUi(self, MainWindow_detect_Jpeak):
|
||||||
|
MainWindow_detect_Jpeak.setWindowTitle(QCoreApplication.translate("MainWindow_detect_Jpeak", u"\u6570\u636e\u7cbe\u540c\u6b65", None))
|
||||||
|
self.action_selectPath.setText(QCoreApplication.translate("MainWindow_detect_Jpeak", u"\u6570\u636e\u8def\u5f84\u9009\u62e9", None))
|
||||||
|
self.action.setText(QCoreApplication.translate("MainWindow_detect_Jpeak", u"\u52a0\u8f7d\u5b58\u6863", None))
|
||||||
|
self.groupBox_canvas.setTitle(QCoreApplication.translate("MainWindow_detect_Jpeak", u"\u7ed8\u56fe\u533a", None))
|
||||||
|
self.groupBox_left.setTitle(QCoreApplication.translate("MainWindow_detect_Jpeak", u"\u9884\u5904\u7406", None))
|
||||||
|
self.pushButton_input_setting.setText(QCoreApplication.translate("MainWindow_detect_Jpeak", u"\u5bfc\u5165\u8bbe\u7f6e", None))
|
||||||
|
self.pushButton_input.setText(QCoreApplication.translate("MainWindow_detect_Jpeak", u"\u5f00\u59cb\u5bfc\u5165", None))
|
||||||
|
self.groupBox_args.setTitle(QCoreApplication.translate("MainWindow_detect_Jpeak", u"\u53c2\u6570\u8f93\u5165", None))
|
||||||
|
self.groupBox_2.setTitle(QCoreApplication.translate("MainWindow_detect_Jpeak", u"\u524d\u6bb5\u533a\u95f4\u5750\u6807\u53d6\u503c", None))
|
||||||
|
self.label_3.setText(QCoreApplication.translate("MainWindow_detect_Jpeak", u"BCG", None))
|
||||||
|
self.label_4.setText(QCoreApplication.translate("MainWindow_detect_Jpeak", u"~", None))
|
||||||
|
self.label_5.setText(QCoreApplication.translate("MainWindow_detect_Jpeak", u"ECG", None))
|
||||||
|
self.label_6.setText(QCoreApplication.translate("MainWindow_detect_Jpeak", u"~", None))
|
||||||
|
self.groupBox_3.setTitle(QCoreApplication.translate("MainWindow_detect_Jpeak", u"\u540e\u6bb5\u533a\u95f4\u5750\u6807\u53d6\u503c", None))
|
||||||
|
self.label_7.setText(QCoreApplication.translate("MainWindow_detect_Jpeak", u"BCG", None))
|
||||||
|
self.label_8.setText(QCoreApplication.translate("MainWindow_detect_Jpeak", u"~", None))
|
||||||
|
self.label_9.setText(QCoreApplication.translate("MainWindow_detect_Jpeak", u"ECG", None))
|
||||||
|
self.label_10.setText(QCoreApplication.translate("MainWindow_detect_Jpeak", u"~", None))
|
||||||
|
self.pushButton_calculate_correlation.setText(QCoreApplication.translate("MainWindow_detect_Jpeak", u"\u8ba1\u7b97\u76f8\u5173\u6027", None))
|
||||||
|
self.pushButton_correlation_align.setText(QCoreApplication.translate("MainWindow_detect_Jpeak", u"\u76f8\u5173\u5bf9\u9f50", None))
|
||||||
|
self.pushButton_precise_align.setText(QCoreApplication.translate("MainWindow_detect_Jpeak", u"\u7cbe\u7ec6\u5bf9\u9f50", None))
|
||||||
|
self.pushButton_save.setText(QCoreApplication.translate("MainWindow_detect_Jpeak", u"\u4fdd\u5b58\u7ed3\u679c", None))
|
||||||
|
self.groupBox.setTitle(QCoreApplication.translate("MainWindow_detect_Jpeak", u"\u65e5\u5fd7", None))
|
||||||
|
# retranslateUi
|
||||||
|
|
||||||
543
ui/MainWindow/MainWindow_precisely_align.ui
Normal file
543
ui/MainWindow/MainWindow_precisely_align.ui
Normal file
@ -0,0 +1,543 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<ui version="4.0">
|
||||||
|
<class>MainWindow_detect_Jpeak</class>
|
||||||
|
<widget class="QMainWindow" name="MainWindow_detect_Jpeak">
|
||||||
|
<property name="enabled">
|
||||||
|
<bool>true</bool>
|
||||||
|
</property>
|
||||||
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>0</x>
|
||||||
|
<y>0</y>
|
||||||
|
<width>1920</width>
|
||||||
|
<height>1080</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Ignored" vsizetype="Preferred">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="windowTitle">
|
||||||
|
<string>数据精同步</string>
|
||||||
|
</property>
|
||||||
|
<widget class="QWidget" name="centralwidget">
|
||||||
|
<layout class="QGridLayout" name="gridLayout" columnstretch="2,8">
|
||||||
|
<item row="0" column="1">
|
||||||
|
<widget class="QGroupBox" name="groupBox_canvas">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>10</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="title">
|
||||||
|
<string>绘图区</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_7">
|
||||||
|
<item>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_canvas"/>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="0">
|
||||||
|
<widget class="QGroupBox" name="groupBox_left">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>10</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="title">
|
||||||
|
<string>预处理</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout" stretch="1,7,3,1,1,5">
|
||||||
|
<item>
|
||||||
|
<layout class="QHBoxLayout" name="horizontalLayout_4">
|
||||||
|
<item>
|
||||||
|
<widget class="QPushButton" name="pushButton_input_setting">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Minimum" vsizetype="Minimum">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>导入设置</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QPushButton" name="pushButton_input">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Minimum" vsizetype="Minimum">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>开始导入</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QGroupBox" name="groupBox_args">
|
||||||
|
<property name="title">
|
||||||
|
<string>参数输入</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_5" stretch="0,0">
|
||||||
|
<item>
|
||||||
|
<widget class="QGroupBox" name="groupBox_2">
|
||||||
|
<property name="title">
|
||||||
|
<string>前段区间坐标取值</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||||
|
<item>
|
||||||
|
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="label_3">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>BCG</string>
|
||||||
|
</property>
|
||||||
|
<property name="alignment">
|
||||||
|
<set>Qt::AlignmentFlag::AlignCenter</set>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QSpinBox" name="spinBox_BCG_front_1">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="buttonSymbols">
|
||||||
|
<enum>QAbstractSpinBox::ButtonSymbols::NoButtons</enum>
|
||||||
|
</property>
|
||||||
|
<property name="minimum">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="maximum">
|
||||||
|
<number>1000000000</number>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="label_4">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>~</string>
|
||||||
|
</property>
|
||||||
|
<property name="alignment">
|
||||||
|
<set>Qt::AlignmentFlag::AlignCenter</set>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QSpinBox" name="spinBox_BCG_front_2">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="buttonSymbols">
|
||||||
|
<enum>QAbstractSpinBox::ButtonSymbols::NoButtons</enum>
|
||||||
|
</property>
|
||||||
|
<property name="minimum">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="maximum">
|
||||||
|
<number>1000000000</number>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<layout class="QHBoxLayout" name="horizontalLayout_5">
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="label_5">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>ECG</string>
|
||||||
|
</property>
|
||||||
|
<property name="alignment">
|
||||||
|
<set>Qt::AlignmentFlag::AlignCenter</set>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QSpinBox" name="spinBox_ECG_front_1">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="buttonSymbols">
|
||||||
|
<enum>QAbstractSpinBox::ButtonSymbols::NoButtons</enum>
|
||||||
|
</property>
|
||||||
|
<property name="minimum">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="maximum">
|
||||||
|
<number>1000000000</number>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="label_6">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>~</string>
|
||||||
|
</property>
|
||||||
|
<property name="alignment">
|
||||||
|
<set>Qt::AlignmentFlag::AlignCenter</set>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QSpinBox" name="spinBox_ECG_front_2">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="buttonSymbols">
|
||||||
|
<enum>QAbstractSpinBox::ButtonSymbols::NoButtons</enum>
|
||||||
|
</property>
|
||||||
|
<property name="minimum">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="maximum">
|
||||||
|
<number>1000000000</number>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QGroupBox" name="groupBox_3">
|
||||||
|
<property name="title">
|
||||||
|
<string>后段区间坐标取值</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_3">
|
||||||
|
<item>
|
||||||
|
<layout class="QHBoxLayout" name="horizontalLayout_6">
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="label_7">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>BCG</string>
|
||||||
|
</property>
|
||||||
|
<property name="alignment">
|
||||||
|
<set>Qt::AlignmentFlag::AlignCenter</set>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QSpinBox" name="spinBox_BCG_back_1">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="buttonSymbols">
|
||||||
|
<enum>QAbstractSpinBox::ButtonSymbols::NoButtons</enum>
|
||||||
|
</property>
|
||||||
|
<property name="minimum">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="maximum">
|
||||||
|
<number>1000000000</number>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="label_8">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>~</string>
|
||||||
|
</property>
|
||||||
|
<property name="alignment">
|
||||||
|
<set>Qt::AlignmentFlag::AlignCenter</set>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QSpinBox" name="spinBox_BCG_back_2">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="buttonSymbols">
|
||||||
|
<enum>QAbstractSpinBox::ButtonSymbols::NoButtons</enum>
|
||||||
|
</property>
|
||||||
|
<property name="minimum">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="maximum">
|
||||||
|
<number>1000000000</number>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<layout class="QHBoxLayout" name="horizontalLayout_7">
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="label_9">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>ECG</string>
|
||||||
|
</property>
|
||||||
|
<property name="alignment">
|
||||||
|
<set>Qt::AlignmentFlag::AlignCenter</set>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QSpinBox" name="spinBox_ECG_back_1">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="buttonSymbols">
|
||||||
|
<enum>QAbstractSpinBox::ButtonSymbols::NoButtons</enum>
|
||||||
|
</property>
|
||||||
|
<property name="minimum">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="maximum">
|
||||||
|
<number>1000000000</number>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="label_10">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>~</string>
|
||||||
|
</property>
|
||||||
|
<property name="alignment">
|
||||||
|
<set>Qt::AlignmentFlag::AlignCenter</set>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QSpinBox" name="spinBox_ECG_back_2">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="buttonSymbols">
|
||||||
|
<enum>QAbstractSpinBox::ButtonSymbols::NoButtons</enum>
|
||||||
|
</property>
|
||||||
|
<property name="minimum">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="maximum">
|
||||||
|
<number>1000000000</number>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<spacer name="verticalSpacer">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Orientation::Vertical</enum>
|
||||||
|
</property>
|
||||||
|
<property name="sizeHint" stdset="0">
|
||||||
|
<size>
|
||||||
|
<width>20</width>
|
||||||
|
<height>40</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
</spacer>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<layout class="QHBoxLayout" name="horizontalLayout_8">
|
||||||
|
<item>
|
||||||
|
<widget class="QPushButton" name="pushButton_calculate_correlation">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Minimum" vsizetype="Minimum">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>计算相关性</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QPushButton" name="pushButton_correlation_align">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Minimum" vsizetype="Minimum">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>相关对齐</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<layout class="QHBoxLayout" name="horizontalLayout_3">
|
||||||
|
<item>
|
||||||
|
<widget class="QPushButton" name="pushButton_precise_align">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Minimum" vsizetype="Minimum">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>精细对齐</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QPushButton" name="pushButton_save">
|
||||||
|
<property name="sizePolicy">
|
||||||
|
<sizepolicy hsizetype="Minimum" vsizetype="Minimum">
|
||||||
|
<horstretch>0</horstretch>
|
||||||
|
<verstretch>0</verstretch>
|
||||||
|
</sizepolicy>
|
||||||
|
</property>
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>保存结果</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QGroupBox" name="groupBox">
|
||||||
|
<property name="title">
|
||||||
|
<string>日志</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_6">
|
||||||
|
<item>
|
||||||
|
<widget class="QTextBrowser" name="textBrowser_info"/>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
<widget class="QStatusBar" name="statusbar"/>
|
||||||
|
<action name="action_selectPath">
|
||||||
|
<property name="text">
|
||||||
|
<string>数据路径选择</string>
|
||||||
|
</property>
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<family>黑体</family>
|
||||||
|
<pointsize>14</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
</action>
|
||||||
|
<action name="action">
|
||||||
|
<property name="text">
|
||||||
|
<string>加载存档</string>
|
||||||
|
</property>
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<family>黑体</family>
|
||||||
|
<pointsize>14</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
</action>
|
||||||
|
</widget>
|
||||||
|
<resources/>
|
||||||
|
<connections/>
|
||||||
|
</ui>
|
||||||
@ -15,10 +15,10 @@ from PySide6.QtGui import (QBrush, QColor, QConicalGradient, QCursor,
|
|||||||
QFont, QFontDatabase, QGradient, QIcon,
|
QFont, QFontDatabase, QGradient, QIcon,
|
||||||
QImage, QKeySequence, QLinearGradient, QPainter,
|
QImage, QKeySequence, QLinearGradient, QPainter,
|
||||||
QPalette, QPixmap, QRadialGradient, QTransform)
|
QPalette, QPixmap, QRadialGradient, QTransform)
|
||||||
from PySide6.QtWidgets import (QApplication, QGridLayout, QGroupBox, QHBoxLayout,
|
from PySide6.QtWidgets import (QApplication, QDoubleSpinBox, QGridLayout, QGroupBox,
|
||||||
QLabel, QMainWindow, QPlainTextEdit, QPushButton,
|
QHBoxLayout, QLabel, QMainWindow, QPlainTextEdit,
|
||||||
QSizePolicy, QSpinBox, QStatusBar, QVBoxLayout,
|
QPushButton, QSizePolicy, QSpinBox, QStatusBar,
|
||||||
QWidget)
|
QVBoxLayout, QWidget)
|
||||||
|
|
||||||
class Ui_MainWindow_artifact_label_input_setting(object):
|
class Ui_MainWindow_artifact_label_input_setting(object):
|
||||||
def setupUi(self, MainWindow_artifact_label_input_setting):
|
def setupUi(self, MainWindow_artifact_label_input_setting):
|
||||||
@ -81,6 +81,9 @@ class Ui_MainWindow_artifact_label_input_setting(object):
|
|||||||
self.spinBox_bandPassOrder = QSpinBox(self.groupBox_2)
|
self.spinBox_bandPassOrder = QSpinBox(self.groupBox_2)
|
||||||
self.spinBox_bandPassOrder.setObjectName(u"spinBox_bandPassOrder")
|
self.spinBox_bandPassOrder.setObjectName(u"spinBox_bandPassOrder")
|
||||||
self.spinBox_bandPassOrder.setFont(font)
|
self.spinBox_bandPassOrder.setFont(font)
|
||||||
|
self.spinBox_bandPassOrder.setMinimum(0)
|
||||||
|
self.spinBox_bandPassOrder.setMaximum(10)
|
||||||
|
self.spinBox_bandPassOrder.setValue(0)
|
||||||
|
|
||||||
self.horizontalLayout.addWidget(self.spinBox_bandPassOrder)
|
self.horizontalLayout.addWidget(self.spinBox_bandPassOrder)
|
||||||
|
|
||||||
@ -91,11 +94,12 @@ class Ui_MainWindow_artifact_label_input_setting(object):
|
|||||||
|
|
||||||
self.horizontalLayout.addWidget(self.label_3)
|
self.horizontalLayout.addWidget(self.label_3)
|
||||||
|
|
||||||
self.spinBox_bandPassLow = QSpinBox(self.groupBox_2)
|
self.doubleSpinBox_bandPassLow = QDoubleSpinBox(self.groupBox_2)
|
||||||
self.spinBox_bandPassLow.setObjectName(u"spinBox_bandPassLow")
|
self.doubleSpinBox_bandPassLow.setObjectName(u"doubleSpinBox_bandPassLow")
|
||||||
self.spinBox_bandPassLow.setFont(font)
|
self.doubleSpinBox_bandPassLow.setFont(font)
|
||||||
|
self.doubleSpinBox_bandPassLow.setMaximum(100.000000000000000)
|
||||||
|
|
||||||
self.horizontalLayout.addWidget(self.spinBox_bandPassLow)
|
self.horizontalLayout.addWidget(self.doubleSpinBox_bandPassLow)
|
||||||
|
|
||||||
self.label_4 = QLabel(self.groupBox_2)
|
self.label_4 = QLabel(self.groupBox_2)
|
||||||
self.label_4.setObjectName(u"label_4")
|
self.label_4.setObjectName(u"label_4")
|
||||||
@ -104,11 +108,12 @@ class Ui_MainWindow_artifact_label_input_setting(object):
|
|||||||
|
|
||||||
self.horizontalLayout.addWidget(self.label_4)
|
self.horizontalLayout.addWidget(self.label_4)
|
||||||
|
|
||||||
self.spinBox_bandPassHigh = QSpinBox(self.groupBox_2)
|
self.doubleSpinBox_bandPassHigh = QDoubleSpinBox(self.groupBox_2)
|
||||||
self.spinBox_bandPassHigh.setObjectName(u"spinBox_bandPassHigh")
|
self.doubleSpinBox_bandPassHigh.setObjectName(u"doubleSpinBox_bandPassHigh")
|
||||||
self.spinBox_bandPassHigh.setFont(font)
|
self.doubleSpinBox_bandPassHigh.setFont(font)
|
||||||
|
self.doubleSpinBox_bandPassHigh.setMaximum(100.000000000000000)
|
||||||
|
|
||||||
self.horizontalLayout.addWidget(self.spinBox_bandPassHigh)
|
self.horizontalLayout.addWidget(self.doubleSpinBox_bandPassHigh)
|
||||||
|
|
||||||
|
|
||||||
self.verticalLayout_5.addWidget(self.groupBox_2)
|
self.verticalLayout_5.addWidget(self.groupBox_2)
|
||||||
|
|||||||
@ -103,6 +103,15 @@
|
|||||||
<pointsize>12</pointsize>
|
<pointsize>12</pointsize>
|
||||||
</font>
|
</font>
|
||||||
</property>
|
</property>
|
||||||
|
<property name="minimum">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="maximum">
|
||||||
|
<number>10</number>
|
||||||
|
</property>
|
||||||
|
<property name="value">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
@ -121,12 +130,15 @@
|
|||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QSpinBox" name="spinBox_bandPassLow">
|
<widget class="QDoubleSpinBox" name="doubleSpinBox_bandPassLow">
|
||||||
<property name="font">
|
<property name="font">
|
||||||
<font>
|
<font>
|
||||||
<pointsize>12</pointsize>
|
<pointsize>12</pointsize>
|
||||||
</font>
|
</font>
|
||||||
</property>
|
</property>
|
||||||
|
<property name="maximum">
|
||||||
|
<double>100.000000000000000</double>
|
||||||
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
@ -145,12 +157,15 @@
|
|||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QSpinBox" name="spinBox_bandPassHigh">
|
<widget class="QDoubleSpinBox" name="doubleSpinBox_bandPassHigh">
|
||||||
<property name="font">
|
<property name="font">
|
||||||
<font>
|
<font>
|
||||||
<pointsize>12</pointsize>
|
<pointsize>12</pointsize>
|
||||||
</font>
|
</font>
|
||||||
</property>
|
</property>
|
||||||
|
<property name="maximum">
|
||||||
|
<double>100.000000000000000</double>
|
||||||
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
|
|||||||
197
ui/setting/precisely_align_input_setting.py
Normal file
197
ui/setting/precisely_align_input_setting.py
Normal file
@ -0,0 +1,197 @@
|
|||||||
|
# -*- coding: utf-8 -*-
|
||||||
|
|
||||||
|
################################################################################
|
||||||
|
## Form generated from reading UI file 'precisely_align_input_setting.ui'
|
||||||
|
##
|
||||||
|
## Created by: Qt User Interface Compiler version 6.8.2
|
||||||
|
##
|
||||||
|
## WARNING! All changes made in this file will be lost when recompiling UI file!
|
||||||
|
################################################################################
|
||||||
|
|
||||||
|
from PySide6.QtCore import (QCoreApplication, QDate, QDateTime, QLocale,
|
||||||
|
QMetaObject, QObject, QPoint, QRect,
|
||||||
|
QSize, QTime, QUrl, Qt)
|
||||||
|
from PySide6.QtGui import (QBrush, QColor, QConicalGradient, QCursor,
|
||||||
|
QFont, QFontDatabase, QGradient, QIcon,
|
||||||
|
QImage, QKeySequence, QLinearGradient, QPainter,
|
||||||
|
QPalette, QPixmap, QRadialGradient, QTransform)
|
||||||
|
from PySide6.QtWidgets import (QApplication, QGridLayout, QGroupBox, QHBoxLayout,
|
||||||
|
QLabel, QMainWindow, QPlainTextEdit, QPushButton,
|
||||||
|
QSizePolicy, QSpinBox, QStatusBar, QVBoxLayout,
|
||||||
|
QWidget)
|
||||||
|
|
||||||
|
class Ui_MainWindow_precisely_align_input_setting(object):
|
||||||
|
def setupUi(self, MainWindow_precisely_align_input_setting):
|
||||||
|
if not MainWindow_precisely_align_input_setting.objectName():
|
||||||
|
MainWindow_precisely_align_input_setting.setObjectName(u"MainWindow_precisely_align_input_setting")
|
||||||
|
MainWindow_precisely_align_input_setting.resize(540, 760)
|
||||||
|
self.centralwidget = QWidget(MainWindow_precisely_align_input_setting)
|
||||||
|
self.centralwidget.setObjectName(u"centralwidget")
|
||||||
|
self.gridLayout = QGridLayout(self.centralwidget)
|
||||||
|
self.gridLayout.setObjectName(u"gridLayout")
|
||||||
|
self.pushButton_cancel = QPushButton(self.centralwidget)
|
||||||
|
self.pushButton_cancel.setObjectName(u"pushButton_cancel")
|
||||||
|
font = QFont()
|
||||||
|
font.setPointSize(12)
|
||||||
|
self.pushButton_cancel.setFont(font)
|
||||||
|
|
||||||
|
self.gridLayout.addWidget(self.pushButton_cancel, 1, 3, 1, 1)
|
||||||
|
|
||||||
|
self.groupBox = QGroupBox(self.centralwidget)
|
||||||
|
self.groupBox.setObjectName(u"groupBox")
|
||||||
|
font1 = QFont()
|
||||||
|
font1.setPointSize(10)
|
||||||
|
self.groupBox.setFont(font1)
|
||||||
|
self.verticalLayout_2 = QVBoxLayout(self.groupBox)
|
||||||
|
self.verticalLayout_2.setObjectName(u"verticalLayout_2")
|
||||||
|
self.groupBox_file_path_input_BCG = QGroupBox(self.groupBox)
|
||||||
|
self.groupBox_file_path_input_BCG.setObjectName(u"groupBox_file_path_input_BCG")
|
||||||
|
self.verticalLayout_5 = QVBoxLayout(self.groupBox_file_path_input_BCG)
|
||||||
|
self.verticalLayout_5.setObjectName(u"verticalLayout_5")
|
||||||
|
self.horizontalLayout_2 = QHBoxLayout()
|
||||||
|
self.horizontalLayout_2.setObjectName(u"horizontalLayout_2")
|
||||||
|
self.label_2 = QLabel(self.groupBox_file_path_input_BCG)
|
||||||
|
self.label_2.setObjectName(u"label_2")
|
||||||
|
self.label_2.setFont(font)
|
||||||
|
|
||||||
|
self.horizontalLayout_2.addWidget(self.label_2)
|
||||||
|
|
||||||
|
self.spinBox_input_freq_BCG = QSpinBox(self.groupBox_file_path_input_BCG)
|
||||||
|
self.spinBox_input_freq_BCG.setObjectName(u"spinBox_input_freq_BCG")
|
||||||
|
self.spinBox_input_freq_BCG.setFont(font)
|
||||||
|
self.spinBox_input_freq_BCG.setMinimum(1)
|
||||||
|
self.spinBox_input_freq_BCG.setMaximum(1000000)
|
||||||
|
|
||||||
|
self.horizontalLayout_2.addWidget(self.spinBox_input_freq_BCG)
|
||||||
|
|
||||||
|
|
||||||
|
self.verticalLayout_5.addLayout(self.horizontalLayout_2)
|
||||||
|
|
||||||
|
self.plainTextEdit_file_path_input_BCG = QPlainTextEdit(self.groupBox_file_path_input_BCG)
|
||||||
|
self.plainTextEdit_file_path_input_BCG.setObjectName(u"plainTextEdit_file_path_input_BCG")
|
||||||
|
|
||||||
|
self.verticalLayout_5.addWidget(self.plainTextEdit_file_path_input_BCG)
|
||||||
|
|
||||||
|
self.verticalLayout_5.setStretch(0, 2)
|
||||||
|
self.verticalLayout_5.setStretch(1, 3)
|
||||||
|
|
||||||
|
self.verticalLayout_2.addWidget(self.groupBox_file_path_input_BCG)
|
||||||
|
|
||||||
|
self.groupBox_file_path_input_Jpeak = QGroupBox(self.groupBox)
|
||||||
|
self.groupBox_file_path_input_Jpeak.setObjectName(u"groupBox_file_path_input_Jpeak")
|
||||||
|
self.verticalLayout_3 = QVBoxLayout(self.groupBox_file_path_input_Jpeak)
|
||||||
|
self.verticalLayout_3.setObjectName(u"verticalLayout_3")
|
||||||
|
self.plainTextEdit_file_path_input_Jpeak = QPlainTextEdit(self.groupBox_file_path_input_Jpeak)
|
||||||
|
self.plainTextEdit_file_path_input_Jpeak.setObjectName(u"plainTextEdit_file_path_input_Jpeak")
|
||||||
|
|
||||||
|
self.verticalLayout_3.addWidget(self.plainTextEdit_file_path_input_Jpeak)
|
||||||
|
|
||||||
|
self.verticalLayout_3.setStretch(0, 2)
|
||||||
|
|
||||||
|
self.verticalLayout_2.addWidget(self.groupBox_file_path_input_Jpeak)
|
||||||
|
|
||||||
|
self.groupBox_file_path_input_ECG = QGroupBox(self.groupBox)
|
||||||
|
self.groupBox_file_path_input_ECG.setObjectName(u"groupBox_file_path_input_ECG")
|
||||||
|
self.verticalLayout_6 = QVBoxLayout(self.groupBox_file_path_input_ECG)
|
||||||
|
self.verticalLayout_6.setObjectName(u"verticalLayout_6")
|
||||||
|
self.horizontalLayout_3 = QHBoxLayout()
|
||||||
|
self.horizontalLayout_3.setObjectName(u"horizontalLayout_3")
|
||||||
|
self.label_3 = QLabel(self.groupBox_file_path_input_ECG)
|
||||||
|
self.label_3.setObjectName(u"label_3")
|
||||||
|
self.label_3.setFont(font)
|
||||||
|
|
||||||
|
self.horizontalLayout_3.addWidget(self.label_3)
|
||||||
|
|
||||||
|
self.spinBox_input_freq_ECG = QSpinBox(self.groupBox_file_path_input_ECG)
|
||||||
|
self.spinBox_input_freq_ECG.setObjectName(u"spinBox_input_freq_ECG")
|
||||||
|
self.spinBox_input_freq_ECG.setFont(font)
|
||||||
|
self.spinBox_input_freq_ECG.setMinimum(1)
|
||||||
|
self.spinBox_input_freq_ECG.setMaximum(1000000)
|
||||||
|
|
||||||
|
self.horizontalLayout_3.addWidget(self.spinBox_input_freq_ECG)
|
||||||
|
|
||||||
|
|
||||||
|
self.verticalLayout_6.addLayout(self.horizontalLayout_3)
|
||||||
|
|
||||||
|
self.plainTextEdit_file_path_input_ECG = QPlainTextEdit(self.groupBox_file_path_input_ECG)
|
||||||
|
self.plainTextEdit_file_path_input_ECG.setObjectName(u"plainTextEdit_file_path_input_ECG")
|
||||||
|
|
||||||
|
self.verticalLayout_6.addWidget(self.plainTextEdit_file_path_input_ECG)
|
||||||
|
|
||||||
|
self.verticalLayout_6.setStretch(0, 2)
|
||||||
|
self.verticalLayout_6.setStretch(1, 3)
|
||||||
|
|
||||||
|
self.verticalLayout_2.addWidget(self.groupBox_file_path_input_ECG)
|
||||||
|
|
||||||
|
self.groupBox_file_path_input_Rpeak = QGroupBox(self.groupBox)
|
||||||
|
self.groupBox_file_path_input_Rpeak.setObjectName(u"groupBox_file_path_input_Rpeak")
|
||||||
|
self.verticalLayout_7 = QVBoxLayout(self.groupBox_file_path_input_Rpeak)
|
||||||
|
self.verticalLayout_7.setObjectName(u"verticalLayout_7")
|
||||||
|
self.plainTextEdit_file_path_input_Rpeak = QPlainTextEdit(self.groupBox_file_path_input_Rpeak)
|
||||||
|
self.plainTextEdit_file_path_input_Rpeak.setObjectName(u"plainTextEdit_file_path_input_Rpeak")
|
||||||
|
|
||||||
|
self.verticalLayout_7.addWidget(self.plainTextEdit_file_path_input_Rpeak)
|
||||||
|
|
||||||
|
self.verticalLayout_7.setStretch(0, 2)
|
||||||
|
|
||||||
|
self.verticalLayout_2.addWidget(self.groupBox_file_path_input_Rpeak)
|
||||||
|
|
||||||
|
self.groupBox_file_path_save = QGroupBox(self.groupBox)
|
||||||
|
self.groupBox_file_path_save.setObjectName(u"groupBox_file_path_save")
|
||||||
|
self.verticalLayout_4 = QVBoxLayout(self.groupBox_file_path_save)
|
||||||
|
self.verticalLayout_4.setObjectName(u"verticalLayout_4")
|
||||||
|
self.plainTextEdit_file_path_save = QPlainTextEdit(self.groupBox_file_path_save)
|
||||||
|
self.plainTextEdit_file_path_save.setObjectName(u"plainTextEdit_file_path_save")
|
||||||
|
|
||||||
|
self.verticalLayout_4.addWidget(self.plainTextEdit_file_path_save)
|
||||||
|
|
||||||
|
|
||||||
|
self.verticalLayout_2.addWidget(self.groupBox_file_path_save)
|
||||||
|
|
||||||
|
self.verticalLayout_2.setStretch(0, 5)
|
||||||
|
self.verticalLayout_2.setStretch(1, 4)
|
||||||
|
self.verticalLayout_2.setStretch(2, 5)
|
||||||
|
self.verticalLayout_2.setStretch(3, 4)
|
||||||
|
self.verticalLayout_2.setStretch(4, 4)
|
||||||
|
|
||||||
|
self.gridLayout.addWidget(self.groupBox, 0, 0, 1, 4)
|
||||||
|
|
||||||
|
self.pushButton_confirm = QPushButton(self.centralwidget)
|
||||||
|
self.pushButton_confirm.setObjectName(u"pushButton_confirm")
|
||||||
|
self.pushButton_confirm.setFont(font)
|
||||||
|
|
||||||
|
self.gridLayout.addWidget(self.pushButton_confirm, 1, 2, 1, 1)
|
||||||
|
|
||||||
|
MainWindow_precisely_align_input_setting.setCentralWidget(self.centralwidget)
|
||||||
|
self.statusbar = QStatusBar(MainWindow_precisely_align_input_setting)
|
||||||
|
self.statusbar.setObjectName(u"statusbar")
|
||||||
|
MainWindow_precisely_align_input_setting.setStatusBar(self.statusbar)
|
||||||
|
|
||||||
|
self.retranslateUi(MainWindow_precisely_align_input_setting)
|
||||||
|
|
||||||
|
QMetaObject.connectSlotsByName(MainWindow_precisely_align_input_setting)
|
||||||
|
# setupUi
|
||||||
|
|
||||||
|
def retranslateUi(self, MainWindow_precisely_align_input_setting):
|
||||||
|
MainWindow_precisely_align_input_setting.setWindowTitle(QCoreApplication.translate("MainWindow_precisely_align_input_setting", u"\u5bfc\u5165\u8bbe\u7f6e", None))
|
||||||
|
self.pushButton_cancel.setText(QCoreApplication.translate("MainWindow_precisely_align_input_setting", u"\u53d6\u6d88", None))
|
||||||
|
self.groupBox.setTitle(QCoreApplication.translate("MainWindow_precisely_align_input_setting", u"\u6587\u4ef6\u8def\u5f84", None))
|
||||||
|
self.groupBox_file_path_input_BCG.setTitle(QCoreApplication.translate("MainWindow_precisely_align_input_setting", u"\u9884\u5904\u7406\u540e\u7684BCG\u8def\u5f84", None))
|
||||||
|
self.label_2.setText(QCoreApplication.translate("MainWindow_precisely_align_input_setting", u"\u91c7\u6837\u7387(Hz)\uff1a", None))
|
||||||
|
self.plainTextEdit_file_path_input_BCG.setPlainText("")
|
||||||
|
self.plainTextEdit_file_path_input_BCG.setPlaceholderText(QCoreApplication.translate("MainWindow_precisely_align_input_setting", u"\u6587\u4ef6\u8def\u5f84", None))
|
||||||
|
self.groupBox_file_path_input_Jpeak.setTitle(QCoreApplication.translate("MainWindow_precisely_align_input_setting", u"\u4eba\u5de5\u7ea0\u6b63\u540e\u7684J\u5cf0\u5cf0\u503c\u8def\u5f84", None))
|
||||||
|
self.plainTextEdit_file_path_input_Jpeak.setPlainText("")
|
||||||
|
self.plainTextEdit_file_path_input_Jpeak.setPlaceholderText(QCoreApplication.translate("MainWindow_precisely_align_input_setting", u"\u6587\u4ef6\u8def\u5f84", None))
|
||||||
|
self.groupBox_file_path_input_ECG.setTitle(QCoreApplication.translate("MainWindow_precisely_align_input_setting", u"\u9884\u5904\u7406\u540e\u7684ECG\u8def\u5f84", None))
|
||||||
|
self.label_3.setText(QCoreApplication.translate("MainWindow_precisely_align_input_setting", u"\u91c7\u6837\u7387(Hz)\uff1a", None))
|
||||||
|
self.plainTextEdit_file_path_input_ECG.setPlainText("")
|
||||||
|
self.plainTextEdit_file_path_input_ECG.setPlaceholderText(QCoreApplication.translate("MainWindow_precisely_align_input_setting", u"\u6587\u4ef6\u8def\u5f84", None))
|
||||||
|
self.groupBox_file_path_input_Rpeak.setTitle(QCoreApplication.translate("MainWindow_precisely_align_input_setting", u"\u4eba\u5de5\u7ea0\u6b63\u540e\u7684R\u5cf0\u5cf0\u503c\u8def\u5f84", None))
|
||||||
|
self.plainTextEdit_file_path_input_Rpeak.setPlainText("")
|
||||||
|
self.plainTextEdit_file_path_input_Rpeak.setPlaceholderText(QCoreApplication.translate("MainWindow_precisely_align_input_setting", u"\u6587\u4ef6\u8def\u5f84", None))
|
||||||
|
self.groupBox_file_path_save.setTitle(QCoreApplication.translate("MainWindow_precisely_align_input_setting", u"\u5bf9\u9f50\u4fe1\u606f\u4fdd\u5b58\u8def\u5f84", None))
|
||||||
|
self.plainTextEdit_file_path_save.setPlaceholderText(QCoreApplication.translate("MainWindow_precisely_align_input_setting", u"\u4fdd\u5b58\u8def\u5f84", None))
|
||||||
|
self.pushButton_confirm.setText(QCoreApplication.translate("MainWindow_precisely_align_input_setting", u"\u786e\u5b9a", None))
|
||||||
|
# retranslateUi
|
||||||
|
|
||||||
216
ui/setting/precisely_align_input_setting.ui
Normal file
216
ui/setting/precisely_align_input_setting.ui
Normal file
@ -0,0 +1,216 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<ui version="4.0">
|
||||||
|
<class>MainWindow_precisely_align_input_setting</class>
|
||||||
|
<widget class="QMainWindow" name="MainWindow_precisely_align_input_setting">
|
||||||
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>0</x>
|
||||||
|
<y>0</y>
|
||||||
|
<width>540</width>
|
||||||
|
<height>760</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
|
<property name="windowTitle">
|
||||||
|
<string>导入设置</string>
|
||||||
|
</property>
|
||||||
|
<widget class="QWidget" name="centralwidget">
|
||||||
|
<layout class="QGridLayout" name="gridLayout">
|
||||||
|
<item row="1" column="3">
|
||||||
|
<widget class="QPushButton" name="pushButton_cancel">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>取消</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="0" colspan="4">
|
||||||
|
<widget class="QGroupBox" name="groupBox">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>10</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="title">
|
||||||
|
<string>文件路径</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_2" stretch="5,4,5,4,4">
|
||||||
|
<item>
|
||||||
|
<widget class="QGroupBox" name="groupBox_file_path_input_BCG">
|
||||||
|
<property name="title">
|
||||||
|
<string>预处理后的BCG路径</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_5" stretch="2,3">
|
||||||
|
<item>
|
||||||
|
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="label_2">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>采样率(Hz):</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QSpinBox" name="spinBox_input_freq_BCG">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="minimum">
|
||||||
|
<number>1</number>
|
||||||
|
</property>
|
||||||
|
<property name="maximum">
|
||||||
|
<number>1000000</number>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QPlainTextEdit" name="plainTextEdit_file_path_input_BCG">
|
||||||
|
<property name="plainText">
|
||||||
|
<string/>
|
||||||
|
</property>
|
||||||
|
<property name="placeholderText">
|
||||||
|
<string>文件路径</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QGroupBox" name="groupBox_file_path_input_Jpeak">
|
||||||
|
<property name="title">
|
||||||
|
<string>人工纠正后的J峰峰值路径</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_3" stretch="2">
|
||||||
|
<item>
|
||||||
|
<widget class="QPlainTextEdit" name="plainTextEdit_file_path_input_Jpeak">
|
||||||
|
<property name="plainText">
|
||||||
|
<string/>
|
||||||
|
</property>
|
||||||
|
<property name="placeholderText">
|
||||||
|
<string>文件路径</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QGroupBox" name="groupBox_file_path_input_ECG">
|
||||||
|
<property name="title">
|
||||||
|
<string>预处理后的ECG路径</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_6" stretch="2,3">
|
||||||
|
<item>
|
||||||
|
<layout class="QHBoxLayout" name="horizontalLayout_3">
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="label_3">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>采样率(Hz):</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QSpinBox" name="spinBox_input_freq_ECG">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="minimum">
|
||||||
|
<number>1</number>
|
||||||
|
</property>
|
||||||
|
<property name="maximum">
|
||||||
|
<number>1000000</number>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QPlainTextEdit" name="plainTextEdit_file_path_input_ECG">
|
||||||
|
<property name="plainText">
|
||||||
|
<string/>
|
||||||
|
</property>
|
||||||
|
<property name="placeholderText">
|
||||||
|
<string>文件路径</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QGroupBox" name="groupBox_file_path_input_Rpeak">
|
||||||
|
<property name="title">
|
||||||
|
<string>人工纠正后的R峰峰值路径</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_7" stretch="2">
|
||||||
|
<item>
|
||||||
|
<widget class="QPlainTextEdit" name="plainTextEdit_file_path_input_Rpeak">
|
||||||
|
<property name="plainText">
|
||||||
|
<string/>
|
||||||
|
</property>
|
||||||
|
<property name="placeholderText">
|
||||||
|
<string>文件路径</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QGroupBox" name="groupBox_file_path_save">
|
||||||
|
<property name="title">
|
||||||
|
<string>对齐信息保存路径</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QVBoxLayout" name="verticalLayout_4">
|
||||||
|
<item>
|
||||||
|
<widget class="QPlainTextEdit" name="plainTextEdit_file_path_save">
|
||||||
|
<property name="placeholderText">
|
||||||
|
<string>保存路径</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="2">
|
||||||
|
<widget class="QPushButton" name="pushButton_confirm">
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<pointsize>12</pointsize>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>确定</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
<widget class="QStatusBar" name="statusbar"/>
|
||||||
|
</widget>
|
||||||
|
<resources/>
|
||||||
|
<connections/>
|
||||||
|
</ui>
|
||||||
Reference in New Issue
Block a user