A method for ECG signal quality assessment based on unsupervised cascaded adaptive networks

CN121370181BActive Publication Date: 2026-09-01ASIAN ANTI-AGING & TRANSLATIONAL MEDICINE RESEARCH CENTER (SHENZHEN) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202511535452.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-10-24
Publication Date
2026-09-01
Estimated Expiration
2045-10-24

AI Technical Summary

Technical Problem

[0005]针对现有技术的不足,本发明提供了一种基于无监督级联自适应网络的心电信号质量评估方法,解决了心电疾病波形误判为噪声的问题

Benefits of technology

1、本发明通过自编码器自动学习正常心电信号分布规律,降低对专业医生标注资源的依赖;同时借助两级自适应评估网络,先过滤显著噪声,再精准区分病理信号与噪声,有效避免将心肌梗死、房颤等疾病引发的异常波形误判为噪声,显著提升病理信号保留率,为临床诊断提供更完整的有效数据支撑。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121370181B_ABST
    Figure CN121370181B_ABST
Patent Text Reader

Abstract

This application relates to the field of electrocardiogram (ECG) signal quality assessment technology, and discloses an ECG signal quality assessment method based on an unsupervised cascaded adaptive network, including the following steps: S1, preprocessing the acquired raw ECG signal: removing power frequency interference through adaptive notch filtering, removing high-frequency electromyographic noise through soft threshold wavelet filtering, and retaining potential pathological feature waveforms during the filtering process to obtain the preprocessed ECG signal; S2, unsupervised multimodal feature extraction: an unsupervised feature extraction network based on an autoencoder. The autoencoder automatically learns the distribution patterns of normal ECG signals, reducing reliance on professional physician annotation resources; simultaneously, with the help of a two-level adaptive assessment network, significant noise is first filtered out, and then pathological signals are accurately distinguished from noise, effectively avoiding misjudging abnormal waveforms caused by diseases such as myocardial infarction and atrial fibrillation as noise, significantly improving the pathological signal retention rate, and providing more complete and effective data support for clinical diagnosis.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of electrocardiogram (ECG) signal quality assessment technology, specifically to an ECG signal quality assessment method based on unsupervised cascaded adaptive networks. Background Technology

[0002] ECG signal quality assessment is a crucial step in the diagnosis and remote monitoring of cardiovascular diseases. Its core is to use technical means to screen out effective signals that are free from interference and can accurately reflect the state of cardiac function, providing a reliable data foundation for subsequent diagnosis and treatment work such as ECG analysis and arrhythmia detection. It is widely used in hospital clinical diagnosis, home health monitoring and wearable medical devices and other scenarios.

[0003] Currently, the industry's ECG signal quality assessment mostly adopts a technical approach that combines supervised learning with single feature extraction. This involves training a model by manually labeling a large number of "normal / noisy" ECG samples, extracting the time-frequency domain features of the signal using methods such as wavelet transform and Fourier transform, and then completing the quality classification using models such as support vector machine and single convolutional neural network. Although some methods introduce unsupervised learning, they mostly adopt a single-stage evaluation mode, directly making a binary judgment of "qualified / unqualified" for the signal.

[0004] However, traditional methods are prone to misidentifying abnormal signal waveforms caused by heart disease as noise interference, leading to the loss of important clinical information. For example, some rule-based methods detect noise by setting a fixed threshold. When patients with heart disease have abnormal electrocardiogram waveforms, these abnormalities may be incorrectly identified as low-quality signals and rejected. Summary of the Invention

[0005] To address the shortcomings of existing technologies, this invention provides a method for evaluating the quality of electrocardiogram (ECG) signals based on unsupervised cascaded adaptive networks, which solves the problem of misjudging ECG waveforms as noise.

[0006] To achieve the above objectives, the present invention provides the following technical solution: a method for assessing the quality of electrocardiogram (ECG) signals based on unsupervised cascaded adaptive networks, comprising the following steps: S1. Preprocess the acquired raw ECG signal: remove power frequency interference by adaptive notch filtering, remove high-frequency electromyographic noise by soft threshold wavelet filtering, and retain potential pathological waveforms during the filtering process to obtain the preprocessed ECG signal. S2, Unsupervised Multimodal Feature Extraction: An unsupervised feature extraction network based on an autoencoder extracts time-domain features, frequency-domain features, and nonlinear features from the ECG signal preprocessed in S1, and then fuses the three types of features to generate a comprehensive feature vector. S3. Cascaded Adaptive Evaluation: Construct a two-level adaptive evaluation network to process the comprehensive feature vector, specifically including: First-level noise filtering: The improved K-means algorithm is used to cluster and filter significant noise features in the comprehensive feature vector to remove obvious noise signals and output candidate signals. Second-level pathology-noise differentiation: An adaptive attention mechanism is introduced, and the candidate signals output from the first level are initially classified by the pathological feature confidence calculation algorithm, and the initial quality assessment results are output. The initial quality assessment results include three categories: suspected pathological signals, noise, and ambiguous interval signals. At the same time, the ambiguous interval signals are further subdivided by a secondary classification algorithm, and the subdivided results are output. The subdivided results include two categories: weak pathological signals and pseudo-pathological noise. S4. Output Quality Level: Combining the preliminary quality assessment results and subdivision results, as well as the preset clinical pathology feature library, output complete ECG signal quality assessment results. The complete ECG signal quality assessment results include four categories: suspected pathological signals, weak pathological signals, pseudo-pathological noise, and noise.

