Electrocardiosignal analysis processing method, system, medium and equipment
By constructing an ECG feature occlusion analysis method and an explanatory report, the usability and interpretability issues of the ECG analysis system were solved, automatic identification of atrial fibrillation and generation of an explanatory report were achieved, and the usability and quantitative analysis capabilities of ECG analysis were improved.
Patent Information
- Application Number
- CN202510589508.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-08
- Publication Date
- 2025-09-12
AI Technical Summary
Existing deep learning methods are not very usable in electrocardiogram analysis and lack interpretability, making it difficult to achieve interpretable and quantitative analysis of electrocardiogram analysis systems.
The electrocardiogram feature occlusion method is used to construct a deep learning model and an explanatory analysis model to generate an explanation report. Atrial fibrillation is diagnosed through a one-dimensional residual convolution feature extraction module and a classification module. The Hamilton segmentation algorithm is used to locate feature points and generate an explanation report on the atrial fibrillation waves and irregular interval characteristics.
It realizes automatic identification of atrial fibrillation and generates result interpretation reports, solves the usability and interpretability issues of electrocardiogram analysis, and improves the usability and quantitative analysis capabilities of the electrocardiogram analysis system.
Smart Images

Figure CN120616563A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of digital medical technology, and in particular to an electrocardiogram signal analysis and processing method, system, medium and equipment. Background Art
[0002] The electrocardiogram (ECG) is one of the most commonly used non-invasive clinical examination methods and is of great value in the diagnosis of cardiovascular disease. With the development of artificial intelligence (AI), a number of deep learning models have been gradually applied to automated ECG analysis, including ECG recognition, atrial fibrillation detection, and arrhythmia classification.
[0003] However, current deep learning methods often only address specific problems or can only assist with a single step in ECG data analysis, resulting in limited usability. Furthermore, most current methods are black-box systems, lacking interpretability and low physician acceptance. Therefore, a technical solution is urgently needed to improve the usability and interpretability of ECG analysis systems.
[0004] Chinese patent publication CN118154501A discloses a chest image pathology prediction method based on group decoupling representation. This method addresses the feature overlap problem inherent in interpretable deep learning methods by employing a group decoupling module and an adversarial constraint module to extract semantically rich, fine-grained features, improving classification performance and the interpretability of the classification model. However, this approach does not qualify as a post-interpretation method, requiring additional steps during training, which limits its application. Furthermore, the interpretability is not specifically integrated with the input domain semantic knowledge, relegating it to qualitative explanatory analysis. Summary of the Invention
[0005] In view of the defects in the prior art, the purpose of the present invention is to provide an electrocardiogram signal analysis and processing method, system, medium and equipment.
[0006] According to the present invention, a method for analyzing and processing an electrocardiogram signal is provided, comprising:
[0007] Step S1: Obtaining the ECG data to be analyzed;
[0008] Step S2: preprocessing the ECG data to be analyzed to obtain preprocessed ECG data to be analyzed;
[0009] Step S3: using the deep learning model to perform recognition processing on the ECG data to be analyzed, obtaining a first recognition result and semantic features generated by the deep learning model during the reasoning process;
[0010] Step S4: Analyze the first recognition result and semantic features using the explanatory analysis model, obtain the extraction results of the fibrillation waves and irregular interval features of atrial fibrillation in the electrocardiogram data using the deep learning model, and generate an explanation report.
[0011] Preferably, the construction of the deep learning model includes:
[0012] Step S3.1: constructing an atrial fibrillation diagnostic model, including a one-dimensional residual convolution feature extraction module and a classification module;
[0013] Step S3.2: Constructing atrial fibrillation diagnosis model training samples, labeling abnormal segments in the ECG data with disease types, and obtaining an ECG database;
[0014] Step S3.3: Preprocessing the ECG database, including data standardization and filtering operations, to obtain a preprocessed ECG database;
[0015] Step S3.4: Using the ECG database to train the atrial fibrillation diagnosis model to obtain a trained atrial fibrillation diagnosis model.
[0016] Preferably, the ECG data includes a normal sinus rhythm ECG and an atrial fibrillation ECG; the ECG database contains two types of information: a 10-second one-dimensional ECG signal and a label, where the label is 0 or 1, where 1 indicates atrial fibrillation and 0 indicates normal.
[0017] Preferably, the step S4 includes:
[0018] Step S4.1: constructing an atrial fibrillation wave characteristic model and an interval irregularity model;
[0019] Step S4.2: performing a quality assessment on the atrial fibrillation signals in the ECG database in step S3 to obtain an atrial fibrillation database for constructing an interpretation model;
[0020] Step S4.3: Perform occlusion analysis on each piece of data in the constructed atrial fibrillation database, including data feature point search and feature waveform transformation operations, to obtain two pieces of data that occlude specific ECG features;
[0021] Step S4.4: Analyze the original atrial fibrillation data and the masked data using the atrial fibrillation diagnosis model to obtain three sets of diagnosis results and intermediate features;
[0022] Step S4.5: Using the intermediate features and the diagnosis results, extract the fibrillation wave feature sensitive channels and the interval irregularity sensitive channels, and calculate the mean and variance of the channel activation factors;
[0023] Step S4.6: Use the cumulative probability distribution function of the tremor wave characteristic model and the interval irregularity model to divide the interval and describe the characteristic morphology, and obtain the interpretation report template and construction rules.
[0024] Preferably, the quality assessment in step S4.2 includes:
[0025] Amplitude assessment: If the ECG signal amplitude exceeds the range of [-3mv, 3mv], it is judged as low quality and excluded;
[0026] Volatility assessment: Calculate the mean and standard deviation of the entire signal, and use the 5σ principle to determine if the signal exceeds the range and exclude it;
[0027] Feature point positioning evaluation: Use the Hamilton segmentation algorithm to locate the ECG P, Q, R, S, and T feature points. If the algorithm is wrong, the signal will be excluded.
[0028] Preferably, the step S4.3 includes:
[0029] Step S4.3.1: Use Hamilton segmentation algorithm to locate ECG reference points and obtain the feature point set of all heart beats {P s ,P,Q s ,Q,R,S,T,T e}, where P s , P are automatically obtained by the algorithm, representing the P wave starting point and P wave position respectively, which are not used in atrial fibrillation occlusion analysis, and Q s With T e Represent the starting point of Q wave and the ending point of T wave of all heart beats respectively; s With T e The entire signal is divided into a set of N heartbeats HB and a baseline set BL, where
[0030] Step S4.3.2: Interval feature mask operation: First, use R to calculate the average RR interval And calculate the distance moved for each heartbeat Beat HB with your heart i Move forward or backward D i make The baseline between two heart beats is obtained from BL, and then the ECG signal with mask interval characteristics is obtained;
[0031] Step S4.3.3: Flutter mask operation: used for f-wave elimination and P-wave filling, based on and Two-point linear interpolation to replace BL i To eliminate the f wave, for the disappeared P wave, use the P wave of the normal ECG signal as the standard P wave and add it to the new BL i Finally, the heartbeat set HB and the new baseline set BL are combined into a new ECG signal to obtain the masked fibrillation wave ECG signal.
[0032] Preferably, the intermediate features are semantic features, deep learning features before the classification layer, and are output from the computational graph during model inference.
[0033] According to the present invention, an electrocardiogram signal analysis and processing system is provided, comprising:
[0034] Module M1: Obtaining ECG data to be analyzed;
[0035] Module M2: preprocesses the ECG data to be analyzed to obtain the preprocessed ECG data to be analyzed;
[0036] Module M3: Using the deep learning model to perform recognition processing on the ECG data to be analyzed, obtaining a first recognition result and semantic features generated by the deep learning model during the reasoning process;
[0037] Module M4: Use the explanatory analysis model to analyze the first recognition results and semantic features, obtain the extraction results of the deep learning model for the fibrillation waves and irregular interval features of atrial fibrillation in the ECG data, and generate an explanation report.
[0038] According to the present invention, a computer-readable storage medium storing a computer program is provided. When the computer program is executed by a processor, the steps of the electrocardiogram signal analysis and processing method are implemented.
[0039] According to the present invention, an electrocardiogram signal analysis and processing device is provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor. When the computer program is executed by the processor, the steps of the electrocardiogram signal analysis and processing method are implemented.
[0040] Compared with the prior art, the present invention has the following beneficial effects:
[0041] 1. The present invention provides an electrocardiogram signal analysis method that can automatically identify atrial fibrillation and simultaneously provide a result interpretation report. It adopts an electrocardiogram feature masking method to solve the problem that conventional mask masking methods are unreasonable in analyzing electrocardiograms, and achieves the effect of masking any semantic feature of the electrocardiogram.
[0042] 2. The present invention adopts the method of constructing a post-interpretative report to solve the problem that the deep learning model in the medical field is unknowable in the process of diagnosing electrocardiograms, and realizes the quantitative analysis of the effect of the deep learning model on the learning of specific areas of the electrocardiogram. BRIEF DESCRIPTION OF THE DRAWINGS
[0043] Other features, objects and advantages of the present invention will become more apparent upon reading the detailed description of non-limiting embodiments with reference to the following drawings:
[0044] Figure 1This is a schematic diagram of the central electrical signal analysis and processing method of the present invention;
[0045] Figure 2 Schematic diagram of the training process of the atrial fibrillation diagnosis model of the present invention;
[0046] Figure 3 This is a schematic diagram of occlusion analysis of atrial fibrillation data in the present invention;
[0047] Figure 4 Schematic diagram of the process of constructing the atrial fibrillation wave characteristic model and the interval irregularity model in the present invention;
[0048] Figure 5 This is a schematic diagram of the explanatory report template and rule generation in the present invention. DETAILED DESCRIPTION
[0049] The present invention will be described in detail below with reference to specific embodiments. The following embodiments will help those skilled in the art to further understand the present invention, but are not intended to limit the present invention in any form. It should be noted that, without departing from the scope of the present invention, a number of variations and improvements may be made by those skilled in the art. These all fall within the scope of protection of the present invention.
[0050] The present invention discloses an electrocardiogram (ECG) signal diagnosis system that can automatically identify atrial fibrillation and simultaneously provide an interpretation report of the results. An occlusion analysis method for atrial fibrillation ECG is proposed, which can be used to analyze the diagnostic results of an atrial fibrillation automatic diagnosis system. Based on the occlusion method, a post-classification interpreter for deep learning model classification results is constructed. The interpreter can generate an interpretation report that describes the signal characteristics from the perspective of the deep learning model (such as Figure 1 shown).
[0051] Step S1: The server receives the ECG data to be analyzed sent by the client;
[0052] Step S2: preprocessing the ECG data to be analyzed to obtain preprocessed ECG data to be analyzed;
[0053] Step S3: The server uses the trained deep learning model to perform atrial fibrillation recognition processing on the pre-processed ECG data to be analyzed, and obtains the recognition results and semantic features in the deep learning model reasoning process;
[0054] Among them, semantic features are the features of the input signal in the middle layer of deep learning. In the present application, semantic features specifically refer to the features before the classification layer. In the deep learning model, as the number of network layers increases, the extracted feature semantic information becomes more abstract, especially the semantic features of the last layer are very comprehensive and abstract. The electrocardiogram occlusion analysis method adopted by the present invention analyzes the changes in semantic features by occluding the abnormal features of the input electrocardiogram, and then obtains which features model these abnormalities more.
[0055] The step S3 comprises the following steps:
[0056] Step S3.1: constructing an atrial fibrillation diagnostic model, including a one-dimensional residual convolution feature extraction module and a classification module;
[0057] Step S3.2: Determine the type of heart disease based on the ECG data, label the arrhythmia type in the entire segment to obtain a diagnostic label, and construct an ECG database;
[0058] In this embodiment, the ECG types are normal sinus rhythm ECG and atrial fibrillation ECG. The ECG database contains two types of information: a 10-second signal and a label, i.e., a one-dimensional ECG signal with a length of 5000 (sampling frequency of 500 Hz), and a label of 0 or 1, where 1 indicates atrial fibrillation and 0 indicates normal.
[0059] Step S3.3: Preprocessing the constructed ECG database, including data standardization and filtering operations, to obtain a preprocessed ECG database;
[0060] Step S3.4: Use the ECG database to train the atrial fibrillation diagnosis model to obtain the trained atrial fibrillation diagnosis model (such as Figure 2 shown).
[0061] Step S4: The server uses the explanatory analysis model to analyze the recognition results and semantic features, obtains the extraction results of the deep learning model for the fibrillation waves and irregular interval features of atrial fibrillation, and generates an explanation report.
[0062] The step S4 comprises the following steps:
[0063] Step S4.1: constructing an atrial fibrillation wave characteristic model and an interval irregularity model, including two Gaussian distribution models;
[0064] Step S4.2: performing a quality assessment on the atrial fibrillation signals in the ECG database preprocessed in step S3 to obtain an atrial fibrillation database for constructing an interpretation model;
[0065] Quality assessment is mainly divided into three steps:
[0066] 1. Amplitude assessment: if the ECG signal amplitude exceeds the range of [-3mv, 3mv], it is judged to be of low quality and excluded;
[0067] 2. Volatility assessment: calculate the mean and standard deviation of the entire signal, and use the 5σ principle to determine if the signal exceeds the range and exclude it.
[0068] 3. Feature point positioning: Use the Hamilton segmentation algorithm to locate the ECG P, Q, R, S, and T feature points. If the algorithm is wrong, the signal will be excluded.
[0069] Step S4.3: Perform occlusion analysis on each data in the constructed atrial fibrillation database, including data feature point search and feature waveform transformation operations, to obtain two data that respectively occlude specific ECG features (such as Figure 3 shown);
[0070] exist Figure 3 In the process, the Hamilton segmentation algorithm is first used to locate the ECG reference points to obtain the feature point set of all heart beats {P s ,P,Q s ,Q,R,S,T,T e}, where P s , P is automatically obtained by the algorithm, representing the P wave starting point and P wave position respectively, which are not used in atrial fibrillation occlusion analysis (P wave does not exist in theory), and Q s With T e Represent the starting point of the Q wave and the ending point of the T wave of all heart beats respectively. s With T e The entire signal can be divided into a set of N heartbeats HB and a baseline set BL, where
[0071] Interval feature mask operation: First, use R to calculate the average RR interval And calculate the distance moved for each heartbeat Beat HB with your heart i Move forward or backward D i make The baseline between two heart beats is obtained from BL, and then the ECG signal with mask interval characteristics is obtained.
[0072] Flutter mask operation: mainly involves f wave elimination and P wave filling. First, based on and Two-point linear interpolation to replace BL i To eliminate the f wave, then for the disappeared P wave, use the P wave of the normal ECG signal as the standard P wave and add it to the new BL i Finally, the heartbeat set HB and the new baseline set BL are combined into a new ECG signal to obtain the masked fibrillation wave ECG signal.
[0073] Step S4.4: Analyze the original atrial fibrillation data and the masked data using the atrial fibrillation diagnosis model trained in step S3 to obtain three sets of diagnosis results and intermediate features;
[0074] The intermediate features here refer to semantic features, deep learning features before the classification layer, which can be obtained by outputting from the computational graph during model inference.
[0075] Step S4.5: Use the intermediate features and the diagnosis results to extract the sensitive channels of the fibrillation wave characteristics and the irregular interval sensitive channels, and solve the mean and variance of the channel activation factors (such as Figure 4 shown).
[0076] Step S4.6: Use the cumulative probability distribution function of the tremor wave characteristic model and the interval irregularity model to divide the interval and describe the characteristic morphology, and obtain the interpretation report template and construction rules (such as Figure 5 shown).
[0077] Step S5: The server transmits the recognition result and the explanation report to the terminal device.
[0078] The present invention also provides an electrocardiogram signal analysis and processing system, comprising:
[0079] Module M1: Obtaining ECG data to be analyzed;
[0080] Module M2: preprocesses the ECG data to be analyzed to obtain the preprocessed ECG data to be analyzed;
[0081] Module M3: Using the deep learning model to perform recognition processing on the ECG data to be analyzed, obtaining a first recognition result and semantic features generated by the deep learning model during the reasoning process;
[0082] Module M4: Use the explanatory analysis model to analyze the first recognition results and semantic features, obtain the extraction results of the deep learning model for the fibrillation waves and irregular interval features of atrial fibrillation in the ECG data, and generate an explanation report.
[0083] The present invention also provides a computer-readable storage medium storing a computer program, which implements the steps of the above-mentioned electrocardiogram signal analysis and processing method when executed by a processor.
[0084] The present invention also provides an ECG signal analysis and processing device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor. When the computer program is executed by the processor, the steps of the above-mentioned ECG signal analysis and processing method are implemented.
[0085] The above describes specific embodiments of the present invention. It should be understood that the present invention is not limited to the specific embodiments described above, and those skilled in the art may make various changes or modifications within the scope of the claims, which do not affect the essence of the present invention. The embodiments of this application and the features in the embodiments may be combined with each other in any manner unless there is a conflict.
Claims
1. A method for analyzing and processing an electrocardiogram signal, characterized in that: include: Step S1: Obtaining the ECG data to be analyzed; Step S2: preprocessing the ECG data to be analyzed to obtain preprocessed ECG data to be analyzed; Step S3: using the deep learning model to perform recognition processing on the ECG data to be analyzed, obtaining a first recognition result and semantic features generated by the deep learning model during the reasoning process; Step S4: Analyze the first recognition result and semantic features using the explanatory analysis model, obtain the extraction results of the fibrillation waves and irregular interval features of atrial fibrillation in the electrocardiogram data using the deep learning model, and generate an explanation report.
2. The electrocardiogram signal analysis and processing method according to claim 1, wherein: The construction of the deep learning model includes: Step S3.1: constructing an atrial fibrillation diagnostic model, including a one-dimensional residual convolution feature extraction module and a classification module; Step S3.2: Constructing atrial fibrillation diagnosis model training samples, labeling abnormal segments in the ECG data with disease types, and obtaining an ECG database; Step S3.3: Preprocessing the ECG database, including data standardization and filtering operations, to obtain a preprocessed ECG database; Step S3.4: Using the ECG database to train the atrial fibrillation diagnosis model to obtain a trained atrial fibrillation diagnosis model.
3. The electrocardiogram signal analysis and processing method according to claim 2, characterized in that: The ECG data includes a normal sinus rhythm ECG and an atrial fibrillation ECG; the ECG database contains two types of information: a 10-second one-dimensional ECG signal and a label, where the label is 0 or 1, where 1 indicates atrial fibrillation and 0 indicates normal.
4. The electrocardiogram signal analysis and processing method according to claim 1, wherein: The step S4 comprises: Step S4.1: constructing an atrial fibrillation wave characteristic model and an interval irregularity model; Step S4.2: performing a quality assessment on the atrial fibrillation signals in the ECG database in step S3 to obtain an atrial fibrillation database for constructing an interpretation model; Step S4.3: Perform occlusion analysis on each piece of data in the constructed atrial fibrillation database, including data feature point search and feature waveform transformation operations, to obtain two pieces of data that occlude specific ECG features; Step S4.4: Analyze the original atrial fibrillation data and the masked data using the atrial fibrillation diagnosis model to obtain three sets of diagnosis results and intermediate features; Step S4.5: Using the intermediate features and the diagnosis results, extract the fibrillation wave feature sensitive channels and the interval irregularity sensitive channels, and calculate the mean and variance of the channel activation factors; Step S4.6: Use the cumulative probability distribution function of the tremor wave characteristic model and the interval irregularity model to divide the interval and describe the characteristic morphology, and obtain the interpretation report template and construction rules.
5. The electrocardiogram signal analysis and processing method according to claim 4, characterized in that: The quality assessment in step S4.2 includes: Amplitude assessment: If the ECG signal amplitude exceeds the range of [-3mv, 3mv], it is judged as low quality and excluded; Volatility assessment: Calculate the mean and standard deviation of the entire signal, and use the 5σ principle to determine if the signal exceeds the range and exclude it; Feature point positioning evaluation: Use the Hamilton segmentation algorithm to locate the ECG P, Q, R, S, and T feature points. If the algorithm is wrong, the signal will be excluded.
6. The electrocardiogram signal analysis and processing method according to claim 4, characterized in that: The step S4.3 includes: Step S4.3.1: Use Hamilton segmentation algorithm to locate ECG reference points and obtain the feature point set of all heart beats {P s ,P,Q s ,Q,R,S,T,T e }, where P s , P are automatically obtained by the algorithm, representing the P wave starting point and P wave position respectively, which are not used in atrial fibrillation occlusion analysis, and Q s With T e Represent the starting point of Q wave and the ending point of T wave of all heart beats respectively; s With T e The entire signal is divided into a set of N heartbeats HB and a baseline set BL, where Step S4.3.2: Interval feature mask operation: First, use R to calculate the average RR interval And calculate the movement distance of each heartbeat Beat HB with your heart i Move forward or backward D i make The baseline between two heart beats is obtained from BL, and then the ECG signal with mask interval characteristics is obtained; Step S4.3.3: Flutter mask operation: used for f-wave elimination and P-wave filling, based on and Two-point linear interpolation to replace BL i To eliminate the f wave, for the disappeared P wave, use the P wave of the normal ECG signal as the standard P wave and add it to the new BL i Finally, the heartbeat set HB and the new baseline set BL are combined into a new ECG signal to obtain the masked fibrillation wave ECG signal.
7. The electrocardiogram signal analysis and processing method according to claim 4, characterized in that: The intermediate features are semantic features, deep learning features before the classification layer, and are output from the computational graph during model inference.
8. An electrocardiogram signal analysis and processing system, characterized in that: include: Module M1: Obtaining ECG data to be analyzed; Module M2: preprocesses the ECG data to be analyzed to obtain the preprocessed ECG data to be analyzed; Module M3: Using the deep learning model to perform recognition processing on the ECG data to be analyzed, obtaining a first recognition result and semantic features generated by the deep learning model during the reasoning process; Module M4: Use the explanatory analysis model to analyze the first recognition results and semantic features, obtain the extraction results of the deep learning model for the fibrillation waves and irregular interval features of atrial fibrillation in the ECG data, and generate an explanation report.
9. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the steps of the electrocardiographic signal analysis and processing method according to any one of claims 1 to 7 are implemented.
10. An electrocardiogram signal analysis and processing device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the computer program is executed by a processor, the steps of the electrocardiographic signal analysis and processing method according to any one of claims 1 to 7 are implemented.
Citation Information
Patent Citations
Thoracic cavity image pathology prediction method based on group decoupling representation
CN118154501A