Electrocardiogram waveform real-time anomaly detection and early warning evaluation method and system

By combining an improved convolutional neural network and a graph attention neural network with a state transition graph, the problem of individual variability adaptation and dynamic evaluation in electrocardiogram (ECG) abnormality detection was solved, achieving high-precision recognition and real-time early warning of ECG waveforms.

CN120959757APending Publication Date: 2025-11-18JIANGSU MOBEN BIOMEDICAL TECHNOLOGY CO LTD
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202511410575.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-09-29
Publication Date
2025-11-18

AI Technical Summary

Technical Problem

Existing methods for detecting abnormal electrocardiograms have poor recognition performance when faced with highly variable, noisy, or atypical pathological waveforms, and lack the ability to adapt to individual differences, making it difficult to achieve dynamic assessment and real-time early warning.

Method used

An improved convolutional neural network and graph attention neural network combined with state transition graphs are used to extract time-frequency features of electrocardiogram waveforms, model state evolution, and generate multi-level response warnings. Multi-level response warnings are generated through local waveform extraction, frequency domain perturbation modeling, cross-cycle context aggregation, and graph attention mechanism.

Benefits of technology

It improves the accuracy and response speed of ECG abnormality identification, enables accurate assessment and real-time early warning of ECG abnormalities, and supports real-time intervention and remote early warning in clinical practice.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120959757A_ABST
    Figure CN120959757A_ABST
Patent Text Reader

Abstract

The invention discloses an electrocardiogram waveform real-time anomaly detection and early warning evaluation method and system, and the method comprises the following steps: S1, collecting the signal data of an electrocardiogram, and carrying out the preprocessing; s2, inputting the electrocardiogram segment sequence into an improved convolutional neural network, and performing feature extraction and aggregation; s3, inputting the fusion feature sequence into a graph attention neural network, and extracting a relation between waveform local dependence and fragment state transition; s4, inputting the global feature map into an anomaly evaluation network, and outputting an anomaly judgment result and a confidence score sequence; s5, generating a risk level tag sequence in combination with the individual parameters; s6, inputting the risk level label sequence into an early warning decision network, and generating a multi-level response label and an alarm trigger signal; and S7, controlling an early warning interface to execute alarm, and synchronously writing related data. According to the invention, real-time anomaly detection and multi-stage early warning response of the electrocardiogram waveform are realized, and the timeliness and reliability of abnormal heart rhythm recognition are improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the field of medical devices and precise positioning technology, and particularly relates to an electrocardiogram waveform real-time anomaly detection and early warning evaluation method and system. BACKGROUND

[0002] In the existing medical monitoring system, electrocardiogram is one of the most direct physiological signals reflecting the activity of the human heart, and is widely used in the early identification and clinical diagnosis of many diseases such as arrhythmia and myocardial ischemia. The traditional electrocardiogram anomaly detection method mainly relies on the rule template matching or the manual threshold setting method for static comparison. This kind of method is usually based on the fixed wave band characteristics of single lead signal, such as the amplitude and timing parameters of P wave, QRS complex and T wave, and determines whether the waveform is abnormal through a rule engine. This scheme has certain adaptability to standardized samples, but has poor recognition effect on pathological waveforms with strong variability, large noise interference or non-typical performance, and has high false detection rate, large missed detection rate and strong dependence on experience.

[0003] In recent years, artificial intelligence technologies such as deep learning have been gradually applied to the analysis field of electrocardiogram signals, and convolutional neural networks have shown superior performance in time series signal modeling. Some research works use end-to-end models to realize automatic classification of electrocardiogram anomalies, and have achieved good recognition accuracy in multiple public data sets. However, such models generally lack adaptability to individual differences, and are difficult to dynamically evaluate in multiple dimensions such as historical physiological parameters and heart rhythm changes. At the same time, most models only output a single abnormal classification result, lack explicit quantification of the determination confidence, do not have a complete risk grading and response mechanism, and cannot effectively support real-time intervention and remote early warning applications in actual clinical practice.

[0004] In addition, existing intelligent electrocardiogram monitoring products are mostly concentrated on mobile terminal side recognition, and the system structure is simple, lacking complex modeling capability for high-dimensional sequence dependence and state evolution process. Especially in the scene where electrocardiogram anomaly evolution has the characteristics of stage, suddenness and continuity, the lack of context-dependent modeling mechanism makes it difficult to identify the potential process of low-risk to high-risk transition, resulting in delayed or missing early warning.

[0005] Therefore, how to provide an electrocardiogram waveform real-time anomaly detection and early warning evaluation method and system is a problem that those skilled in the art need to solve. SUMMARY

[0006] One objective of this invention is to propose a method and system for real-time abnormal detection and early warning assessment of electrocardiogram (ECG) waveforms. This invention fully utilizes an improved convolutional neural network, a graph attention neural network, and an early warning decision model based on a state transition graph. It describes in detail the entire process of realizing ECG waveform time-frequency feature extraction, state evolution modeling, and multi-level response early warning, and has the advantages of high recognition accuracy, fast response speed, and strong risk assessment accuracy.

[0007] The method for real-time abnormal detection and early warning assessment of electrocardiogram waveforms according to embodiments of the present invention includes the following steps:

[0008] S1. Acquire electrocardiogram (ECG) signal data, perform preprocessing, and construct an ECG image segment sequence;