[0007] Preferably, the threshold calculation method for the soft threshold wavelet filter in the S1 ECG signal preprocessing module is as follows: based on the high-frequency coefficients after wavelet decomposition, the noise standard deviation is estimated, and combined with the number of sampling points of the original ECG signal, the threshold is determined through logarithmic relationship to ensure that high-frequency electromyographic noise with a frequency greater than 100Hz is removed without losing low-frequency pathological features.

[0008] Preferably, the extraction method of time-domain features in the unsupervised multimodal feature extraction module in S2 is as follows: the waveform segments of the preprocessed ECG signal are truncated using the sliding window method, and the QRS amplitude, RR interval standard deviation, and ST segment offset of each segment are calculated, for a total of 3 time-domain parameters; the extraction method of frequency-domain features is as follows: the ECG signal preprocessed in S1 is subjected to fast Fourier transform, and the power spectral entropy and the energy ratio of the low-frequency and high-frequency bands of heart rate variability are calculated, for a total of 2 frequency-domain parameters; the extraction method of nonlinear features is as follows: the fractal dimension is calculated using the box counting method, and the sample entropy is calculated using the sample entropy algorithm, for a total of 2 nonlinear parameters; a total of 7 parameters are fused with equal weights to generate a comprehensive feature vector.

[0009] Preferably, the network structure parameters of the autoencoder in the unsupervised multimodal feature extraction module in S2 are as follows: the coding layer dimension is set to 128, the decoding layer dimension is consistent with the dimension of the preprocessed ECG signal, the mean square error is used as the loss function, and the distribution pattern of normal ECG signals is learned by minimizing the loss function, so as to provide a benchmark for the subsequent pathological feature confidence calculation algorithm.

[0010] Preferably, the pathological feature confidence calculation algorithm of the second-level pathological-noise region molecular network in the cascaded adaptive evaluation module is used to achieve preliminary classification of candidate signals. The specific calculation formula includes:

[0011] In the formula: : Confidence level of pathological features, with a value range of [0,1], used as a preliminary classification basis; when A value ≥0.6 is initially considered a suspected pathological signal. If the value is less than 0.3, it is initially classified as noise; if 0.3 ≤ Signals with a value less than 0.6 are marked as fuzzy interval signals; The weight of the i-th pathological association feature includes three core pathological association features: ST segment offset, fractal dimension, and sample entropy, with corresponding weights of 0.4, 0.3, and 0.3, respectively. The weights are obtained by training with 500 myocardial infarction samples and 300 atrial fibrillation samples from a pre-set clinical pathological feature library. : No. The normalized value of each pathological correlation feature ranges from [0,1]. When the ST segment offset is greater than 0.1mV, the normalized value is 1. When the fractal dimension is less than 1.0, the normalized value is 1. When the sample entropy is less than 0.5, the normalized value is 1. : Reconstruction error correction coefficient, with a value of 0.2, is used to balance the influence of signal reconstruction results from unsupervised learning and the weights of pathological features; The reconstruction error of the autoencoder ranges from [0, 0.1]. The reconstruction error of the pathological waveform is higher than that of the normal signal but lower than that of the random noise due to deviation from the normal signal distribution. The reconstruction error of the normal signal is <0.02, the reconstruction error of the pathological signal is 0.02~0.05, and the reconstruction error of the noise is >0.05.

[0012] Preferred confidence level of pathological features The initial classification threshold was determined by optimizing the receiver operating characteristic curve: using the pathological waveforms and noise marked in the preset clinical pathological feature library as the gold standard, the threshold was adjusted to make the overall accuracy of the initial classification ≥90%, while reserving a subdivision ratio of 10%~15% of the total signal for fuzzy interval signals.

[0013] Preferably, the pre-defined clinical pathological feature database is constructed as follows: 1000 clinically diagnosed pathological electrocardiogram (ECG) samples and 500 normal ECG samples are collected, including 500 samples of myocardial infarction, 300 samples of atrial fibrillation, and 200 samples of premature ventricular contractions (PVCs); waveform feature parameters are labeled for each sample, including QRS width, ST segment elevation amplitude, and RR interval regularity; three types of typical pathological waveform templates are generated using K-means clustering, with the parameters for each type of template as follows: The first type of template corresponds to myocardial infarction, and its parameters are ST segment elevation amplitude ≥0.1mV in the precordial leads or ≥0.2mV in the limb leads, and the QRS wave is QS type; The second type of template corresponds to atrial fibrillation, with parameters including an absolutely irregular RR interval, an f-wave frequency of 350~600 beats / min, and an f-wave amplitude of <0.1mV; The third type of template corresponds to premature ventricular contractions (PVCs), with parameters including QRS width > 120 ms and complete compensatory pause. The pre-set clinical pathology feature library has been clinically validated by tertiary hospitals, ensuring that the matching accuracy between the template and the real pathological waveform is ≥95%.

