A method and system for identifying artifacts of dynamic electrocardiogram signals

By using support vector machines to extract features from dynamic electrocardiogram signals and train models, the problem of low accuracy in artifact identification in existing technologies has been solved, achieving higher identification accuracy and stability, and improving the reliability of clinical diagnosis.

CN115778402BActive Publication Date: 2024-08-30SHENZHEN ECGMAC MEDICAL ELECTRONICS
View PDF 14 Cites 0 Cited by

Patent Information

Application Number
CN202211540499.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-12-02
Publication Date
2024-08-30
Estimated Expiration
2042-12-02

AI Technical Summary

Technical Problem

In existing technologies, the methods for identifying artifacts in dynamic electrocardiograms mainly rely on the characteristics of the data to be analyzed, resulting in low accuracy and poor stability, which affects the clinical diagnostic effect.

Method used

Support vector machines are used to preprocess and extract features from labeled electrocardiogram (ECG) data to generate an artifact recognition model. By deeply mining the feature values ​​of ECG signals, such as wavelet coefficients, interval ratios, matching degrees, and noise interference information, the accuracy and robustness of artifact recognition are improved.

Benefits of technology

It improves the accuracy and stability of dynamic electrocardiogram signal artifact identification, reduces the misjudgment of clinical diagnosis by artifacts, and enhances the reliability of diagnosis.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115778402B
    Figure CN115778402B
Patent Text Reader

Abstract

The present invention discloses a method and system for identifying artifacts of dynamic electrocardiogram signals. The method comprises: obtaining labeled dynamic electrocardiogram data, wherein the labeled dynamic electrocardiogram data comprises heartbeat data, performing a first preprocessing operation on the labeled heartbeat data, extracting characteristic values ​​for each heartbeat after preprocessing and normalizing them, and obtaining a sample characteristic vector; inputting the sample characteristic vector into a pre-constructed support vector machine for training, and generating an artifact identification model; performing a second preprocessing operation on the collected dynamic electrocardiogram data, extracting characteristic values ​​for each heartbeat after preprocessing and normalizing them, and obtaining a heartbeat characteristic vector; inputting the heartbeat characteristic vector into the artifact identification model, and using the output result as the artifact identification result. The embodiment of the present invention extracts the features of the data to be analyzed by deep mining, and uses the support vector machine for training to obtain the identification model, which is used for the artifact identification of dynamic electrocardiogram signals, and improves the accuracy of identification and the robustness of the algorithm.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of data processing, and in particular to a method and system for identifying artifacts of dynamic electrocardiogram signals. Background Art

[0002] A dynamic electrocardiogram (Hypercardiogram) is a procedure in which a patient's entire cardiac activity is recorded continuously for 24 hours or longer in their daily life using a dynamic electrocardiograph. The electrocardiogram information obtained by the recorder is input into a computer for processing, and a dynamic electrocardiogram report is printed out after manual editing, providing a basis for clinical diagnosis and treatment of diseases.

[0003] Holter recordings are collected during patients' daily lives, and are therefore inevitably subject to varying degrees of interference during the recording process, including baseline drift, power frequency interference, and myoelectric interference. While some interference can be removed through the design of filters, interference introduced by factors such as exercise cannot be completely eliminated due to its similarity to the actual heartbeat. These interference artifacts, known as "artifacts," can be misinterpreted as premature ventricular or atrial beats during automated analysis, thus affecting the doctor's analysis and diagnosis.

[0004] Among the existing related technologies, template matching clustering, high-order statistics, wavelet analysis and independent component analysis are mainly used to identify artifacts. However, these methods mainly utilize the characteristics of the data to be analyzed, resulting in low recognition accuracy and poor stability, and the effect is not ideal in actual clinical applications.

[0005] Therefore existing technology also needs further development. Summary of the Invention

[0006] In response to the above technical problems, an embodiment of the present invention provides a method and system for identifying artifacts of dynamic electrocardiogram signals, which can solve the technical problems that the existing technology mainly uses methods such as template matching clustering, high-order statistics, wavelet analysis and independent component analysis to identify artifacts, but these methods mainly use the characteristics of the data to be analyzed itself, resulting in low recognition accuracy and poor stability.

[0007] A first aspect of an embodiment of the present invention provides a method for identifying artifacts of a dynamic electrocardiogram signal, comprising:

[0008] Acquire labeled dynamic electrocardiogram data, wherein the labeled dynamic electrocardiogram data includes heartbeat data, and the heartbeat data type includes real heartbeats and artifacts;

[0009] Performing a first preprocessing operation on the marked heartbeat data, extracting a feature value for each heartbeat after the preprocessing and performing normalization processing to obtain a sample feature vector;

[0010] Inputting the sample feature vector into a pre-constructed support vector machine for training to generate an artifact recognition model;