[0009] S2. Input the ECG image segment sequence into the improved convolutional neural network, perform local waveform extraction, frequency domain perturbation modeling and cross-cycle context aggregation respectively, and output the fused feature sequence.

[0010] S3. Input the fused feature sequence into the graph attention neural network. The first attention layer captures the local dependencies within the waveform, the second attention layer captures the state transition relationships between adjacent segments, and outputs a global feature map.

[0011] S4. Input the global feature map into the anomaly evaluation network, which consists of a hierarchical decoding unit and an attention confidence regression unit, and outputs the anomaly judgment result and confidence score sequence for each segment.

[0012] S5. Construct a risk level mapping table based on the abnormality judgment results and confidence score sequence, and calculate the risk level label sequence by combining the patient's resting heart rate, previous diagnosis results and individual rhythm parameters.

[0013] S6. Input the risk level label sequence into the early warning decision network constructed based on the state transition graph to generate a set of multi-level response labels and alarm trigger signals;

[0014] S7. The control and early warning interface completes the corresponding alarm action and synchronously writes the electrocardiogram segment, abnormal judgment result, confidence score sequence and risk level label sequence into the database.

[0015] Optionally, the signal data includes lead number, voltage sample value, sampling timestamp, and signal sampling frequency.

[0016] Optionally, the preprocessing includes bandpass filtering, baseline drift correction, outlier suppression, principal component compression, sliding window segmentation, and segmented normalization.

[0017] Optionally, S2 specifically includes:

[0018] S21. The preprocessed electrocardiogram signal is divided into segments using an equal-length sliding window method. Each segment is set to have 500 sampling points, and the overlapping area between adjacent segments is 250 sampling points, resulting in a continuous electrocardiogram segment sequence. Each segment is a sequence of original voltage values ​​for a single lead.

[0019] S22. Each electrocardiogram segment is sequentially input into a convolutional neural network with three different receptive field structures. The convolutional neural network consists of multiple convolutional channels. Each channel uses convolutional kernels with lengths of 5, 9, and 13, respectively. Local features are calculated by sliding under a fixed stride of 1, and multiple local waveform feature tensors are output. Each tensor retains the original sequence dimension.

[0020] S23. The output features of multiple convolutional channels are concatenated to form a multi-scale joint representation feature map, which is then input into the frequency domain perturbation modeling structure. The modeling structure uses a fixed window framing method to cut the time domain signal into several frames, uses fast Fourier transform to obtain the frequency domain amplitude spectrum corresponding to each frame, and calculates the energy density corresponding to each frequency point to model the frequency distribution characteristics and obtain the frequency domain perturbation feature matrix.

[0021] S24. The frequency domain perturbation feature matrix and the multi-scale joint representation feature map are concatenated along the channel dimension to construct a fusion tensor, and cross-cycle context aggregation is performed. The aggregation process includes two stacked gated loop structures, each layer of which has 128 hidden units. The context information of the preceding and following segments is encoded using a bidirectional processing method, and layer normalization, discard control and linear transformation operations are performed in sequence to form a fusion feature sequence.

[0022] Optionally, the improved convolutional neural network consists of a one-dimensional convolutional extraction layer, a frequency domain perturbation modeling layer, and a cross-period context aggregation layer connected sequentially. The one-dimensional convolutional extraction layer includes three sets of parallel convolutional branches with kernel lengths of 5, 9, and 13, respectively. Zero padding is used to maintain consistent output lengths, and the outputs of each branch are concatenated through channels to form a local feature map. The frequency domain perturbation modeling layer performs fixed-frame-length segmentation and Fourier transform on the local feature map, generates a spectrogram, calculates the frequency domain energy density of each frame, and outputs a frequency domain perturbation tensor. The cross-period context aggregation layer contains two bidirectional gated recurrent unit structures with a hidden state dimension of 128. It is equipped with residual connections and time-step attention weight extraction mechanisms, and outputs a fused feature sequence of uniform dimension.

[0023] Optionally, S3 specifically includes:

[0024] S31. Divide the fusion feature sequence into multiple nodes, each node corresponding to the fusion representation of an electrocardiogram segment, construct an initial undirected graph structure, and establish basic edge connections between each node in the graph according to the time sequence.

[0025] S32. Input the initial graph structure into the first attention layer of the graph attention neural network. The first attention layer adopts the node self-attention mechanism to perform weighted aggregation of the feature vectors inside each node. Through the multi-head attention structure, the local dependencies inside the waveform are extracted, and the intermediate graph structure containing the dynamic feature expression inside the segment is output.

[0026] S33. Input the intermediate graph structure into the second attention layer. The second attention layer uses the adjacency matrix dynamic update strategy to adjust the edge weights based on the temporal position relationship and feature similarity between nodes, capture the state transition relationship between adjacent segments, and generate an updated graph representation with structured transition information.

[0027] S34. The updated graph representation is processed by graph convolution and fully connected transformation to extract graph-level structured features and generate a global feature map of uniform size. The global feature map retains the state evolution pattern and waveform association structure between each electrocardiogram segment to support the anomaly assessment process.

[0028] Optionally, S4 specifically includes:

[0029] S41. Input the global feature map into the anomaly evaluation network. The anomaly evaluation network consists of a hierarchical decoding unit and an attention confidence regression unit. The hierarchical decoding unit has a three-layer decoding structure. The first decoding layer uses convolution transformation to extract key discriminative features. The second decoding layer performs dimension compression and nonlinear activation operations. The third decoding layer generates an anomaly label sequence with the same length as the original fragment sequence.

[0030] S42. The global feature map is input into the attention confidence regression unit in parallel. The attention confidence regression unit consists of a multi-head feature weighting structure and a regression mapping structure. The multi-head feature weighting structure extracts the confidence expression tensor according to the contextual attention relationship between segments. The regression mapping structure performs continuous value regression on the confidence expression tensor to generate a confidence score sequence that corresponds one-to-one with the anomaly label.

[0031] S43. Index and match the abnormal label sequence with the confidence score sequence to form an abnormality judgment result and confidence metric value for each electrocardiogram segment, which constitutes the final output judgment matrix and is provided to the risk level calculation process.

[0032] Optionally, S5 specifically includes:

[0033] S51. Based on the abnormal judgment results and confidence score sequence corresponding to each electrocardiogram segment, an initial risk feature set is constructed in chronological order. The risk feature set records the abnormal state, judgment intensity and duration of continuous abnormality for each segment.

[0034] S52. Extract the individual's resting heart rate parameters, previous diagnostic results and rhythm cycle distribution information. The resting heart rate is calculated by the average heart rate under historical no-load conditions. Previous diagnostic results are imported from historical health records. The rhythm cycle distribution information is obtained based on statistical analysis of intraday fluctuation range.

[0035] S53. Combine the initial risk feature set with individual physiological parameters to calculate, set multi-level risk level classification rules, and calculate the risk level label corresponding to each segment based on abnormal intensity, duration, baseline heart rate and historical medical history labels to form a risk level label sequence.

[0036] Optionally, S6 specifically includes:

[0037] S61. Input the risk level label sequence into the early warning decision network. The early warning decision network is constructed based on the state transition graph. The state transition graph consists of multiple directed state nodes and transition paths. Each state node corresponds to a risk level state. Each transition path is set with a fixed transition threshold and time dependence factor.

[0038] S62. Based on the time evolution order in the risk level label sequence, perform step-by-step node traversal and path selection on the state transition graph, calculate the state transition trajectory at each time point, determine whether there is a continuous transition from a low-risk state to a medium-to-high-risk state, and record the start and end positions of the continuous transition segments.

[0039] S63. Based on the state transition trajectory analysis results, call the preset response mapping rules to generate corresponding multi-level response tags. The response tags include observation level, intervention level and emergency level. Match and trigger the corresponding alarm signal output action according to different response tags to form the final alarm trigger signal set.

[0040] The real-time abnormal detection and early warning assessment system for electrocardiogram waveforms according to an embodiment of the present invention includes:

[0041] The signal processing module is used to acquire electrocardiogram (ECG) signal data, perform preprocessing, and construct an ECG image segment sequence.

[0042] The feature aggregation module is used to input the ECG image segment sequence into the improved convolutional neural network, and perform local waveform extraction, frequency domain perturbation modeling and cross-cycle context aggregation respectively, and output a fused feature sequence.

[0043] The global feature module is used to input the fused feature sequence into the graph attention neural network. The first attention layer captures the local dependencies within the waveform, the second attention layer captures the state transition relationships between adjacent segments, and outputs a global feature map.

[0044] An anomaly assessment module is used to input the global feature map into the anomaly assessment network, which consists of a hierarchical decoding unit and an attention confidence regression unit, and outputs the anomaly judgment result and confidence score sequence for each segment.

[0045] The risk mapping module is used to construct a risk level mapping table based on the anomaly judgment results and confidence score sequence, and to calculate the risk level label sequence by combining the patient's resting heart rate, previous diagnosis results and individual rhythm parameters.

[0046] The early warning response module is used to input the risk level label sequence into the early warning decision network constructed based on the state transition graph, and generate a set of multi-level response labels and alarm trigger signals;

[0047] The control synchronization module is used to control the early warning interface to complete the corresponding alarm action and synchronously write the electrocardiogram segment, abnormal judgment result, confidence score sequence and risk level label sequence into the database.

[0048] The beneficial effects of this invention are:

[0049] First, by constructing an improved convolutional neural network, this invention achieves multi-scale time-frequency joint feature extraction of electrocardiogram waveforms, which can fully capture the local changes and frequency domain perturbation features within the waveform, significantly improving the ability to identify atypical abnormal waveforms and solving the problem of low recognition accuracy of traditional template and threshold-based detection methods in complex noise environments.

[0050] Secondly, a graph attention neural network is introduced to perform graph construction on the fused feature sequence. By using two attention mechanisms to model the internal dependencies of waveform segments and the state transition paths between segments, the ability to express continuous abnormal evolution processes is effectively improved, making the identification of abnormal states more coherent and stable.

[0051] Finally, based on abnormal results and confidence score sequences, a risk level mapping and state transition map are constructed. Combined with the patient's resting heart rate, previous diagnostic records, and individual rhythm parameters, a multi-level response and early warning mechanism is formed. This not only improves the accuracy and timeliness of early warning, but also realizes closed-loop control of abnormality detection, risk assessment, and alarm linkage, effectively meeting the actual needs of rapid response and graded intervention for ECG abnormalities in clinical and remote monitoring scenarios. Attached Figure Description