[0014] Preferably, the secondary classification algorithm of the second-level pathological-noise region molecular network in the cascaded adaptive evaluation module is used to subdivide the signal in the fuzzy region. The output subdivision results include two categories: weak pathological signals and pseudo-pathological noise. The specific calculation formula includes:

[0015] In the formula: : Secondary classification confidence score, with a value range of [0,1], is used as the basis for subdivision; when A value ≥0.5 is considered a weak pathological signal. A value <0.5 is considered pseudo-pathological noise; The dispersion of pathological association features, with a value range of [0,1], is calculated as the ratio of the standard deviation of the three core pathological association features (ST segment offset, fractal dimension, and sample entropy) to the maximum value of each feature. : The matching residual between the signal and the preset clinical pathology feature library template, with a value range of [0,1]. It is calculated by the Euclidean distance between the comprehensive feature vector of the fuzzy interval signal and the feature vector of the most similar template in the preset clinical pathology feature library, and then normalized to the [0,1] interval. : The secondary classification balance coefficient, with a value of 0.4, is used to balance the weights of feature dispersion, matching residuals, and pathological feature confidence C; Pathological feature confidence score, which is the preliminary classification result output by the pathological feature confidence score calculation algorithm, with a value range of 0.3 ≤ <0.6.

[0016] Preferably, the selection rule for the most similar template in the secondary classification algorithm is as follows: for the comprehensive feature vector F_candidate of the fuzzy interval signal, calculate its Euclidean distance with the feature vectors of the three types of templates in the preset clinical pathology feature library, and select the template with the smallest distance as F_template; if the smallest Euclidean distance is greater than a preset threshold, which is 1.2 times the average Euclidean distance of all template feature vectors in the preset clinical pathology feature library, then e_match is forcibly set to 0.8.

[0017] Preferably, the result fusion rule of the quality level output module is as follows: retain the suspected pathological signals and noise determined by the pathological feature confidence calculation algorithm, and add the weak pathological signals and pseudo-pathological noise output by the secondary classification algorithm to form four complete classifications; among them, the weak pathological signals need to be associated with the corresponding template type in the preset clinical pathological feature library to provide a reference for clinical diagnosis.

[0018] This invention provides a method for evaluating the quality of electrocardiogram (ECG) signals based on unsupervised cascaded adaptive networks. It has the following beneficial effects: 1. This invention automatically learns the distribution pattern of normal electrocardiogram signals through an autoencoder, reducing the reliance on annotation resources from professional doctors; at the same time, it uses a two-level adaptive evaluation network to first filter out significant noise and then accurately distinguish pathological signals from noise, effectively avoiding misjudging abnormal waveforms caused by diseases such as myocardial infarction and atrial fibrillation as noise, significantly improving the retention rate of pathological signals, and providing more complete and effective data support for clinical diagnosis.

[0019] 2. This invention, through multimodal feature fusion and dual-algorithm collaboration, not only comprehensively captures the time-domain, frequency-domain, and nonlinear features of ECG signals, but also supplements the judgment of feature dispersion and template matching dimension for signals in fuzzy intervals, thereby improving the evaluation accuracy; and the preset clinical pathological feature library has been clinically verified, adapting to the recognition of signals of common cardiovascular diseases, and taking into account the real-time performance of wearable devices and other scenarios as well as the practicality of clinical diagnosis. Attached Figure Description

[0020] Figure 1 This is a flowchart of the present invention. Detailed Implementation

[0021] The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0022] Example: Please see the appendix Figure 1This invention provides a method for evaluating the quality of electrocardiogram (ECG) signals based on unsupervised cascaded adaptive networks, comprising the following steps: S1. Preprocess the acquired raw ECG signal: remove power frequency interference by adaptive notch filtering, remove high-frequency electromyographic noise by soft threshold wavelet filtering, and retain potential pathological waveforms during the filtering process to obtain the preprocessed ECG signal. A 30-minute lead II signal (EDF format) was acquired using a dynamic electrocardiogram recorder with a sampling frequency of 250Hz and a precision of 16 bits. An IIR filter was used for adaptive notch filtering, which was matched to the 50 / 60Hz power frequency in real time with a bandwidth of 2Hz, reducing the interference amplitude to less than 5% of the original signal. A soft threshold wavelet filter was used with a db4 wavelet basis for 5-level decomposition, processing only the high-frequency coefficients (>100Hz) of the first 1-3 levels, while the low-frequency coefficients (including QRS waves and ST segments) of the 4-5 levels were preserved. Pathological features were confirmed by comparing the QRS wave morphology (peak-valley position deviation ≤5ms), and the preprocessed signal was output.

[0023] S2, Unsupervised Multimodal Feature Extraction: An unsupervised feature extraction network based on an autoencoder extracts time-domain features, frequency-domain features, and nonlinear features from the ECG signal preprocessed in S1, and then fuses the three types of features to generate a comprehensive feature vector. The input layer dimension of the autoencoder is adapted to the length of the preprocessed ECG signal. The encoding layer dimension can be set to 128 and uses the ReLU activation function; the decoding layer uses the Sigmoid activation function, and its dimension is consistent with the input layer. Mean squared error is used as the loss function, and the network is trained using a certain number of healthy ECG samples (e.g., 100 cases). The network is trained through multiple iterations (e.g., 500 times), with a learning rate of 0.001, until the loss function converges to a low value (e.g., less than 0.01), thereby learning the distribution pattern of normal ECG signals. A sliding window method is used to extract features by truncating signal segments. The sliding window length can be, for example, 2 seconds, and the step size can be, for example, 1 second. Seven feature parameters (describing the feature types) are calculated within each window. After normalizing all parameters, they are fused with equal weights to generate the corresponding comprehensive feature vector.