[0011] Acquire the collected dynamic electrocardiogram data, perform a second preprocessing operation on the collected dynamic electrocardiogram data, extract characteristic values ​​for each heartbeat after the preprocessing and perform normalization processing to obtain a heartbeat characteristic vector;

[0012] The heartbeat feature vector is input into an artifact recognition model, an output result of the artifact recognition model is obtained, and the output result is used as an artifact recognition result.

[0013] Optionally, performing a first preprocessing operation on the marked heartbeat data includes:

[0014] The real heartbeats and artifacts in the marked heartbeat data are template matched in sequence according to their positions. After all the marked data are matched, the number of heartbeats in each template is counted.

[0015] Optionally, extract characteristic values ​​from each heartbeat after preprocessing and perform normalization processing to obtain a sample characteristic vector, including:

[0016] Extract characteristic values ​​for each heartbeat after preprocessing, including the wavelet coefficient of the heartbeat, the total number of heartbeats in the template, the interval ratio of the three intervals before and after the current heartbeat, the matching degree between the current heartbeat and the previous and next heartbeats, heartbeat differential data information, and low-frequency and high-frequency noise interference information;

[0017] The extracted eigenvalues ​​are normalized to obtain the sample eigenvector.

[0018] Optionally, the acquiring the collected dynamic electrocardiogram data and performing a second preprocessing operation on the collected dynamic electrocardiogram data include:

[0019] Acquire the collected dynamic electrocardiogram data, filter the collected dynamic electrocardiogram data, and generate filtered data;

[0020] Perform heartbeat detection on the filtered data based on the differential threshold algorithm and record the position information of each heartbeat;

[0021] Perform cluster statistics on each heartbeat and count the number of heartbeats in each template.

[0022] Optionally, the step of performing template matching on the real heartbeats and artifacts in the marked heartbeat data in sequence according to their positions includes:

[0023] Calculate the similarity between the marked heartbeat data and the existing templates in sequence according to their positions;

[0024] If the similarity is greater than or equal to the threshold, it is determined that the heartbeat data belongs to the template, and the data in the template is updated;

[0025] If the similarity is less than the threshold, the matching calculation is performed with the next template;

[0026] If the marked heartbeat data does not match any template, a corresponding template is created based on the heartbeat data.

[0027] A second aspect of an embodiment of the present invention provides a system for identifying artifacts of a dynamic electrocardiogram (DECT) signal. The system includes 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 following steps are implemented:

[0028] Acquire labeled dynamic electrocardiogram data, wherein the labeled dynamic electrocardiogram data includes heartbeat data, and the heartbeat data type includes real heartbeats and artifacts;

[0029] Performing a first preprocessing operation on the marked heartbeat data, extracting a feature value for each heartbeat after the preprocessing and performing normalization processing to obtain a sample feature vector;

[0030] Inputting the sample feature vector into a pre-constructed support vector machine for training to generate an artifact recognition model;

[0031] Acquire the collected dynamic electrocardiogram data, perform a second preprocessing operation on the collected dynamic electrocardiogram data, extract characteristic values ​​for each heartbeat after the preprocessing and perform normalization processing to obtain a heartbeat characteristic vector;

[0032] The heartbeat feature vector is input into an artifact recognition model, an output result of the artifact recognition model is obtained, and the output result is used as an artifact recognition result.

[0033] Optionally, when the computer program is executed by the processor, the following steps are implemented:

[0034] The real heartbeats and artifacts in the marked heartbeat data are template matched in sequence according to their positions. After all the marked data are matched, the number of heartbeats in each template is counted.

[0035] Optionally, when the computer program is executed by the processor, the following steps are further implemented:

[0036] Extract characteristic values ​​for each heartbeat after preprocessing, including the wavelet coefficient of the heartbeat, the total number of heartbeats in the template, the interval ratio of the three intervals before and after the current heartbeat, the matching degree between the current heartbeat and the previous and next heartbeats, heartbeat differential data information, and low-frequency and high-frequency noise interference information;

[0037] The extracted eigenvalues ​​are normalized to obtain the sample eigenvector.

[0038] Optionally, when the computer program is executed by the processor, the following steps are further implemented:

[0039] Acquire the collected dynamic electrocardiogram data, filter the collected dynamic electrocardiogram data, and generate filtered data;

[0040] Perform heartbeat detection on the filtered data based on the differential threshold algorithm and record the position information of each heartbeat;

[0041] Perform cluster statistics on each heartbeat and count the number of heartbeats in each template.

[0042] A third aspect of an embodiment of the present invention provides a non-volatile computer-readable storage medium, characterized in that the non-volatile computer-readable storage medium stores computer-executable instructions, which, when executed by one or more processors, enable the one or more processors to execute the above-mentioned method for identifying artifacts of dynamic electrocardiogram signals.