[0052] The accompanying drawings are provided to further illustrate the invention and form part of the specification. They are used in conjunction with embodiments of the invention to explain the invention and do not constitute a limitation thereof. In the drawings:

[0053] Figure 1 The flowchart shows the real-time abnormal detection and early warning assessment method for electrocardiogram waveforms proposed in this invention.

[0054] Figure 2 The flowchart of the real-time abnormality detection method for electrocardiogram waveforms proposed in this invention is shown.

[0055] Figure 3 This is a flowchart of the electrocardiogram (ECG) abnormality assessment and early warning decision-making process for the real-time abnormality detection and early warning assessment method for ECG waveforms proposed in this invention.

[0056] Figure 4 This is a module structure diagram of the real-time abnormal detection and early warning assessment system for electrocardiogram waveforms proposed in this invention. Detailed Implementation

[0057] The present invention will now be described in further detail with reference to the accompanying drawings. These drawings are simplified schematic diagrams, illustrating only the basic structure of the invention, and therefore only show the components relevant to the invention.

[0058] refer to Figures 1-3 A method for real-time abnormal detection and early warning assessment of electrocardiogram waveforms includes the following steps:

[0059] S1. Acquire electrocardiogram (ECG) signal data, perform preprocessing, and construct an ECG image segment sequence;

[0060] S2. Input the ECG image segment sequence into the improved convolutional neural network, perform local waveform extraction, frequency domain perturbation modeling and cross-cycle context aggregation respectively, and output the fused feature sequence.

[0061] S3. Input the fused feature sequence into the graph attention neural network. The first attention layer captures the local dependencies within the waveform, the second attention layer captures the state transition relationships between adjacent segments, and outputs a global feature map.

[0062] S4. Input the global feature map into the anomaly evaluation network, which consists of a hierarchical decoding unit and an attention confidence regression unit, and outputs the anomaly judgment result and confidence score sequence for each segment.

[0063] S5. Construct a risk level mapping table based on the abnormality judgment results and confidence score sequence, and calculate the risk level label sequence by combining the patient's resting heart rate, previous diagnosis results and individual rhythm parameters.

[0064] S6. Input the risk level label sequence into the early warning decision network constructed based on the state transition graph to generate a set of multi-level response labels and alarm trigger signals;

[0065] S7. The control and early warning interface completes the corresponding alarm action and synchronously writes the electrocardiogram segment, abnormal judgment result, confidence score sequence and risk level label sequence into the database.

[0066] This invention constructs a comprehensive electrocardiogram (ECG) processing method consisting of signal processing, feature extraction, graph modeling, anomaly assessment, risk mapping, and early warning response. This method enables real-time analysis, anomaly identification, and graded early warning of ECG waveforms, thereby improving the immediate response capability and assessment accuracy for sudden cardiac arrhythmias.

[0067] In this embodiment, the signal data includes lead number, voltage sample value, sampling timestamp, and signal sampling frequency.

[0068] This invention ensures the integrity and consistency of input data by clearly defining the composition structure of the acquired signal, thus providing a high-quality input foundation for subsequent waveform segmentation and depth modeling.

[0069] In this embodiment, the preprocessing includes bandpass filtering, baseline drift correction, outlier suppression, principal component compression, sliding window segmentation, and segmented normalization.

[0070] This invention enhances the signal-to-noise ratio of the original electrocardiogram data by introducing techniques such as bandpass filtering, baseline correction, and principal component compression in the preprocessing stage, effectively reducing the impact of noise interference on the subsequent judgment process.

[0071] In this embodiment, S2 specifically includes:

[0072] S21. The preprocessed electrocardiogram signal is divided into segments using an equal-length sliding window method. Each segment is set to have 500 sampling points, and the overlapping area between adjacent segments is 250 sampling points, resulting in a continuous electrocardiogram segment sequence. Each segment is a sequence of original voltage values ​​for a single lead.

[0073] S22. Each electrocardiogram segment is sequentially input into a convolutional neural network with three different receptive field structures. The convolutional neural network consists of multiple convolutional channels. Each channel uses convolutional kernels with lengths of 5, 9, and 13, respectively. Local features are calculated by sliding under a fixed stride of 1, and multiple local waveform feature tensors are output. Each tensor retains the original sequence dimension.

[0074] S23. The output features of multiple convolutional channels are concatenated to form a multi-scale joint representation feature map, which is then input into the frequency domain perturbation modeling structure. The modeling structure uses a fixed window framing method to cut the time domain signal into several frames, uses fast Fourier transform to obtain the frequency domain amplitude spectrum corresponding to each frame, and calculates the energy density corresponding to each frequency point to model the frequency distribution characteristics and obtain the frequency domain perturbation feature matrix.

[0075] S24. The frequency domain perturbation feature matrix and the multi-scale joint representation feature map are concatenated along the channel dimension to construct a fusion tensor, and cross-cycle context aggregation is performed. The aggregation process includes two stacked gated loop structures, each layer of which has 128 hidden units. The context information of the preceding and following segments is encoded using a bidirectional processing method, and layer normalization, discard control and linear transformation operations are performed in sequence to form a fusion feature sequence.

[0076] This invention, by setting equal-length sliding windows and multiple convolutional channels, combined with frequency domain modeling and context aggregation, forms a fusion feature sequence with a rigorous structure and strong expressive power, thereby improving the sensitivity of abnormal segments in complex waveforms.