[0024] S3. Cascaded Adaptive Evaluation: Construct a two-level adaptive evaluation network to process the comprehensive feature vector, specifically including: First-level noise filtering: The improved K-means algorithm is used to cluster and filter significant noise features in the comprehensive feature vector to remove obvious noise signals and output candidate signals. Second-level pathology-noise differentiation: An adaptive attention mechanism is introduced, and the candidate signals output from the first level are initially classified by the pathological feature confidence calculation algorithm, and the initial quality assessment results are output. The initial quality assessment results include three categories: suspected pathological signals, noise, and ambiguous interval signals. At the same time, the ambiguous interval signals are further subdivided by a secondary classification algorithm, and the subdivided results are output. The subdivided results include two categories: weak pathological signals and pseudo-pathological noise. Improve K-means by setting two cluster centers (significant noise / effective signal) using K-means++, iterating 50 times; calculate the Euclidean distance between the vector and the center, and discard segments that are more than 50% biased towards the noise center; the length of the candidate signal must be greater than or equal to 60% of the original signal, otherwise it is judged as low quality overall.

[0025] S4. Output Quality Level: Combining the preliminary quality assessment results and subdivision results, as well as the preset clinical pathology feature library, outputs a complete ECG signal quality assessment result. The complete ECG signal quality assessment result includes four categories: suspected pathological signal, weak pathological signal, pseudo-pathological noise, and noise.

[0026] The system calls upon a feature library containing templates for three types of diseases: myocardial infarction, atrial fibrillation, and premature ventricular contractions. It calculates the Euclidean distance between the signal and the template and selects the optimal match. The output table includes: overall level (four categories, such as "containing pathological information" if the suspected pathology percentage is ≥30%), time distribution of each signal (accurate to the second), matching template and matching degree. The results are synchronized to the clinical diagnostic system.

[0027] In this invention, the threshold calculation method for soft threshold wavelet filtering in the S1 ECG signal preprocessing module is as follows: based on the high-frequency coefficients after wavelet decomposition, the noise standard deviation is estimated, and combined with the number of sampling points of the original ECG signal, the threshold is determined through logarithmic relationship to ensure that while removing high-frequency electromyographic noise with a frequency greater than 100Hz, low-frequency pathological features are not lost.

[0028] The specific steps are as follows: 1. Use the db4 wavelet basis to perform a 5-level decomposition on the original signal. After decomposition, 5 sets of high-frequency coefficients and 1 set of low-frequency coefficients are obtained. Extract the first level of high-frequency coefficients (this level of coefficients mainly contains the high-frequency noise components in the signal). 2. By statistically analyzing the distribution of the high-frequency coefficients in the first layer, the degree of noise fluctuation (i.e., the noise standard deviation) can be estimated. 3. Based on the total number of sampling points of the original signal (7500 points in total, sampled at 250Hz for 30 minutes), calculate the filtering threshold using a logarithmic relationship; 4. Use this threshold to process the high-frequency coefficients of layers 1-3 (all of which are high-frequency components >100Hz), and retain the low-frequency coefficients of layers 4-5 (including low-frequency pathological features such as QRS waves and ST segments), so as to achieve a balance between high-frequency noise filtering and pathological feature preservation.

[0029] In this invention, the extraction method of time-domain features in the unsupervised multimodal feature extraction module of S2 is as follows: the waveform segments of the preprocessed ECG signal are truncated using the sliding window method, and the QRS amplitude, RR interval standard deviation, and ST segment offset of each segment are calculated, for a total of 3 time-domain parameters; the extraction method of frequency-domain features is as follows: the ECG signal preprocessed in S1 is subjected to fast Fourier transform, and the power spectral entropy and the energy ratio of the low-frequency and high-frequency bands of heart rate variability are calculated, for a total of 2 frequency-domain parameters; the extraction method of nonlinear features is as follows: the fractal dimension is calculated using the box counting method, and the sample entropy is calculated using the sample entropy algorithm, for a total of 2 nonlinear parameters; a total of 7 parameters are fused with equal weights to generate a comprehensive feature vector.

[0030] The sliding window is set to 2 seconds, sliding for 1 second at a time to ensure coverage of the entire signal and no repetition of segments; the QRS amplitude is taken as the difference between the peak value of the R wave and the trough value of the S wave within each window; the standard deviation of the RR interval is used to statistically analyze the dispersion of all adjacent heartbeat intervals within the window; the ST segment offset is compared with the potential at 80ms after the J point and the PR segment reference potential; 1024 points are taken when performing the fast Fourier transform; the power spectral entropy reflects the uniformity of signal energy distribution in the 0.5-40Hz frequency band; the energy ratio of the low-frequency band (0.04-0.15Hz) to the high-frequency band (0.15-0.4Hz) of heart rate variability reflects autonomic nerve function; the box counting method uses a box side length with a step size of 0.01-0.1mV to cover the waveform; the sample entropy is calculated by measuring the regularity of signal fluctuations; the seven parameters are first uniformly adjusted to between 0 and 1, and then each is added with a weight of one-seventh to form a comprehensive feature vector.