[0043] In the technical solution provided by the embodiment of the present invention, labeled dynamic electrocardiogram data is obtained, and the labeled dynamic electrocardiogram data includes heartbeat data. A first preprocessing operation is performed on the labeled heartbeat data, and characteristic values ​​are extracted and normalized for each heartbeat after preprocessing to obtain a sample characteristic vector; the sample characteristic vector is input into a pre-constructed support vector machine for training to generate an artifact recognition model; a second preprocessing operation is performed on the collected dynamic electrocardiogram data, and characteristic values ​​are extracted and normalized for each heartbeat after preprocessing to obtain a heartbeat characteristic vector; the heartbeat characteristic vector is input into the artifact recognition model, and the output result is used as the artifact recognition result. The embodiment of the present invention deeply mines and extracts the features of the data to be analyzed, and uses a support vector machine for training to obtain a recognition model for artifact recognition of dynamic electrocardiogram signals, thereby improving the recognition accuracy and the robustness of the algorithm. BRIEF DESCRIPTION OF THE DRAWINGS

[0044] Figure 1 1 is a flow chart of an embodiment of a method for identifying artifacts of a dynamic electrocardiogram signal according to an embodiment of the present invention;

[0045] Figure 2 A schematic diagram of real heart beats and artifacts in one embodiment of a method for identifying artifacts of a dynamic electrocardiogram signal according to an embodiment of the present invention;

[0046] Figure 3a This is a schematic diagram of intervals in an embodiment of a method for identifying artifacts of a dynamic electrocardiogram signal according to an embodiment of the present invention;

[0047] Figure 3b In the embodiment of the present invention Figure 3a Schematic diagram of the calculation corresponding to the interval;

[0048] Figure 4aA schematic diagram of an electrocardiogram waveform according to an embodiment of a method for identifying artifacts of a dynamic electrocardiogram signal according to an embodiment of the present invention;

[0049] Figure 4b Schematic diagram of differential signals according to an embodiment of a method for identifying artifacts of a dynamic electrocardiogram signal in an embodiment of the present invention;

[0050] Figure 5 A schematic diagram of a high-frequency noise calculation range of an embodiment of a method for identifying artifacts of a dynamic electrocardiogram signal according to an embodiment of the present invention;

[0051] Figure 6 This is a flow chart of identification preprocessing of an embodiment of a method for identifying artifacts of a dynamic electrocardiogram signal according to an embodiment of the present invention;

[0052] Figure 7 This is a QRS wave detection flow chart of an embodiment of a method for identifying artifacts of a dynamic electrocardiogram signal in an embodiment of the present invention;

[0053] Figure 8 FIG. 1 is a schematic diagram of the hardware structure of another embodiment of a system for identifying artifacts of a dynamic electrocardiogram signal according to an embodiment of the present invention. DETAILED DESCRIPTION

[0054] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without making any creative efforts shall fall within the scope of protection of the present invention.

[0055] The embodiments of the present invention are described in detail below with reference to the accompanying drawings.

[0056] See also Figure 1 , Figure 1 FIG. 1 is a flow chart of an embodiment of a method for identifying artifacts of a dynamic electrocardiogram signal according to an embodiment of the present invention. Figure 1 Shown, including:

[0057] Step S100: Acquire labeled Holter ECG data, wherein the labeled Holter ECG data includes heartbeat data, and the heartbeat data type includes real heartbeats and artifacts;

[0058] Step S200: performing a first preprocessing operation on the marked heartbeat data, extracting a feature value from each heartbeat after the preprocessing and performing normalization processing to obtain a sample feature vector;

[0059] Step S300: inputting the sample feature vector into a pre-constructed support vector machine for training to generate an artifact recognition model;

[0060] Step S400: Acquire collected Holter ECG data, perform a second preprocessing operation on the collected Holter ECG data, extract characteristic values ​​from each heartbeat after the preprocessing, and perform normalization processing to obtain a heartbeat characteristic vector;

[0061] Step S500: input the heartbeat feature vector into an artifact recognition model, obtain an output result of the artifact recognition model, and use the output result as an artifact recognition result.

[0062] In specific implementation, the technical solution of the present invention is used to obtain a training module for a recognition model and an identification module for dynamic electrocardiogram signal artifact recognition. The training module uses the labeled electrocardiogram data to extract eigenvalues ​​after preprocessing, and multiple eigenvalues ​​are used as input to perform model training using a support vector machine, and finally obtain an artifact recognition model. In the recognition module, the collected dynamic electrocardiogram data is preprocessed, and feature extraction is performed using a method consistent with the training module. Finally, the model obtained by the training module is used to perform artifact recognition, and the artifact recognition result is output.