[0077] In this embodiment, the improved convolutional neural network consists of a one-dimensional convolutional extraction layer, a frequency domain perturbation modeling layer, and a cross-period context aggregation layer connected sequentially. The one-dimensional convolutional extraction layer includes three sets of parallel convolutional branches with kernel lengths of 5, 9, and 13, respectively. Zero padding is used to maintain consistent output lengths, and the outputs of each branch are concatenated through channels to form a local feature map. The frequency domain perturbation modeling layer performs fixed-frame-length segmentation and Fourier transform on the local feature map, generates a spectrogram, calculates the frequency domain energy density of each frame, and outputs a frequency domain perturbation tensor. The cross-period context aggregation layer contains two bidirectional gated recurrent unit structures with a hidden state dimension of 128. It is equipped with residual connections and time-step attention weight extraction mechanisms, and outputs a fused feature sequence of uniform dimension.

[0078] This invention enhances the representation ability of electrocardiogram segments with different time scales and frequency distributions by constructing an improved convolutional neural network with multi-receptor field structure and frequency domain modeling capability, thereby improving the comprehensiveness and depth of feature extraction.

[0079] In this embodiment, S3 specifically includes:

[0080] S31. Divide the fusion feature sequence into multiple nodes, each node corresponding to the fusion representation of an electrocardiogram segment, construct an initial undirected graph structure, and establish basic edge connections between each node in the graph according to the time sequence.

[0081] S32. Input the initial graph structure into the first attention layer of the graph attention neural network. The first attention layer adopts the node self-attention mechanism to perform weighted aggregation of the feature vectors inside each node. Through the multi-head attention structure, the local dependencies inside the waveform are extracted, and the intermediate graph structure containing the dynamic feature expression inside the segment is output.

[0082] S33. Input the intermediate graph structure into the second attention layer. The second attention layer uses the adjacency matrix dynamic update strategy to adjust the edge weights based on the temporal position relationship and feature similarity between nodes, capture the state transition relationship between adjacent segments, and generate an updated graph representation with structured transition information.

[0083] S34. The updated graph representation is processed by graph convolution and fully connected transformation to extract graph-level structured features and generate a global feature map of uniform size. The global feature map retains the state evolution pattern and waveform association structure between each electrocardiogram segment to support the anomaly assessment process.

[0084] This invention introduces a two-layer graph attention mechanism to simultaneously model the internal structure of the waveform and the state transition process between segments, preserving the temporal dependence and structural integrity of the electrocardiogram sequence and improving the stability of the abnormality identification results.

[0085] In this embodiment, S4 specifically includes:

[0086] S41. Input the global feature map into the anomaly evaluation network. The anomaly evaluation network consists of a hierarchical decoding unit and an attention confidence regression unit. The hierarchical decoding unit has a three-layer decoding structure. The first decoding layer uses convolution transformation to extract key discriminative features. The second decoding layer performs dimension compression and nonlinear activation operations. The third decoding layer generates an anomaly label sequence with the same length as the original fragment sequence.

[0087] S42. The global feature map is input into the attention confidence regression unit in parallel. The attention confidence regression unit consists of a multi-head feature weighting structure and a regression mapping structure. The multi-head feature weighting structure extracts the confidence expression tensor according to the contextual attention relationship between segments. The regression mapping structure performs continuous value regression on the confidence expression tensor to generate a confidence score sequence that corresponds one-to-one with the anomaly label.

[0088] S43. Index and match the abnormal label sequence with the confidence score sequence to form an abnormality judgment result and confidence metric value for each electrocardiogram segment, which constitutes the final output judgment matrix and is provided to the risk level calculation process.

[0089] This invention designs an anomaly assessment network that includes a decoding structure and confidence evaluation, which not only outputs anomaly judgment results but also quantifies their credibility, providing a reliable support basis for subsequent risk mapping and graded intervention.

[0090] In this embodiment, S5 specifically includes:

[0091] S51. Based on the abnormal judgment results and confidence score sequence corresponding to each electrocardiogram segment, an initial risk feature set is constructed in chronological order. The risk feature set records the abnormal state, judgment intensity and duration of continuous abnormality for each segment.

[0092] S52. Extract the individual's resting heart rate parameters, previous diagnostic results and rhythm cycle distribution information. The resting heart rate is calculated by the average heart rate under historical no-load conditions. Previous diagnostic results are imported from historical health records. The rhythm cycle distribution information is obtained based on statistical analysis of intraday fluctuation range.

[0093] S53. Combine the initial risk feature set with individual physiological parameters to calculate, set multi-level risk level classification rules, and calculate the risk level label corresponding to each segment based on abnormal intensity, duration, baseline heart rate and historical medical history labels to form a risk level label sequence.

[0094] This invention constructs a multi-factor risk level assessment mechanism by combining individual resting heart rate, historical diagnostic records, and rhythm cycle characteristics, enabling risk assessment results to have individualized adaptability and effectively enhancing the accuracy of clinical risk assessment.

[0095] In this embodiment, S6 specifically includes:

[0096] S61. Input the risk level label sequence into the early warning decision network. The early warning decision network is constructed based on the state transition graph. The state transition graph consists of multiple directed state nodes and transition paths. Each state node corresponds to a risk level state. Each transition path is set with a fixed transition threshold and time dependence factor.