[0031] In this invention, the network structure parameters of the autoencoder in the unsupervised multimodal feature extraction module in S2 are as follows: the coding layer dimension is set to 128, the decoding layer dimension is consistent with the dimension of the preprocessed ECG signal, the mean square error is used as the loss function, and the distribution pattern of normal ECG signals is learned by minimizing the loss function, providing a benchmark for the subsequent pathological feature confidence calculation algorithm.

[0032] The number of neurons in the input layer of the autoencoder is the same as the length of the preprocessed signal (7500 neurons for 30 minutes of 250Hz sampling). The encoding layer has 128 neurons, and the ReLU activation function is used to enhance feature extraction. The number of neurons in the decoding layer is the same as the input layer, and the Sigmoid activation function is used to make the output signal range match the original signal. During training, ECG data from 100 people without cardiovascular disease are used. The network parameters are adjusted in each iteration. Training is stopped when the mean square error (reflecting the difference between the network output and input signals) drops below 0.01. At this point, the network can accurately reproduce the waveform pattern of normal ECG signals, providing a reliable normal signal benchmark for subsequent differentiation of "normal signals, pathological signals, and noise".

[0033] In this invention, the pathological feature confidence calculation algorithm of the second-level pathological-noise region molecular network in the cascaded adaptive evaluation module is used to achieve preliminary classification of candidate signals. The specific calculation formula includes:

[0034] In the formula: : Confidence level of pathological features, with a value range of [0,1], used as a preliminary classification basis; when A value ≥0.6 is initially considered a suspected pathological signal. If the value is less than 0.3, it is initially classified as noise; if 0.3 ≤ Signals with a value less than 0.6 are marked as fuzzy interval signals; The weight of the i-th pathological association feature includes three core pathological association features: ST segment offset, fractal dimension, and sample entropy, with corresponding weights of 0.4, 0.3, and 0.3, respectively. The weights are obtained by training with 500 myocardial infarction samples and 300 atrial fibrillation samples from a pre-set clinical pathological feature library. : No. The normalized value of each pathological correlation feature ranges from [0,1]. When the ST segment offset is greater than 0.1mV, the normalized value is 1. When the fractal dimension is less than 1.0, the normalized value is 1. When the sample entropy is less than 0.5, the normalized value is 1. : Reconstruction error correction coefficient, with a value of 0.2, is used to balance the influence of signal reconstruction results from unsupervised learning and the weights of pathological features; The reconstruction error of the autoencoder ranges from [0, 0.1]. The reconstruction error of the pathological waveform is higher than that of the normal signal but lower than that of the random noise due to deviation from the normal signal distribution. The reconstruction error of the normal signal is <0.02, the reconstruction error of the pathological signal is 0.02~0.05, and the reconstruction error of the noise is >0.05.

[0035] The calculation first takes the normalized values ​​of the three pathological features of the candidate signal and calculates the weighted sum according to the set weights. Then, the reconstruction effect of the autoencoder on the signal is observed (the smaller the reconstruction error, the closer the signal is to normal). After adjusting with correction coefficients, it is combined with the weighted sum to obtain a confidence level between 0 and 1. For example, a signal has an ST segment offset of 0.12mV, a fractal dimension of 0.9, and a sample entropy of 0.4 (all three normalized values ​​are 1), a reconstruction error of 0.03, and a weighted sum of 0.4 + 0.3 + 0.3 = 1. Combined with the correction coefficient, the confidence level is calculated to be about 0.86, which is judged as a suspected pathological signal. The weights of the three features are determined through repeated debugging of 800 pathological samples to ensure the sensitivity of identification of pathological features such as myocardial infarction and atrial fibrillation.

[0036] In the implementation of this invention, the confidence level of pathological features The initial classification threshold was determined by optimizing the receiver operating characteristic curve: using the pathological waveforms and noise marked in the preset clinical pathological feature library as the gold standard, the threshold was adjusted to make the overall accuracy of the initial classification ≥90%, while reserving a subdivision ratio of 10%~15% of the total signal for fuzzy interval signals.

[0037] We selected 500 clearly labeled pathological waveforms (covering myocardial infarction, atrial fibrillation, and premature ventricular contractions) and 300 noise signals from the feature library as reference standards to plot receiver operating characteristic (ROC) curves. By adjusting the confidence threshold, we ensured that both the "pathological signal recognition rate" and the "noise recognition rate" were at a high level. Ultimately, we determined that when the confidence level was ≥0.6, the pathological signal recognition rate exceeded 95%; when the confidence level was <0.3, the noise recognition rate exceeded 92%, and the overall classification accuracy reached 91%. Furthermore, the proportion of ambiguous signals between 0.3 and 0.6 was approximately 12%, which avoids increasing the processing pressure due to too many ambiguous signals and also avoids missing potential pathological information due to too few.