[0063] Mark the real heart beats and artifacts in the Holter data; professional ECG doctors use software to mark the real heart beats (including normal heart beats, ventricular heart beats and atrial heart beats, etc.) and artifacts in the Holter data, and use the results as training samples, such as Figure 2 As shown, the true heart beats are marked as N (sinus beat) and V (ventricular premature beat), and the artifacts are marked as X (noise interference).

[0064] The real heartbeat is the name relative to the artifact. The real heartbeat includes normal heartbeat, ventricular heartbeat and atrial heartbeat. Among them, the normal heartbeat includes sinus beat, left bundle branch and right bundle branch; atrial heartbeat includes atrial premature beat, atrial escape beat, etc.; ventricular heartbeat includes ventricular premature beat, ventricular escape beat, etc. The N (sinus beat) and V (ventricular premature beat) described above are for Figure 2 Detailed description.

[0065] Perform cluster statistics on the marked true heart beats and artifacts, perform template matching on the true heart beats and artifacts of the Holter ECG data in sequence by position, and count the number of heart beats in each template after all data matching is completed;

[0066] Perform feature extraction on each heartbeat to generate training samples. The extracted feature values ​​include the wavelet coefficient of the heartbeat, the total number of heartbeats in the template, the interval ratio of the three intervals before and after the current heartbeat, the matching degree between the current heartbeat and the previous and next heartbeats, the information of the heartbeat difference data, and the low-frequency and high-frequency noise interference information.

[0067] The extracted features are normalized to obtain feature vectors. After feature extraction is completed, support vector machines are used as classifiers to train the obtained features, with the normalized feature vectors as input and radial basis function kernels as kernel functions to obtain an artifact recognition model for subsequent artifact recognition.

[0068] Filter the collected dynamic ECG data, use the differential threshold method to detect the heartbeat of the filtered data, record the position information of each heartbeat, perform clustering statistics on each heartbeat, and count the number of heartbeats in each template;

[0069] After preprocessing, feature extraction is performed on each heartbeat (real heartbeat and artifacts). The extracted features and methods are consistent with those in the training module, and the extracted feature values ​​are also normalized.

[0070] The normalized feature values ​​are input into the recognition model obtained by the training module to obtain the final recognition result (real heart beat or artifact), and the result is output to the user.

[0071] Furthermore, a first preprocessing operation is performed on the marked heartbeat data, including:

[0072] The real heartbeats and artifacts in the marked heartbeat data are template matched in sequence according to their positions. After all the marked data are matched, the number of heartbeats in each template is counted.

[0073] In practice, since the true heartbeats and artifacts in the ECG data are already labeled, training preprocessing primarily involves clustering and counting the true heartbeats and artifacts. This method involves performing template matching on the true heartbeats and artifacts in the Holter ECG data, sequentially by location. After all data are matched, the number of beats (true heartbeats and artifacts) in each template is counted.

[0074] Furthermore, the real heartbeats and artifacts in the marked heartbeat data are template matched in sequence according to their positions, including:

[0075] Calculate the similarity between the marked heartbeat data and the existing templates in sequence according to their positions;

[0076] If the similarity is greater than or equal to the threshold, it is determined that the heartbeat data belongs to the template, and the data in the template is updated;

[0077] If the similarity is less than the threshold, the matching calculation is performed with the next template;

[0078] If the marked heartbeat data does not match any template, a corresponding template is created based on the heartbeat data.

[0079] In specific implementation, a real heartbeat or pseudo-error data is input and the similarity is calculated with the existing templates in turn. If the result is greater than or equal to the threshold, the data is considered to belong to the template and the data in the template is updated. Otherwise, the matching calculation continues with the next template; if the data does not match all templates, a new template is created based on the data.

[0080] Furthermore, feature values ​​are extracted for each heartbeat after preprocessing, and the feature values ​​include the wavelet coefficient of the heartbeat, the total number of heartbeats in the template, the interval ratio of the three intervals before and after the current heartbeat, the matching degree between the current heartbeat and the previous and next heartbeats, heartbeat differential data information, and low-frequency and high-frequency noise interference information;

[0081] The extracted eigenvalues ​​are normalized to obtain the sample eigenvector.

[0082] In specific implementation, after preprocessing, feature extraction is performed on each heartbeat (real heartbeat and artifact), mainly extracting the following feature values:

[0083] 1) Wavelet coefficients of heartbeat

[0084] The data of 1 second, 400ms before and 600ms after the heartbeat position, were selected for 5-order wavelet decomposition, and the obtained wavelet coefficients were used as eigenvalues.

[0085] The wavelet transform is a signal analysis method that can perform analysis in both the time and frequency domains, featuring time-frequency localization and multiresolution. This multiresolution analysis feature of the wavelet transform is utilized here to perform multiresolution decomposition of the signal at different scales. The basic theory of the wavelet transform is quite complex, involving numerous difficult mathematical concepts and operations. However, from an application perspective, wavelet transformations can be viewed as a cascade of low-pass and high-pass filters, followed by a downsampling operation. The wavelet transform is the signal obtained after a series of filtering and downsampling operations, which are also called wavelet coefficients. In this example, wavelet decomposition is performed using the db6 mother wavelet Daubechies basis. After wavelet decomposition at five scales, the resulting signal (wavelet coefficients) is used as the eigenvalue.