[0097] S62. Based on the time evolution order in the risk level label sequence, perform step-by-step node traversal and path selection on the state transition graph, calculate the state transition trajectory at each time point, determine whether there is a continuous transition from a low-risk state to a medium-to-high-risk state, and record the start and end positions of the continuous transition segments.

[0098] S63. Based on the state transition trajectory analysis results, call the preset response mapping rules to generate corresponding multi-level response tags. The response tags include observation level, intervention level and emergency level. Match and trigger the corresponding alarm signal output action according to different response tags to form the final alarm trigger signal set.

[0099] This invention captures the dynamic evolution trend of risk levels by constructing an early warning decision network based on state transition graphs, realizes multi-level response tag generation and real-time alarm linkage, and improves the predictability and response time of the overall system.

[0100] refer to Figure 4A real-time electrocardiogram waveform anomaly detection and early warning assessment system, including:

[0101] The signal processing module is used to acquire electrocardiogram (ECG) signal data, perform preprocessing, and construct an ECG image segment sequence.

[0102] The feature aggregation module is used to input the ECG image segment sequence into the improved convolutional neural network, and perform local waveform extraction, frequency domain perturbation modeling and cross-cycle context aggregation respectively, and output a fused feature sequence.

[0103] The global feature module is used to input the fused feature sequence into the graph attention neural network. The first attention layer captures the local dependencies within the waveform, the second attention layer captures the state transition relationships between adjacent segments, and outputs a global feature map.

[0104] An anomaly assessment module is used to input the global feature map into the anomaly assessment network, which consists of a hierarchical decoding unit and an attention confidence regression unit, and outputs the anomaly judgment result and confidence score sequence for each segment.

[0105] The risk mapping module is used to construct a risk level mapping table based on the anomaly judgment results and confidence score sequence, and to calculate the risk level label sequence by combining the patient's resting heart rate, previous diagnosis results and individual rhythm parameters.

[0106] The early warning response module is used to input the risk level label sequence into the early warning decision network constructed based on the state transition graph, and generate a set of multi-level response labels and alarm trigger signals;

[0107] The control synchronization module is used to control the early warning interface to complete the corresponding alarm action and synchronously write the electrocardiogram segment, abnormal judgment result, confidence score sequence and risk level label sequence into the database.

[0108] The system proposed in this invention has a complete structure and clear functional module division. The modules work together to form a closed-loop processing flow, supporting intelligent processing of the entire process from raw data access to multi-level alarm output. It has high integration and practicality.

[0109] Example 1:

[0110] To verify the feasibility of this invention in practice, it was applied to a scenario involving dynamic electrocardiogram (ECG) data collected by a wearable health monitoring terminal. The test subjects were middle-aged and elderly individuals and those with underlying arrhythmia symptoms. Existing mobile ECG monitoring methods rely on device-side threshold judgment or static template matching, which often suffers from inaccurate identification and delayed abnormality detection for segments with large heart rate fluctuations. This leads to missed or false alarms of true heart rate abnormalities, affecting the efficiency of medical intervention. The method proposed in this invention is integrated into an analysis platform for real-time processing and dynamic risk assessment of 72 consecutive hours of raw ECG data.

[0111] During testing, the monitoring equipment continuously collected single-lead voltage data at a sampling frequency of 500 times per second. The data was transmitted to the processing platform in real time. First, the signal processing module performed bandpass filtering and sliding window segmentation to construct a normalized sequence of ECG image segments. Then, the feature extraction module extracted multi-scale convolutional features and frequency perturbation features, combining them with cross-cycle contextual information to form a time-series feature map. This feature map was processed by a graph attention network to capture the evolutionary structural relationships between waveform segments, and further passed to the anomaly assessment network to output an anomaly label and confidence score for each segment. Based on the judgment results, historical heart rate records, and rhythm parameters, the system generated multi-level risk labels and used a state transition graph model to determine whether continuous high-risk transitions occurred, ultimately triggering alarms and initiating alarm actions.

[0112] By comparing the system with a traditional baseline template comparison system, continuous electrocardiogram (ECG) data from 500 users were analyzed to compare the performance of the proposed method with that of the traditional method in terms of anomaly identification accuracy, response delay, false alarm rate, and missed alarm rate. The results show that the proposed system can effectively capture high-frequency atrial fibrillation and premature ventricular contractions (PVCs) in continuous anomaly identification, issuing a moderate to high-risk warning 30 seconds in advance, a 27-second improvement compared to the traditional method. The anomaly identification accuracy reached 96.2%, an improvement of 12.7 percentage points compared to the traditional method, with the missed alarm rate reduced to 1.8% and the false alarm rate controlled below 2.0%. More importantly, when there are no obvious abnormal waveforms in the middle of the ECG data but a trend towards rhythm disorder, the proposed system can identify potential high-risk transformation trends based on contextual state transition patterns, significantly enhancing the predictability of the warning.

[0113] The following is a statistical table of system verification data:

[0114] Table 1. Performance Comparison Data Between the Invention Method and Traditional Methods (Statistical Table)

[0115]

[0116] In summary, this invention demonstrates high recognition rate, low error, and fast response in the intelligent processing of continuous electrocardiogram data, significantly outperforming existing rule-based judgment systems and possessing strong clinical early warning application value.