[0038] In this invention, the pre-defined clinical pathological feature database is constructed as follows: 1000 clinically diagnosed pathological electrocardiogram (ECG) samples and 500 normal ECG samples are collected, including 500 myocardial infarction samples, 300 atrial fibrillation samples, and 200 premature ventricular contraction (PVC) samples; waveform feature parameters are labeled for each sample, including QRS width, ST segment elevation amplitude, and RR interval regularity; three types of typical pathological waveform templates are generated using K-means clustering, with the parameters for each type being: The first type of template corresponds to myocardial infarction, and its parameters are ST segment elevation amplitude ≥0.1mV in the precordial leads or ≥0.2mV in the limb leads, and the QRS wave is QS type; The second type of template corresponds to atrial fibrillation, with parameters including an absolutely irregular RR interval, an f-wave frequency of 350~600 beats / min, and an f-wave amplitude of <0.1mV; The third type of template corresponds to premature ventricular contractions (PVCs), with parameters including QRS width > 120 ms and complete compensatory pause. The pre-set clinical pathology feature library has been clinically validated by tertiary hospitals, ensuring that the matching accuracy between the template and the real pathological waveform is ≥95%.

[0039] The samples were obtained from the cardiology departments of three tertiary hospitals, and all were diagnosed and signed by two associate chief physicians or above to avoid diagnostic errors. Professional electrocardiogram analysis software was used for annotation, with QRS wave width accurate to milliseconds and ST segment elevation amplitude accurate to 0.01mV. Three cluster centers were set for K-means clustering, corresponding to three types of pathology. After 30 iterations, the clustering results were stable, and the waveform similarity of samples in the same category exceeded 96%. Clinical validation used 200 pathological samples that were not included in the library construction and compared them with the three types of templates. The average matching accuracy was 95.8%, with the central infarction template showing the highest matching accuracy (97.2%), which can meet the clinical needs for the identification of typical pathological signals.

[0040] In this invention, the secondary classification algorithm of the second-level pathological-noise region molecular network in the cascaded adaptive evaluation module is used to subdivide the fuzzy interval signal. The output subdivision results include two categories: weak pathological signals and pseudo-pathological noise. The specific calculation formula includes:

[0041] In the formula: : Secondary classification confidence score, with a value range of [0,1], is used as the basis for subdivision; when A value ≥0.5 is considered a weak pathological signal. A value <0.5 is considered pseudo-pathological noise; The dispersion of pathological association features, with a value range of [0,1], is calculated as the ratio of the standard deviation of the three core pathological association features (ST segment offset, fractal dimension, and sample entropy) to the maximum value of each feature. : The matching residual between the signal and the preset clinical pathology feature library template, with a value range of [0,1]. It is calculated by the Euclidean distance between the comprehensive feature vector of the fuzzy interval signal and the feature vector of the most similar template in the preset clinical pathology feature library, and then normalized to the [0,1] interval. : The secondary classification balance coefficient, with a value of 0.4, is used to balance the weights of feature dispersion, matching residuals, and pathological feature confidence C; Pathological feature confidence score, which is the preliminary classification result output by the pathological feature confidence score calculation algorithm, with a value range of 0.3 ≤ <0.6.

[0042] The calculation first examines the dispersion of the three pathological features (the smaller the dispersion, the more stable the feature, and the more likely it is to be a true pathological signal). Then, it examines the similarity between the signal and the feature library template (the smaller the matching residual, the closer it is to the known pathological waveform). The balance coefficient is used to combine these two new indicators with the preliminary confidence level to obtain the secondary classification confidence level. For example, a certain fuzzy signal has a feature dispersion of 0.05, a template matching residual of 0.32, a preliminary confidence level of 0.45, and a balance coefficient of 0.4. The final calculated secondary confidence level is approximately 0.52, which is determined to be a weak pathological signal. The balance coefficient of 0.4 was determined through debugging 100 fuzzy signals, allowing the new indicators to work synergistically with the original confidence level to improve the subdivision accuracy.

[0043] In this invention, the selection rule for the most similar template in the secondary classification algorithm is as follows: for the comprehensive feature vector F_candidate of the fuzzy interval signal, calculate its Euclidean distance with the feature vectors of the three types of templates in the preset clinical pathology feature library, and select the template with the smallest distance as F_template; if the smallest Euclidean distance is greater than a preset threshold, which is 1.2 times the average Euclidean distance of all template feature vectors in the preset clinical pathology feature library, then e_match is forcibly set to 0.8.

[0044] First, calculate the distance between the fuzzy signal vector and the template vectors of the three types: myocardial infarction, atrial fibrillation, and premature ventricular contractions. Select the template with the smallest distance as the most similar template. For example, if the distances between a signal and the three types of templates are 0.28, 0.55, and 0.42 respectively, the smallest distance of 0.28 corresponds to the myocardial infarction template, which is the most similar template. First, calculate the average distance between the three types of templates in the feature library (e.g., 0.25), and set 1.2 times (0.3) of it as the threshold. If the distance between the signal and the most similar template is 0.28 (less than 0.3), calculate the matching residual based on the actual distance. If the distance is 0.35 (greater than 0.3), it means that the signal is very different from the known template. Force the matching residual to be set to 0.8 to avoid misjudging atypical noise as a pathological signal.