[0086] 2) The total number of heartbeats in the template

[0087] The total number of heartbeats under the template of each heartbeat is taken as the feature value;

[0088] 3) The ratio of the three intervals before and after the current heartbeat

[0089] like Figure 3a and Figure 3bAs shown, R3 is the current heartbeat, R0 to R2 are the first three heartbeats, R4 to R6 are the last three heartbeats, and RR1 is the interval between R0 and R1. Its value is the position of R1 minus the position of R0. The algorithm for other RR intervals is similar. By calculating the ratio between two adjacent intervals among the six intervals, the five interval ratios are obtained as feature values.

[0090] 4) The matching degree between the current heartbeat and the previous and next heartbeats

[0091] The similarity calculation method is used to calculate the similarity between the current heartbeat and the previous heartbeat and the next heartbeat respectively, and the two calculated results are used as feature values;

[0092] 5) Heartbeat difference data information

[0093] like Figure 4a and Figure 4b As shown, the ECG signal is differentially calculated to obtain differential data. The maximum differential position (point P1 in the figure) and the minimum differential position (point P0 in the figure) are found on the differential data, and three values ​​are calculated as characteristic values: the time interval between P0 and P1, and the amplitudes of points P0 and P1;

[0094] In this example, a backward difference operation is used, using the following formula: D(n) is the difference result at the current point, X(n) is the signal value at the current point, and X(n-10ms) is the signal value 10ms ago.

[0095] D(n)=X(n)–X(n-10ms)

[0096] 6) Low-frequency and high-frequency noise interfere with information

[0097] The data of 400ms before and 600ms after the heartbeat position, a total of 1 second, is selected for median filtering to extract low-frequency interference information. Specifically, the maximum and minimum values ​​of the signal are found in the filtered signal obtained after median filtering, and the result of subtracting the minimum value from the maximum value is used as the interference value of the low-frequency noise. The interference value calculation range of high-frequency noise is as follows: Figure 5 As shown in the figure, using the current heartbeat as the reference position, the noise value of the signal is calculated for a period of 100ms, 150ms before and after the reference position. The calculation method is to perform a second-order difference on the signal within this 100ms period, sum the absolute values ​​of the difference results, and use the final sum as the noise value. The interference value of high-frequency noise is the maximum of the two noise values ​​before and after the reference position. The low-frequency and high-frequency noise interference values ​​are used as the characteristic values.

[0098] The time in this example is the length of time required to obtain relatively ideal results based on the current experiment. Other time lengths can also be selected, but generally speaking, it should not be too short or too long.

[0099] In this example, a second-order backward difference is used, as shown in the following formula: D2(n) is the second-order difference result at the current point, X(n) is the signal value at the current point, and X(n-5ms) and X(n-10ms) are the signal values ​​5ms and 10ms ago, respectively.

[0100] D2(n)=X(n)–2*X(n-5ms)+X(n-10ms)

[0101] Normalize the above eigenvalues, mapping them all to the range [0, 1] to obtain the final eigenvector. Normalization can effectively improve the algorithm's convergence speed. The method involves traversing all eigenvalues ​​for the current heartbeat, finding the maximum eigenvalue FMax and the minimum eigenvalue FMin. Each eigenvalue is then transformed using the following formula, where FIn and FOut are the input eigenvalue and the transformed eigenvalue, respectively.

[0102] FOut=(FIn-FMin) / (FMax-FMin).

[0103] Furthermore, the collected dynamic electrocardiogram data is obtained, and a second preprocessing operation is performed on the collected dynamic electrocardiogram data, including:

[0104] Acquire the collected dynamic electrocardiogram data, filter the collected dynamic electrocardiogram data, and generate filtered data;

[0105] Perform heartbeat detection on the filtered data based on the differential threshold algorithm and record the position information of each heartbeat;

[0106] Perform cluster statistics on each heartbeat and count the number of heartbeats in each template.

[0107] When implementing it specifically, Figure 6 As shown in the figure, the collected ECG data is first filtered to remove interference from noise such as baseline drift, power frequency interference, and myoelectric interference. Next, a differential threshold method is used to detect heartbeats on the filtered data, recording the location of each heartbeat (true heartbeat and artifacts). Finally, cluster statistics are performed using the same method as the training preprocessing method to count the number of heartbeats (true heartbeat and artifacts) in each template.

[0108] Different filtering methods are used to filter out baseline drift, power frequency interference and myoelectric interference.