[0117] The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any equivalent substitutions or modifications made by those skilled in the art within the scope of the technology disclosed in the present invention, based on the technical solution and inventive concept of the present invention, should be covered within the scope of protection of the present invention.

Claims

1. A method for real-time abnormal detection and early warning assessment of electrocardiogram waveforms, characterized in that, Includes the following steps: S1. Acquire electrocardiogram (ECG) signal data, perform preprocessing, and construct an ECG image segment sequence; S2. Input the ECG image segment sequence into the improved convolutional neural network, perform local waveform extraction, frequency domain perturbation modeling and cross-cycle context aggregation respectively, and output the fused feature sequence. S3. Input the fused feature sequence into the graph attention neural network. The first attention layer captures the local dependencies within the waveform, the second attention layer captures the state transition relationships between adjacent segments, and outputs a global feature map. S4. Input the global feature map into the anomaly evaluation network, which consists of a hierarchical decoding unit and an attention confidence regression unit, and outputs the anomaly judgment result and confidence score sequence for each segment. S5. Construct a risk level mapping table based on the abnormality judgment results and confidence score sequence, and calculate the risk level label sequence by combining the patient's resting heart rate, previous diagnosis results and individual rhythm parameters. S6. Input the risk level label sequence into the early warning decision network constructed based on the state transition graph to generate a set of multi-level response labels and alarm trigger signals; S7. The control and early warning interface completes the corresponding alarm action and synchronously writes the electrocardiogram segment, abnormal judgment result, confidence score sequence and risk level label sequence into the database.

2. The method for real-time abnormal detection and early warning assessment of electrocardiogram waveforms according to claim 1, characterized in that, The signal data includes lead number, voltage sample value, sampling timestamp, and signal sampling frequency.

3. The method for real-time abnormal detection and early warning assessment of electrocardiogram waveforms according to claim 1, characterized in that, The preprocessing includes bandpass filtering, baseline drift correction, outlier suppression, principal component compression, sliding window segmentation, and segmented normalization.

4. The method for real-time abnormal detection and early warning assessment of electrocardiogram waveforms according to claim 1, characterized in that, S2 specifically includes: S21. The preprocessed electrocardiogram signal is divided into segments using an equal-length sliding window method. Each segment is set to have 500 sampling points, and the overlapping area between adjacent segments is 250 sampling points, resulting in a continuous electrocardiogram segment sequence. Each segment is a sequence of original voltage values ​​for a single lead. S22. Each electrocardiogram segment is sequentially input into a convolutional neural network with three different receptive field structures. The convolutional neural network consists of multiple convolutional channels. Each channel uses convolutional kernels with lengths of 5, 9, and 13, respectively. Local features are calculated by sliding under a fixed stride of 1, and multiple local waveform feature tensors are output. Each tensor retains the original sequence dimension. S23. The output features of multiple convolutional channels are concatenated to form a multi-scale joint representation feature map, which is then input into the frequency domain perturbation modeling structure. The modeling structure uses a fixed window framing method to cut the time domain signal into several frames, uses fast Fourier transform to obtain the frequency domain amplitude spectrum corresponding to each frame, and calculates the energy density corresponding to each frequency point to model the frequency distribution characteristics and obtain the frequency domain perturbation feature matrix. S24. The frequency domain perturbation feature matrix and the multi-scale joint representation feature map are concatenated along the channel dimension to construct a fusion tensor, and cross-cycle context aggregation is performed. The aggregation process includes two stacked gated loop structures, each layer of which has 128 hidden units. The context information of the preceding and following segments is encoded using a bidirectional processing method, and layer normalization, discard control and linear transformation operations are performed in sequence to form a fusion feature sequence.

5. The method for real-time abnormal detection and early warning assessment of electrocardiogram waveforms according to claim 4, characterized in that, The improved convolutional neural network consists of a one-dimensional convolutional extraction layer, a frequency domain perturbation modeling layer, and a cross-period context aggregation layer connected sequentially. The one-dimensional convolutional extraction layer includes three sets of parallel convolutional branches with kernel lengths of 5, 9, and 13, respectively. Zero padding is used to maintain consistent output lengths, and the outputs of each branch are concatenated through channels to form a local feature map. The frequency domain perturbation modeling layer performs fixed-frame-length segmentation and Fourier transform on the local feature map, generates a spectrogram, calculates the frequency domain energy density of each frame, and outputs a frequency domain perturbation tensor. The cross-period context aggregation layer contains two bidirectional gated recurrent unit structures with a hidden state dimension of 128. It is equipped with residual connections and time-step attention weight extraction mechanisms, and outputs a fused feature sequence with a unified dimension.

6. The method for real-time abnormal detection and early warning assessment of electrocardiogram waveforms according to claim 1, characterized in that, S3 specifically includes: S31. Divide the fusion feature sequence into multiple nodes, each node corresponding to the fusion representation of an electrocardiogram segment, construct an initial undirected graph structure, and establish basic edge connections between each node in the graph according to the time sequence. S32. Input the initial graph structure into the first attention layer of the graph attention neural network. The first attention layer adopts the node self-attention mechanism to perform weighted aggregation of the feature vectors inside each node. Through the multi-head attention structure, the local dependencies inside the waveform are extracted, and the intermediate graph structure containing the dynamic feature expression inside the segment is output. S33. Input the intermediate graph structure into the second attention layer. The second attention layer uses the adjacency matrix dynamic update strategy to adjust the edge weights based on the temporal position relationship and feature similarity between nodes, capture the state transition relationship between adjacent segments, and generate an updated graph representation with structured transition information. S34. The updated graph representation is processed by graph convolution and fully connected transformation to extract graph-level structured features and generate a global feature map of uniform size. The global feature map retains the state evolution pattern and waveform association structure between each electrocardiogram segment to support the anomaly assessment process.