[0045] In this invention, the result fusion rule of the quality level output module is as follows: retain the suspected pathological signals and noise determined by the pathological feature confidence calculation algorithm, and add the weak pathological signals and pseudo-pathological noise output by the secondary classification algorithm to form four complete classifications; among them, the weak pathological signals need to be associated with the corresponding template type in the preset clinical pathological feature library to provide a reference for clinical diagnosis.

[0046] During the fusion process, the proportion of each of the four types of signals is first calculated. For example, suspected pathological signals account for 28%, noise 15%, weak pathological signals 45%, and pseudo-pathological noise 12%. The overall level is determined to be "requiring clinical observation" based on the fact that "weak pathological signals account for the highest proportion and exceed 50%". For each weak pathological signal, the template with the highest matching degree is found (for example, a weak pathological signal has a 92% matching degree with the premature ventricular contraction template). The output results are marked as "weak pathological signal (suspected premature ventricular contraction)" so that doctors can quickly understand the potential pathological type and improve diagnostic efficiency.

[0047] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended claims and their equivalents.

Claims

1. A method for assessing the quality of electrocardiogram (ECG) signals based on unsupervised cascaded adaptive networks, characterized in that, Includes the following steps: S1. Preprocess the acquired raw ECG signal: remove power frequency interference by adaptive notch filtering, remove high-frequency electromyographic noise by soft threshold wavelet filtering, and retain potential pathological waveforms during the filtering process to obtain the preprocessed ECG signal. S2, Unsupervised Multimodal Feature Extraction: An unsupervised feature extraction network based on an autoencoder extracts time-domain features, frequency-domain features, and nonlinear features from the ECG signal preprocessed in S1, and then fuses the three types of features to generate a comprehensive feature vector. S3. Cascaded Adaptive Evaluation: Construct a two-level adaptive evaluation network to process the comprehensive feature vector, specifically including: First-level noise filtering: The improved K-means algorithm is used to cluster and filter significant noise features in the comprehensive feature vector to remove obvious noise signals and output candidate signals. Second-level pathology-noise differentiation: An adaptive attention mechanism is introduced, and the candidate signals output from the first level are initially classified by the pathological feature confidence calculation algorithm, and the initial quality assessment results are output. The initial quality assessment results include three categories: suspected pathological signals, noise, and ambiguous interval signals. At the same time, the ambiguous interval signals are further subdivided by a secondary classification algorithm, and the subdivided results are output. The subdivided results include two categories: weak pathological signals and pseudo-pathological noise. S4. Output quality level: Combining the preliminary quality assessment results and subdivision results, as well as the preset clinical pathology feature library, output complete ECG signal quality assessment results. The complete ECG signal quality assessment results include four categories: suspected pathological signals, weak pathological signals, pseudo-pathological noise, and noise. The algorithm for calculating the confidence of pathological features in the second-level pathological-noise region molecular network in the cascaded adaptive evaluation module is used to achieve preliminary classification of candidate signals. The specific calculation formula is as follows: ; In the formula: : Pathological feature confidence level, with a value range of [0,1], used as a preliminary classification basis; when A value ≥0.6 is initially considered a suspected pathological signal. If the value is less than 0.3, it is initially classified as noise; if 0.3 ≤ Signals with a value less than 0.6 are marked as fuzzy interval signals; The weight of the i-th pathological association feature includes three core pathological association features: ST segment offset, fractal dimension, and sample entropy, with corresponding weights of 0.4, 0.3, and 0.3, respectively. The weights are obtained by training with 500 myocardial infarction samples and 300 atrial fibrillation samples from a pre-set clinical pathological feature library. : No. The normalized value of each pathological correlation feature ranges from [0,1]. When the ST segment offset is greater than 0.1mV, the normalized value is 1. When the fractal dimension is less than 1.0, the normalized value is 1. When the sample entropy is less than 0.5, the normalized value is 1. : Reconstruction error correction coefficient, with a value of 0.2, is used to balance the influence of signal reconstruction results from unsupervised learning and the weights of pathological features; The reconstruction error of the autoencoder ranges from [0, 0.1]. The reconstruction error of the pathological waveform is higher than that of the normal signal but lower than that of the random noise due to deviation from the normal signal distribution. The reconstruction error of the normal signal is <0.02, the reconstruction error of the pathological signal is 0.02~0.05, and the reconstruction error of the noise is >0.