[0109] Baseline drift. Baseline drift is generally caused by the subject's breathing, electrode drift, etc. during the ECG measurement process. It is characterized by a low frequency (generally below 0.7Hz), a gentle change but a large amplitude. In this example, median filtering is used to filter out baseline drift interference. A window with a length of 800ms is used to calculate the median of the signal within the window, and the median signal is subtracted from the original signal as the final filtering result. Specifically, each sampling point in the ECG signal is processed as follows: the median of the signal within the 800ms window, 400ms before and 400ms after the current point, is calculated, and the value of the current point minus the median is used as the result of the median filtering of the current point.

[0110] Power frequency interference. Power frequency interference is primarily caused by the electromagnetic field generated by the AC power supply and the loop circuit between the ECG acquisition device and the human body. It has a frequency of 50Hz or 60Hz. Power frequency interference primarily consists of sinusoidal signals and appears as regularly distributed ripples on the ECG. In this example, a notch filter is used to eliminate power frequency interference noise. The filtering formula is as follows: where Y(n) is the filtering result, Y(n-20ms) is the filtering result for the previous 20ms, X(n) is the signal value at the current point, and X(n-20ms) is the signal value 20ms ago.

[0111] Y(n)=0.86*Y(n-20ms)+0.93*(X(n)–X(n-20ms))

[0112] Myoelectric interference. Myoelectric interference is caused by factors such as thyroid diseases, muscle contraction, and stress and cold. Its frequency ranges from 5 to 2000 Hz. Compared to ECG signals, myoelectric interference is a high-frequency interference signal. In this example, a low-pass filter is used to eliminate myoelectric interference noise. The filtering formula is as follows: where Y(n) is the filtering result, Y(n-1) and Y(n-2) are the filtering results of the previous two points, X(n) is the signal value at the current point, and X(n-10ms) and X(n-20ms) are the signal values ​​10ms and 20ms ago, respectively.

[0113] Y(n)=2*Y(n-1)–Y(n-2)+X(n)–2*X(n-10ms)+X(n-20ms)

[0114] Differential threshold method. Figure 7As shown, the differential threshold method is used to detect QRS waves (that is, heartbeats). Specifically, after filtering the ECG data, differential, square and moving average processing is performed in sequence, and then the peak value is found. After obtaining the peak value, the peak value is compared with the threshold value. If the peak value is greater than the threshold value, it is considered that the QRS wave is detected, otherwise the detected QRS wave is treated as noise. Finally, the threshold value is updated, for example, the updated threshold value is made half of the previous threshold value, and then the differential, square and moving average processing is directed again to the above-mentioned differential, square and moving average processing, and a new peak value is found and re-compared. It should be noted that the QRS wave detection of this embodiment belongs to the prior art. For details, please refer to the relevant description of the processes such as differential, square, moving average processing, peak value search and threshold value comparison in the Chinese invention patent "A real-time heart rate detection method and system for ECG signals" (CN104586384B). Of course, the present invention can also use other methods to detect QRS waves on ECG data, which will not be repeated here.

[0115] The embodiment of the present invention proposes a method for identifying artifacts of dynamic electrocardiogram signals. In the selection of characteristic values, the characteristic parameters include the heartbeat data's own information (wavelet coefficients, differential information), relevant information with other data (number of matched heartbeats, interval ratio, matching degree of previous and next heartbeats), and information interfered with by noise (low-frequency and high-frequency noise interference values). By deeply mining and extracting the features of the data to be analyzed, a recognition model is obtained by training with a support vector machine for identifying artifacts of dynamic electrocardiogram signals. The features used for identifying artifacts include not only the data to be analyzed itself, but also information such as the similarity between the data to be analyzed and the previous and next data, the interval ratio of the data sequence, and the noise of the data to be analyzed, thereby avoiding the influence of factors such as individual differences on the recognition results and improving the accuracy of recognition and the robustness of the algorithm.

[0116] It should be noted that there is not necessarily a certain order between the above steps. A person skilled in the art can understand, based on the description of the embodiments of the present invention, that in different embodiments, the above steps may have different execution orders, that is, they may be executed in parallel, or may be executed interchangeably, etc.

[0117] The above describes the method for identifying artifacts of a dynamic electrocardiogram signal in an embodiment of the present invention. The following describes the system for identifying artifacts of a dynamic electrocardiogram signal in an embodiment of the present invention. Figure 8 , Figure 8 FIG. 1 is a schematic diagram of the hardware structure of another embodiment of a system for identifying artifacts of a dynamic electrocardiogram signal according to an embodiment of the present invention. Figure 8 As shown, the system 10 includes: a memory 101, a processor 102, and a computer program stored in the memory and executable on the processor. When the computer program is executed by the processor 101, the following steps are implemented:

[0118] Acquire labeled dynamic electrocardiogram data, wherein the labeled dynamic electrocardiogram data includes heartbeat data, and the heartbeat data type includes real heartbeats and artifacts;