7. The method for real-time abnormal detection and early warning assessment of electrocardiogram waveforms according to claim 1, characterized in that, S4 specifically includes: S41. Input the global feature map into the anomaly evaluation network. The anomaly evaluation network consists of a hierarchical decoding unit and an attention confidence regression unit. The hierarchical decoding unit has a three-layer decoding structure. The first decoding layer uses convolution transformation to extract key discriminative features. The second decoding layer performs dimension compression and nonlinear activation operations. The third decoding layer generates an anomaly label sequence with the same length as the original fragment sequence. S42. The global feature map is input into the attention confidence regression unit in parallel. The attention confidence regression unit consists of a multi-head feature weighting structure and a regression mapping structure. The multi-head feature weighting structure extracts the confidence expression tensor according to the contextual attention relationship between segments. The regression mapping structure performs continuous value regression on the confidence expression tensor to generate a confidence score sequence that corresponds one-to-one with the anomaly label. S43. Index and match the abnormal label sequence with the confidence score sequence to form an abnormality judgment result and confidence metric value for each electrocardiogram segment, which constitutes the final output judgment matrix and is provided to the risk level calculation process.

8. The method for real-time abnormal detection and early warning assessment of electrocardiogram waveforms according to claim 1, characterized in that, S5 specifically includes: S51. Based on the abnormal judgment results and confidence score sequence corresponding to each electrocardiogram segment, an initial risk feature set is constructed in chronological order. The risk feature set records the abnormal state, judgment intensity and duration of continuous abnormality for each segment. S52. Extract the individual's resting heart rate parameters, previous diagnostic results and rhythm cycle distribution information. The resting heart rate is calculated by the average heart rate under historical no-load conditions. Previous diagnostic results are imported from historical health records. The rhythm cycle distribution information is obtained based on statistical analysis of intraday fluctuation range. S53. Combine the initial risk feature set with individual physiological parameters to calculate, set multi-level risk level classification rules, and calculate the risk level label corresponding to each segment based on abnormal intensity, duration, baseline heart rate and historical medical history labels to form a risk level label sequence.

9. The method for real-time abnormal detection and early warning assessment of electrocardiogram waveforms according to claim 1, characterized in that, S6 specifically includes: S61. Input the risk level label sequence into the early warning decision network. The early warning decision network is constructed based on the state transition graph. The state transition graph consists of multiple directed state nodes and transition paths. Each state node corresponds to a risk level state. Each transition path is set with a fixed transition threshold and time dependence factor. S62. Based on the time evolution order in the risk level label sequence, perform step-by-step node traversal and path selection on the state transition graph, calculate the state transition trajectory at each time point, determine whether there is a continuous transition from a low-risk state to a medium-to-high-risk state, and record the start and end positions of the continuous transition segments. S63. Based on the state transition trajectory analysis results, call the preset response mapping rules to generate corresponding multi-level response tags. The response tags include observation level, intervention level and emergency level. Match and trigger the corresponding alarm signal output action according to different response tags to form the final alarm trigger signal set.

10. A real-time electrocardiogram waveform anomaly detection and early warning assessment system, comprising the real-time electrocardiogram waveform anomaly detection and early warning assessment method according to any one of claims 1 to 9, characterized in that, include: The signal processing module is used to acquire electrocardiogram (ECG) signal data, perform preprocessing, and construct an ECG image segment sequence. The feature aggregation module is used to input the ECG image segment sequence into the improved convolutional neural network, and perform local waveform extraction, frequency domain perturbation modeling and cross-cycle context aggregation respectively, and output a fused feature sequence. The global feature module is used to input the fused feature sequence into the graph attention neural network. The first attention layer captures the local dependencies within the waveform, the second attention layer captures the state transition relationships between adjacent segments, and outputs a global feature map. An anomaly assessment module is used to input the global feature map into the anomaly assessment network, which consists of a hierarchical decoding unit and an attention confidence regression unit, and outputs the anomaly judgment result and confidence score sequence for each segment. The risk mapping module is used to construct a risk level mapping table based on the anomaly judgment results and confidence score sequence, and to calculate the risk level label sequence by combining the patient's resting heart rate, previous diagnosis results and individual rhythm parameters. The early warning response module is used to input the risk level label sequence into the early warning decision network constructed based on the state transition graph, and generate a set of multi-level response labels and alarm trigger signals; The control synchronization module is used to control the early warning interface to complete the corresponding alarm action and synchronously write the electrocardiogram segment, abnormal judgment result, confidence score sequence and risk level label sequence into the database.

Citation Information

Cited By

  • Atrial fibrillation early warning method and system based on multi-time scale trend energy modeling

    CN121313192A

  • Self-adaptive health threshold alarm method for wearable device based on millimeter wave radar

    CN121439235A