05. The pre-defined clinical pathological feature database was constructed as follows: 1000 clinically diagnosed pathological electrocardiogram (ECG) samples and 500 normal ECG samples were collected. The pathological ECG samples included 500 myocardial infarction samples, 300 atrial fibrillation samples, and 200 premature ventricular contraction (PVC) samples. Waveform feature parameters were labeled for each sample, including QRS width, ST segment elevation amplitude, and RR interval regularity. Three typical pathological waveform templates were generated using K-means clustering. The parameters for the three typical pathological waveform templates were as follows: The first type of template corresponds to myocardial infarction, and its parameters are ST segment elevation amplitude ≥0.1mV in the precordial leads or ≥0.2mV in the limb leads, and the QRS wave is QS type; The second type of template corresponds to atrial fibrillation, with parameters including an absolutely irregular RR interval, an f-wave frequency of 350~600 beats / min, and an f-wave amplitude of <0.1mV; The third type of template corresponds to premature ventricular contractions (PVCs), with parameters including QRS width > 120 ms and complete compensatory pause. The pre-set clinical pathology feature database has been clinically validated in tertiary hospitals, ensuring that the matching accuracy between the template and the real pathological waveform is ≥95%. The secondary classification algorithm of the second-level pathological-noise region molecular network in the cascaded adaptive evaluation module is used to subdivide the signal in the fuzzy region. The output subdivision results include two categories: weak pathological signals and pseudo-pathological noise. The specific calculation formula is as follows: ; In the formula: : Secondary classification confidence score, with a value range of [0,1], is used as the basis for subdivision; when A value ≥0.5 is considered a weak pathological signal. A value <0.5 is considered pseudo-pathological noise; The dispersion of pathological association features, with a value range of [0,1], is calculated as the ratio of the standard deviation of the three core pathological association features (ST segment offset, fractal dimension, and sample entropy) to the maximum value of each feature. : The matching residual between the signal and the preset clinical pathology feature library template, with a value range of [0,1]. It is calculated by the Euclidean distance between the comprehensive feature vector of the fuzzy interval signal and the feature vector of the most similar template in the preset clinical pathology feature library, and then normalized to the [0,1] interval. : The secondary classification balance coefficient, with a value of 0.4, is used to balance the weights of feature dispersion, matching residuals, and pathological feature confidence C; Pathological feature confidence score, which is the preliminary classification result output by the pathological feature confidence score calculation algorithm, with a value range of 0.3 ≤ <0.6; The selection rule for the most similar template in the secondary classification algorithm is as follows: For the comprehensive feature vector F_candidate of the fuzzy interval signal, calculate its Euclidean distance with the feature vectors of the three types of templates in the preset clinical pathology feature library, and select the template with the smallest distance as F_template; if the smallest Euclidean distance is greater than the preset threshold, which is 1.2 times the average Euclidean distance of all template feature vectors in the preset clinical pathology feature library, then e_match is forcibly set to 0.

8.

2. The ECG signal quality assessment method based on unsupervised cascaded adaptive networks according to claim 1, characterized in that, The threshold calculation method for the soft threshold wavelet filter in the S1 ECG signal preprocessing module is as follows: based on the high-frequency coefficients after wavelet decomposition, the noise standard deviation is estimated, and combined with the number of sampling points of the original ECG signal, the threshold is determined through logarithmic relationship to ensure that high-frequency electromyographic noise with a frequency greater than 100Hz is removed without losing low-frequency pathological features.

3. The ECG signal quality assessment method based on unsupervised cascaded adaptive networks according to claim 1, characterized in that, The extraction method for time-domain features in the unsupervised multimodal feature extraction module of S2 is as follows: waveform segments of the preprocessed ECG signal are extracted using the sliding window method, and the QRS amplitude, RR interval standard deviation, and ST segment offset of each segment are calculated, totaling three time-domain parameters. The extraction method for frequency-domain features is as follows: fast Fourier transform is performed on the ECG signal preprocessed in S1, and the power spectral entropy and the energy ratio of the low-frequency and high-frequency bands of heart rate variability are calculated, totaling two frequency-domain parameters. The extraction method for nonlinear features is as follows: the fractal dimension is calculated using the box counting method, and the sample entropy is calculated using the sample entropy algorithm, totaling two nonlinear parameters. A total of seven parameters are fused with equal weights to generate a comprehensive feature vector.

4. The ECG signal quality assessment method based on unsupervised cascaded adaptive networks according to claim 3, characterized in that, The network structure parameters of the autoencoder in the unsupervised multimodal feature extraction module in S2 are as follows: the coding layer dimension is set to 128, the decoding layer dimension is consistent with the dimension of the preprocessed ECG signal, the mean square error is used as the loss function, and the distribution pattern of normal ECG signals is learned by minimizing the loss function, so as to provide a benchmark for the subsequent pathological feature confidence calculation algorithm.

5. The ECG signal quality assessment method based on unsupervised cascaded adaptive networks according to claim 4, characterized in that, Confidence of pathological features The initial classification threshold was determined by optimizing the receiver operating characteristic curve: using the pathological waveforms and noise marked in the preset clinical pathological feature library as the gold standard, the threshold was adjusted to make the overall accuracy of the initial classification ≥90%, while reserving a subdivision ratio of 10%~15% of the total signal for fuzzy interval signals.

6. The ECG signal quality assessment method based on unsupervised cascaded adaptive networks according to claim 5, characterized in that, The result fusion rule of the quality level output module is as follows: retain the suspected pathological signals and noise determined by the pathological feature confidence calculation algorithm, and add the weak pathological signals and pseudo-pathological noise output by the secondary classification algorithm to form four complete classifications; among them, the weak pathological signals need to be associated with the corresponding template type in the preset clinical pathological feature library to provide a reference for clinical diagnosis.

Citation Information

Patent Citations

  • Non-contact electrocardiosignal quality classification method

    CN114176519A

  • Mask self-supervision-based dynamic electrocardiogram quality assessment method

    CN118058751A