[0119] Performing a first preprocessing operation on the marked heartbeat data, extracting a feature value for each heartbeat after the preprocessing and performing normalization processing to obtain a sample feature vector;

[0120] Inputting the sample feature vector into a pre-constructed support vector machine for training to generate an artifact recognition model;

[0121] Acquire the collected dynamic electrocardiogram data, perform a second preprocessing operation on the collected dynamic electrocardiogram data, extract characteristic values ​​for each heartbeat after the preprocessing and perform normalization processing to obtain a heartbeat characteristic vector;

[0122] The heartbeat feature vector is input into an artifact recognition model, an output result of the artifact recognition model is obtained, and the output result is used as an artifact recognition result.

[0123] The specific implementation steps are the same as those in the method embodiment and will not be repeated here.

[0124] Optionally, when the computer program is executed by the processor 101, the following steps are further implemented:

[0125] The real heartbeats and artifacts in the marked heartbeat data are template matched in sequence according to their positions. After all the marked data are matched, the number of heartbeats in each template is counted.

[0126] The specific implementation steps are the same as those in the method embodiment and will not be repeated here.

[0127] Optionally, when the computer program is executed by the processor 101, the following steps are further implemented:

[0128] Extract characteristic values ​​for each heartbeat after preprocessing, including the wavelet coefficient of the heartbeat, the total number of heartbeats in the template, the interval ratio of the three intervals before and after the current heartbeat, the matching degree between the current heartbeat and the previous and next heartbeats, heartbeat differential data information, and low-frequency and high-frequency noise interference information;

[0129] The extracted eigenvalues ​​are normalized to obtain the sample eigenvector.

[0130] The specific implementation steps are the same as those in the method embodiment and will not be repeated here.

[0131] Optionally, when the computer program is executed by the processor 101, the following steps are further implemented:

[0132] Acquire the collected dynamic electrocardiogram data, filter the collected dynamic electrocardiogram data, and generate filtered data;

[0133] Perform heartbeat detection on the filtered data based on the differential threshold algorithm and record the position information of each heartbeat;

[0134] Perform cluster statistics on each heartbeat and count the number of heartbeats in each template.

[0135] The specific implementation steps are the same as those in the method embodiment and will not be repeated here.

[0136] Optionally, when the computer program is executed by the processor 101, the following steps are further implemented:

[0137] Calculate the similarity between the marked heartbeat data and the existing templates in sequence according to their positions;

[0138] If the similarity is greater than or equal to the threshold, it is determined that the heartbeat data belongs to the template, and the data in the template is updated;

[0139] If the similarity is less than the threshold, the matching calculation is performed with the next template;

[0140] If the marked heartbeat data does not match any template, a corresponding template is created based on the heartbeat data.

[0141] The specific implementation steps are the same as those in the method embodiment and will not be repeated here.

[0142] An embodiment of the present invention provides a non-volatile computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions, which are executed by one or more processors, for example, to execute the above-described Figure 1 Method steps S100 to S500.

[0143] As an example, the non-volatile storage medium can include a read-only memory (ROM), a programmable ROM (PROM), an electrically programmable ROM (EPROM), an electrically erasable ROM (EEPROM), or a flash memory. Volatile memory can include a random access memory (RAM) as an external cache memory. By way of illustration and not limitation, RAM can be obtained in many forms such as synchronous RAM (SRAM), dynamic RAM, (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), Synchlink DRAM (SLDRAM), and direct Rambus RAM (DRRAM). The disclosed memory components or memories of the operating environment described in the embodiments of the present invention are intended to include one or more of these and / or any other suitable types of memory.

[0144] The above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the various embodiments of the present invention.

Claims

1. A method for identifying artifacts of dynamic electrocardiogram signals, characterized in that: include: Acquire labeled dynamic electrocardiogram data, wherein the labeled dynamic electrocardiogram data includes heartbeat data, and the heartbeat data type includes real heartbeats and artifacts; Performing a first preprocessing operation on the marked heartbeat data, extracting a feature value from each heartbeat after the preprocessing and performing normalization processing to obtain a sample feature vector; Inputting the sample feature vector into a pre-constructed support vector machine for training to generate a pseudo-error recognition model; Acquire the collected dynamic electrocardiogram data, perform a second preprocessing operation on the collected dynamic electrocardiogram data, extract characteristic values ​​from each heartbeat after the preprocessing, and perform normalization processing to obtain a heartbeat characteristic vector; Inputting the heartbeat feature vector into an artifact recognition model, obtaining an output result of the artifact recognition model, and using the output result as an artifact recognition result; The first preprocessing operation on the marked heartbeat data includes: The real heartbeats and artifacts in the marked heartbeat data are template matched in sequence according to their positions. After all the marked data are matched, the number of heartbeats in each template is counted. The extracting characteristic values ​​of each heartbeat after preprocessing and performing normalization processing to obtain a sample characteristic vector includes: Extracting feature values ​​for each heartbeat after preprocessing, wherein the feature values ​​include the wavelet coefficient of the heartbeat, the total number of heartbeats of the template, the interval ratio of the three intervals before and after the current heartbeat, the matching degree between the current heartbeat and the previous and next heartbeats, the heartbeat differential data information, and the low-frequency and high-frequency noise interference information; The extracted eigenvalues ​​are normalized to obtain the sample eigenvector; The acquiring the collected dynamic electrocardiogram data and performing a second preprocessing operation on the collected dynamic electrocardiogram data include: Acquire the collected dynamic electrocardiogram data, filter the collected dynamic electrocardiogram data, and generate filtered data; Perform heartbeat detection on the filtered data based on the differential threshold algorithm and record the position information of each heartbeat; Perform clustering statistics on each heartbeat and count the number of heartbeats in each template; The template matching of the real heartbeat and the artifact in the marked heartbeat data in sequence according to the positions includes: Calculate the similarity between the marked heartbeat data and the existing templates in sequence according to their positions; If the similarity is greater than or equal to the threshold, it is determined that the heartbeat data belongs to the template, and the data in the template is updated; If the similarity is less than the threshold, the next template is matched and calculated; If the marked heartbeat data does not match any template, a corresponding template is newly created based on the heartbeat data.

2. A system for identifying artifacts of dynamic electrocardiogram signals, characterized in that: The system comprises: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program implements the following steps when executed by the processor: Acquire labeled dynamic electrocardiogram data, wherein the labeled dynamic electrocardiogram data includes heartbeat data, and the heartbeat data type includes real heartbeats and artifacts; Performing a first preprocessing operation on the marked heartbeat data, extracting a feature value from each heartbeat after the preprocessing and performing normalization processing to obtain a sample feature vector; Inputting the sample feature vector into a pre-constructed support vector machine for training to generate a pseudo-error recognition model; Acquire the collected dynamic electrocardiogram data, perform a second preprocessing operation on the collected dynamic electrocardiogram data, extract characteristic values ​​from each heartbeat after the preprocessing, and perform normalization processing to obtain a heartbeat characteristic vector; Inputting the heartbeat feature vector into an artifact recognition model, obtaining an output result of the artifact recognition model, and using the output result as an artifact recognition result; The first preprocessing operation on the marked heartbeat data includes: The real heartbeats and artifacts in the marked heartbeat data are template matched in sequence according to their positions. After all the marked data are matched, the number of heartbeats in each template is counted. The extracting characteristic values ​​of each heartbeat after preprocessing and performing normalization processing to obtain a sample characteristic vector includes: Extracting feature values ​​for each heartbeat after preprocessing, wherein the feature values ​​include the wavelet coefficient of the heartbeat, the total number of heartbeats of the template, the interval ratio of the three intervals before and after the current heartbeat, the matching degree between the current heartbeat and the previous and next heartbeats, the heartbeat differential data information, and the low-frequency and high-frequency noise interference information; The extracted eigenvalues ​​are normalized to obtain the sample eigenvector; The acquiring the collected dynamic electrocardiogram data and performing a second preprocessing operation on the collected dynamic electrocardiogram data include: Acquire the collected dynamic electrocardiogram data, filter the collected dynamic electrocardiogram data, and generate filtered data; Perform heartbeat detection on the filtered data based on the differential threshold algorithm and record the position information of each heartbeat; Perform clustering statistics on each heartbeat and count the number of heartbeats in each template; The template matching of the real heartbeat and the artifact in the marked heartbeat data in sequence according to the positions includes: Calculate the similarity between the marked heartbeat data and the existing templates in sequence according to their positions; If the similarity is greater than or equal to the threshold, it is determined that the heartbeat data belongs to the template, and the data in the template is updated; If the similarity is less than the threshold, the next template is matched and calculated; If the marked heartbeat data does not match any template, a corresponding template is newly created based on the heartbeat data.

3. A non-volatile computer-readable storage medium, characterized in that: The non-volatile computer-readable storage medium stores computer-executable instructions, which, when executed by one or more processors, enable the one or more processors to execute the method for identifying artifacts of dynamic electrocardiogram signals according to claim 1.

Citation Information

Patent Citations

  • A method and system for real-time heart rate detection of electrocardiographic signals

    CN104586384B

  • Identification method for premature beat in dynamic electrocardiogram

    CN108937915A

  • An intelligent electrocardiogram classification method

    CN109171707A

  • Pseudo differential heart beat and abnormal heart beat recognition method based on misclassification and supervised learning

    CN109303561A

  • Dynamic electrocardiosignal artifact recognition method and device thereof

    CN109645979A