Method, device and computer equipment for extracting electrocardiogram signal

The method enhances heart rate signal extraction by filtering out body movement artifacts and noise, improving signal accuracy and reliability through peak detection and quality indicators, addressing interference issues in non-invasive ECG monitoring.

CN118364225BActive Publication Date: 2025-03-18SOUTH CHINA NORMAL UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202410276213.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-03-12
Publication Date
2025-03-18
Estimated Expiration
2044-03-12

AI Technical Summary

Technical Problem

Heart rate signals are prone to interference from body movements and environmental noise, leading to inconsistent monitoring quality in non-invasive ECG signal collection, which complicates data analysis due to individual differences in heart signal morphology.

Method used

A method that extracts heart rate signals by removing body movement artifacts through time and frequency domain features, using peak detection and quality indicators to differentiate between target and non-target signal units, enhancing signal accuracy by combining relevant units.

Benefits of technology

Improves the precision of heart rate signal extraction by filtering out noise and focusing on high-quality signal components, leading to more reliable data for analysis.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118364225B_ABST
    Figure CN118364225B_ABST
Patent Text Reader

Abstract

The present invention relates to the field of signal processing technology, and in particular to a method for extracting an electrocardiogram signal. Based on extracted time domain features and frequency domain features, body motion artifacts are removed from the electrocardiogram signal to obtain a plurality of non-body motion electrocardiogram unit signals corresponding to the electrocardiogram signal. A fast peak-finding method is used to perform preliminary usability detection on the plurality of non-body motion electrocardiogram unit signals, and the signals are divided into target electrocardiogram unit signals and non-target electrocardiogram unit signals. Quality detection indicators of the plurality of non-target electrocardiogram unit signals are extracted, and multi-level information mining is performed on the non-target electrocardiogram unit signals to obtain more sufficient and rich feature information. According to the quality detection indicators, a plurality of target electrocardiogram unit signals are extracted from the plurality of non-target electrocardiogram unit signals, and the plurality of target electrocardiogram unit signals are combined as a signal extraction result of the electrocardiogram signal, thereby improving the accuracy of extraction of ballistocardiogram signals.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of signal processing, and in particular to an electrocardiogram signal extraction method, device, computer equipment and storage medium. Background Art

[0002] Electrocardiogram (ECG) signals are essentially weak force signals of external pressure on the human body surface caused by the beating of the human heart and the flow of arterial blood through blood vessels. Each characteristic point can represent different time points in the process of the heart pumping blood, and has been proven to be effective for monitoring the heart. ECG signals are weak force signals that can be converted into electrical signals through pressure sensors without direct contact, thereby achieving non-intrusive collection of the user's vital signs.

[0003] At present, ECG signals are mainly acquired through non-contact vital signs monitoring. The acquisition equipment does not need to be in direct contact with the subject's body, thus avoiding the discomfort caused to the user by invasive acquisition. The emergence of home-based cardiovascular function monitoring equipment has also improved the convenience of acquiring ECG signals. However, due to the weakness of the ECG signal, its morphology is also easily disturbed. In the actual application scenarios of the above-mentioned acquisition method, the signal will be disturbed by such interferences as breathing, motion artifacts, distance from the sensor, environmental noise, etc., resulting in inconsistent monitoring signal quality, and the same analysis and application cannot be performed. In addition, due to the individual differences of the ECG signal, various influencing factors inside and outside the user's body in different populations will cause the morphology of the ballistocardiogram to change. Therefore, quality control of the ECG signal and selection of relatively better quality data from the signal are of great significance for subsequent data processing and analysis. Summary of the invention

[0004] Based on this, the purpose of the present invention is to provide an electrocardiogram signal extraction method, device, computer equipment and storage medium, based on the extracted time domain features and frequency domain features, remove body motion artifacts from the electrocardiogram signal to be detected, obtain a number of non-body motion electrocardiogram unit signals corresponding to the electrocardiogram signal to be detected, use a fast peak finding method to perform preliminary availability detection on the number of non-body motion electrocardiogram unit signals, divide them into target electrocardiogram unit signals and non-target electrocardiogram unit signals, extract a number of non-target electrocardiogram unit signal quality detection indicators, perform multi-level information mining on the non-target electrocardiogram unit signals, obtain more sufficient and rich feature information, extract a number of target electrocardiogram unit signals from the number of non-target electrocardiogram unit signals according to the quality detection indicators, combine the several target electrocardiogram unit signals as the signal extraction result of the electrocardiogram signal to be detected, and improve the extraction accuracy of the ballistocardiogram signal.

[0005] In a first aspect, an embodiment of the present application provides a method for extracting an electrocardiogram signal, comprising the following steps:

[0006] Obtaining an electrocardiogram signal to be detected, dividing the electrocardiogram signal to be detected into a plurality of initial electrocardiogram unit signals, and extracting time domain features and frequency domain features of the plurality of initial electrocardiogram unit signals;

[0007] According to the time domain features and the frequency domain features, the body motion artifacts of the electrocardiogram signal to be detected are removed to obtain a plurality of non-body motion electrocardiogram unit signals corresponding to the electrocardiogram signal to be detected;

[0008] A fast peak-finding method is used to construct peak location data of a plurality of the non-body movement electrocardiogram unit signals, and according to the peak location data, the plurality of the non-body movement electrocardiogram unit signals are divided into target electrocardiogram unit signals and non-target electrocardiogram unit signals;

[0009] Using a peak location method, constructing peak location data of a plurality of the non-target electrocardiogram unit signals, and obtaining quality detection indicators of a plurality of the non-target electrocardiogram unit signals according to the peak location data;

[0010] According to the quality detection index, a plurality of target electrocardiogram unit signals are extracted from a plurality of non-target electrocardiogram unit signals, and the plurality of target electrocardiogram unit signals are combined as a signal extraction result of the electrocardiogram signal to be detected.

[0011] In a second aspect, an embodiment of the present application provides an electrocardiogram signal extraction device, comprising:

[0012] A signal acquisition module, used for obtaining an electrocardiogram signal to be detected, dividing the electrocardiogram signal to be detected into a plurality of initial electrocardiogram unit signals, and extracting time domain features and frequency domain features of the plurality of initial electrocardiogram unit signals;

[0013] A body motion artifact removal module, used to remove body motion artifacts from the electrocardiogram signal to be detected according to the time domain characteristics and the frequency domain characteristics, and obtain a plurality of non-body motion electrocardiogram unit signals corresponding to the electrocardiogram signal to be detected;

[0014] A first signal extraction module is used to construct peak location data of a plurality of non-body movement electrocardiogram unit signals by using a fast peak search method, and divide the plurality of non-body movement electrocardiogram unit signals into target electrocardiogram unit signals and non-target electrocardiogram unit signals according to the peak location data;

[0015] A quality detection index calculation module, used to construct peak location data of a plurality of non-target electrocardiogram unit signals by using a peak location method, and obtain quality detection indicators of a plurality of non-target electrocardiogram unit signals according to the peak location data;

[0016] The second signal extraction module is used to extract a number of target ECG unit signals from a number of non-target ECG unit signals according to the quality detection index, and combine the several target ECG unit signals as the signal extraction result of the ECG signal to be detected.

[0017] In a third aspect, an embodiment of the present application provides a computer device, comprising a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the steps of the electrocardiogram signal extraction method as described in the first aspect are implemented.

[0018] In a fourth aspect, an embodiment of the present application provides a storage medium, wherein the storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the electrocardiogram signal extraction method as described in the first aspect are implemented.

[0019] In an embodiment of the present application, a method, apparatus, computer equipment and storage medium for extracting an electrocardiogram signal are provided. Based on the extracted time domain features and frequency domain features, body motion artifacts are removed from the electrocardiogram signal to be detected, and a plurality of non-body motion electrocardiogram unit signals corresponding to the electrocardiogram signal to be detected are obtained. A fast peak finding method is used to perform preliminary availability detection on the plurality of non-body motion electrocardiogram unit signals, and the signals are divided into target electrocardiogram unit signals and non-target electrocardiogram unit signals. A plurality of non-target electrocardiogram unit signal quality detection indicators are extracted, and multi-level information mining is performed on the non-target electrocardiogram unit signals to obtain more sufficient and rich feature information. According to the quality detection indicators, a plurality of target electrocardiogram unit signals are extracted from the plurality of non-target electrocardiogram unit signals, and the plurality of target electrocardiogram unit signals are combined as the signal extraction result of the electrocardiogram signal to be detected, thereby improving the extraction accuracy of the ballistocardiogram signal.

[0020] For better understanding and implementation, the present invention is described in detail below with reference to the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS

[0021] Figure 1 A schematic diagram of a flow chart of a method for extracting an electrocardiogram signal provided in one embodiment of the present application;

[0022] Figure 2 A schematic diagram of S1 in the process of the electrocardiogram signal extraction method provided in one embodiment of the present application;

[0023] Figure 3 A schematic diagram of S3 in the process of the electrocardiogram signal extraction method provided in one embodiment of the present application;

[0024] Figure 4 A schematic diagram of S4 in the process of the electrocardiogram signal extraction method provided in one embodiment of the present application;

[0025] Figure 5 A schematic diagram of S5 in the process of the electrocardiogram signal extraction method provided by one embodiment of the present application;

[0026] Figure 6 A schematic diagram of S5 in the process of the electrocardiogram signal extraction method provided by another embodiment of the present application;

[0027] Figure 7 A schematic diagram of S54 in the process of the electrocardiogram signal extraction method provided by one embodiment of the present application;

[0028] Figure 8 A schematic diagram of the structure of an electrocardiogram signal extraction device provided in one embodiment of the present application;

[0029] Fig. 9 A schematic diagram of the structure of a computer device provided for one embodiment of the present application. DETAILED DESCRIPTION

[0030] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The implementations described in the following exemplary embodiments do not represent all implementations consistent with the present application. Instead, they are merely examples of devices and methods consistent with some aspects of the present application as detailed in the appended claims.

[0031] The terms used in this application are for the purpose of describing specific embodiments only and are not intended to limit this application. The singular forms of "a", "said" and "the" used in this application and the appended claims are also intended to include plural forms unless the context clearly indicates other meanings. It should also be understood that the term "and / or" used herein refers to and includes any or all possible combinations of one or more associated listed items.

[0032] It should be understood that, although the terms first, second, third, etc. may be used in the present application to describe various information, these information should not be limited to these terms. These terms are only used to distinguish the same type of information from each other. For example, without departing from the scope of the present application, the first information may also be referred to as the second information, and similarly, the second information may also be referred to as the first information. Depending on the context, the words "if" / "if" as used herein may be interpreted as "at the time of" or "when" or "in response to determination".

[0033] See also Figure 1 , Figure 1 A schematic flow chart of a method for extracting an electrocardiogram signal provided in an embodiment of the present application, the method comprising the following steps:

[0034] S1: obtaining an electrocardiogram signal to be detected, dividing the electrocardiogram signal to be detected into a number of initial electrocardiogram unit signals, and extracting time domain features and frequency domain features of the initial electrocardiogram unit signals.

[0035] The executor of the electrocardiogram signal extraction method is a detection device of the electrocardiogram signal extraction method (hereinafter referred to as the detection device). In an optional embodiment, the detection device can be a computer device, a server, or a server cluster composed of multiple computer devices.

[0036] In this embodiment, the detection device can obtain the electrocardiogram signal to be detected of the user to be detected by querying in a preset database, or it can collect the electrocardiogram signal to be detected of the user to be detected through positive and negative electrodes. In the application scenario of this embodiment, by setting corresponding positive and negative electrodes on the smart toilet mat, a single-lead electrocardiogram signal of the buttocks of the user to be detected is collected during the process of the user to be detected using the toilet as the electrocardiogram signal to be detected.

[0037] Since the baseline of the collected hip single-lead electrocardiogram signal usually contains a large number of burrs, in an optional embodiment, the detection device preprocesses the electrocardiogram signal to be detected. Specifically, the preprocessing includes the steps of:

[0038] The detection device downsamples the electrocardiogram signal to be detected to improve the computing speed under the premise of ensuring that the signal is not distorted. The detection device uses a preset time window to cut the downsampled electrocardiogram signal to be detected, obtain a set of electrocardiogram signal segments corresponding to several time windows, calculate the range of several time windows, select 3 times the median of the range of several time windows as the threshold, remove several time windows with ranges greater than the threshold, and then take the median of the range of the remaining part to represent the amplitude of the electrocardiogram signal to be detected, normalize the amplitude of the electrocardiogram signal to be detected according to the amplitude, use a bandpass filter to filter out the power frequency interference and high-frequency noise of the electrocardiogram signal to be detected after amplitude normalization, and obtain the preprocessed electrocardiogram signal to be detected.

[0039] The detection device divides the preprocessed electrocardiogram signal to be detected into a number of initial electrocardiogram unit signals, and extracts time domain features and frequency domain features of the initial electrocardiogram unit signals, wherein the time domain features include variance, and the frequency domain features include main frequency, bandwidth, spectrum flatness and spectrum ratio, and the variance is:

[0040]

[0041] In the formula, is the variance, is the initial ECG unit signal, To find the variance function.

[0042] The main frequency is:

[0043]

[0044] In the formula, is the main frequency, is the frequency component of the initial ECG unit signal, To find the aggregate function.

[0045] The bandwidth is:

[0046]

[0047] In the formula, is the frequency bandwidth, is the frequency at which the total energy of the initial ECG unit signal is 10%, is the frequency at which the total energy of the initial ECG unit signal is 90%.

[0048] The spectral flatness is:

[0049]

[0050] In the formula, is the spectral flatness, is the first unit signal in the initial electrocardiogram i The amplitude of the frequency component, N is the number of frequency components.

[0051] The spectral ratio is:

[0052]

[0053] In the formula, is the spectrum ratio, is the energy of all 15 Hz-35 Hz frequency components in the initial ECG unit signal, It is the energy of all frequency components of 2 Hz-15 Hz in the initial ECG unit signal.

[0054] S2: According to the time domain features and the frequency domain features, body motion artifacts are removed from the electrocardiogram signal to be detected, so as to obtain a plurality of non-body motion electrocardiogram unit signals corresponding to the electrocardiogram signal to be detected.

[0055] In this embodiment, the detection device performs body motion artifact removal on the electrocardiogram signal to be detected based on the time domain characteristics and frequency domain characteristics to remove body motion artifacts and signal segments affected by electrode detachment, and obtains a number of non-body motion electrocardiogram unit signals corresponding to the electrocardiogram signal to be detected.

[0056] See also Figure 2 , Figure 2 The schematic diagram of S1 in the process of the electrocardiogram signal extraction method provided in one embodiment of the present application includes steps S21-S22, which are specifically as follows:

[0057] S21: construct an algorithm based on the variance, main frequency, bandwidth, spectral flatness, spectrum ratio and preset threshold values ​​of several initial electrocardiogram unit signals to obtain a variance threshold, a main frequency threshold, a bandwidth threshold, a spectral flatness threshold and a spectrum ratio threshold.

[0058] The threshold construction algorithm is:

[0059]

[0060] In the formula, is the variance threshold, is the main frequency threshold, is the bandwidth threshold, is the spectrum flatness threshold, is the spectrum ratio threshold, is the variance, is the main frequency, is the frequency bandwidth, is the spectral flatness, is the spectrum ratio, To find the mean function;

[0061] In this embodiment, the detection device constructs an algorithm based on the variance, main frequency, bandwidth, spectral flatness, spectrum ratio and preset thresholds of several initial electrocardiogram unit signals to obtain the variance threshold, main frequency threshold, bandwidth threshold, spectral flatness threshold and spectrum ratio threshold.

[0062] S22: Compare the variance, main frequency, bandwidth, spectral flatness and spectrum ratio of several initial electrocardiogram unit signals with the corresponding variance threshold, main frequency threshold, bandwidth threshold, spectral flatness threshold and spectrum ratio threshold respectively, to obtain threshold comparison results of several initial electrocardiogram unit signals; based on the threshold comparison results, take the initial electrocardiogram unit signals as non-body movement electrocardiogram unit signals, to obtain several non-body movement electrocardiogram unit signals corresponding to the electrocardiogram signals to be detected.

[0063] In this embodiment, the detection device compares the variance, main frequency, bandwidth, spectral flatness, and spectrum ratio of several of the initial electrocardiogram unit signals with the corresponding variance threshold, main frequency threshold, bandwidth threshold, spectral flatness threshold, and spectrum ratio threshold, respectively, to obtain threshold comparison results of several of the initial electrocardiogram unit signals, wherein the threshold comparison results include a threshold greater than comparison result.

[0064] The detection device uses the threshold comparison result as the basis, and if the threshold of the initial electrocardiogram unit signal is greater than the number of comparison results and is less than a preset first comparison number threshold, the initial electrocardiogram unit signal is used as a non-body movement electrocardiogram unit signal to obtain a number of non-body movement electrocardiogram unit signals corresponding to the electrocardiogram signal to be detected.

[0065] S3: adopting a fast peak-finding method to construct peak location data of a plurality of the non-body movement electrocardiogram unit signals, and dividing the plurality of the non-body movement electrocardiogram unit signals into target electrocardiogram unit signals and non-target electrocardiogram unit signals according to the peak location data.

[0066] In this embodiment, the detection device adopts a fast peak search method to construct peak location data of several non-body movement electrocardiogram unit signals. Specifically, the detection device performs simple peak search on several non-body movement electrocardiogram unit signals to obtain several maximum points, i.e., peak points, of the non-body movement electrocardiogram unit signals. If the distance between adjacent peak points is 0.3s (usually the distance between the R peak and the T peak), the largest peak point is taken and other peak points within 0.3s are removed; if the peak width of the peak is less than 0.15s (the maximum width of a normal QRS wave group), the peak point is removed; if the amplitude parameter corresponding to the peak point is less than the amplitude parameter 3uv of the previous peak point, the peak point is removed to construct the peak location data of several non-body movement electrocardiogram unit signals, wherein the peak location data includes the peak location parameters of several peak points, and the peak location parameters include amplitude parameters and position parameters.

[0067] The detection device divides the plurality of non-body movement electrocardiogram unit signals into target electrocardiogram unit signals and non-target electrocardiogram unit signals according to the peak location data.

[0068] See also Figure 3 , Figure 3 The schematic diagram of S3 in the process of the electrocardiogram signal extraction method provided in one embodiment of the present application includes steps S31 to S33, which are specifically as follows:

[0069] S31: Calculate the peak interval data of the non-body movement electrocardiogram according to the position parameters of the peak points in the peak positioning data, and obtain the interval stability judgment results of the non-body movement electrocardiogram unit signals according to the interval parameters between the peak points and adjacent peak points in the peak interval data and the preset interval threshold.

[0070] In this embodiment, the detection device calculates a plurality of peak interval data of the non-body motion electrocardiogram according to the position parameters of a plurality of peak points in the peak location data, wherein the peak interval data is:

[0071]

[0072] In the formula, For the i The interval parameter between a peak point and the adjacent peak points, For the i +1 peak point location parameter, For the i The location parameters of the peak points, k is the number of peak points.

[0073] The detection device obtains interval stability judgment results of several non-body movement electrocardiogram unit signals according to the interval parameters between several peak points and adjacent peak points in the peak interval data and a preset interval threshold, wherein the interval stability judgment results include interval stability results and interval instability results. Specifically, if the interval data between several peak points and adjacent peak points in the peak interval data are all less than the interval threshold, the interval stability result of the non-body movement electrocardiogram unit signal is obtained; otherwise, the interval instability result of the non-body movement electrocardiogram unit signal is obtained.

[0074] S32: Calculate the amplitude difference data of the non-body movement electrocardiogram unit signal whose interval stability judgment result is the interval stability result according to the amplitude parameters of several peak points in the peak positioning data, and obtain the amplitude stability judgment result of the non-body movement electrocardiogram unit signal according to the amplitude difference parameters between several peak points and adjacent peak points in the amplitude difference data and a preset amplitude difference threshold.

[0075] In this embodiment, the detection device calculates the amplitude difference data of the non-body motion electrocardiogram unit signal whose interval stability judgment result is the interval stability result according to the amplitude parameters of several peak points in the peak positioning data, wherein the amplitude difference data is:

[0076]

[0077] In the formula, For the i The amplitude difference parameter between a peak point and the adjacent peak point, For the i +1 peak point amplitude parameter, For the i The amplitude parameter of the peak point.

[0078] The detection device obtains an amplitude stability judgment result of the non-body movement electrocardiogram unit signal based on the amplitude difference parameters between several peak points and adjacent peak points in the amplitude difference data and a preset amplitude difference threshold, wherein the amplitude stability judgment result includes an amplitude stability result and an amplitude instability result. Specifically, if the amplitude difference parameters between several peak points and adjacent peak points in the peak interval data are all less than the amplitude difference threshold, the amplitude stability result of the non-body movement electrocardiogram unit signal is obtained; otherwise, the amplitude instability result of the non-body movement electrocardiogram unit signal is obtained.

[0079] S33: If the amplitude stability judgment result of the non-body movement ECG unit signal is an amplitude stability result, the non-body movement ECG unit signal is classified as a target ECG unit signal, and other non-body movement ECG unit signals are classified as non-target ECG unit signals.

[0080] In this embodiment, if the amplitude stability judgment result of the non-body movement ECG unit signal is an amplitude stability result, the detection device divides the non-body movement ECG unit signal into a target ECG unit signal, and divides other non-body movement ECG unit signals into non-target ECG unit signals.

[0081] S4: adopting a peak location method to construct peak location data of a plurality of the non-target electrocardiogram unit signals, and obtaining quality detection indicators of a plurality of the non-target electrocardiogram unit signals according to the peak location data.

[0082] In this embodiment, the detection device adopts a peak positioning method to construct peak positioning data of several non-target electrocardiogram unit signals, wherein the peak positioning data of the non-target electrocardiogram unit signal includes first sub-peak positioning data and second sub-peak positioning data, the first sub-peak positioning data is peak positioning data obtained by using a Hamilton positioning algorithm, and the second sub-peak positioning data is peak positioning data obtained by using an Engzee positioning algorithm; the first sub-peak positioning data and the second sub-peak positioning data both include peak positioning parameters of several peak points.

[0083] The detection device obtains several quality detection indicators of the non-target electrocardiogram unit signal based on the peak positioning data, wherein the quality detection indicators include a positioning consistency quality indicator, an interval consistency quality indicator, a wave group morphology consistency quality indicator and an amplitude quality indicator.

[0084] See also Figure 4 , Figure 4 The schematic diagram of S4 in the process of the electrocardiogram signal extraction method provided in one embodiment of the present application includes steps S41 to S46, which are specifically as follows:

[0085] S41: Perform consistency judgment on the position parameters of the peak points under the same position index in the first sub-peak positioning data and the second sub-peak positioning data of the same non-target ECG unit signal, obtain several first peak points of the same position data and second peak points of different position data under the same position index, combine several first peak points of the same non-target ECG unit signal to construct several consistent peak positioning data of the non-target ECG unit signal, and combine several second peak points of the same non-target ECG unit signal to construct several inconsistent peak positioning data of the non-target ECG unit signal.

[0086] In this embodiment, the detection device makes a consistency judgment on the position parameters of the peak points under the same position index in the first sub-peak positioning data and the second sub-peak positioning data of the same non-target electrocardiogram unit signal, obtains several first peak points of the same position data and second peak points of different position data under the same position index, combines several first peak points of the same non-target electrocardiogram unit signal to construct several consistent peak positioning data of the non-target electrocardiogram unit signal, and combines several second peak points of the same non-target electrocardiogram unit signal to construct several inconsistent peak positioning data of the non-target electrocardiogram unit signal.

[0087] S42: Obtain positioning consistency quality indicators of several non-target electrocardiogram unit signals according to the first sub-peak positioning data, the second sub-peak positioning data, the consistent peak positioning data and a preset first indicator calculation algorithm of the several non-target electrocardiogram unit signals.

[0088] The first indicator calculation algorithm is:

[0089]

[0090] In the formula, To locate the consistency quality indicator, To locate the data for the consistent peak, is the first sub-peak location data, Positioning data for the second sub-peak, To find the length function, it is used to indicate the number of peak points.

[0091] In this embodiment, the detection device obtains the positioning consistency quality indicators of several non-target electrocardiogram unit signals based on the first sub-peak positioning data, the second sub-peak positioning data, the consistent peak positioning data and the preset first indicator calculation algorithm of several non-target electrocardiogram unit signals.

[0092] S43: According to the consistent peak location data and the inconsistent peak location data of the same non-target electrocardiogram unit signal, the first sub-peak location data and the second sub-peak location data are fused to construct fused peak location data of several non-target electrocardiogram unit signals.

[0093] In this embodiment, the detection device fuses the first sub-peak positioning data and the second sub-peak positioning data according to the consistent peak positioning data and the inconsistent peak positioning data of the same non-target electrocardiogram unit signal, and constructs fused peak positioning data of several non-target electrocardiogram unit signals, wherein the fused peak positioning data includes peak positioning parameters of several fused peak points.

[0094] Specifically, the detection device determines that the first peak point and the second peak point with the same position index in the consistent peak positioning data and the inconsistent peak positioning data of the same non-target electrocardiogram unit signal are the first erroneous peak point if the second peak point appears within 0.36 s before or after the position of the first peak point with the position index, and uses the second peak point that appears within 0.36 s before or after the position of the first peak point with the position index as the first candidate fusion peak point; if the second peak point does not appear within 0.36 s before or after the position of the first peak point with the position index, the first peak point with the position index is used as the first candidate fusion peak point, thereby realizing preliminary self-check of the peak points.

[0095] After completing the preliminary self-check of the peak point, the detection device locates the second peak points of several position indexes in the inconsistent peak location data of several non-target electrocardiogram unit signals. If there are two adjacent second peak points with the position index before and after the second peak point position of the second peak point of the position index within 0.36s of the second peak point of the position index, the second peak points of the two adjacent second peak points with the position index are used as the second candidate peak point. If not, the second peak point of the position index is used as the second candidate peak point.

[0096] The detection device calculates the variance of the first candidate peak points and the second candidate peak points of the position indexes based on the amplitude parameters, compares the variance of the first candidate peak point and the second candidate peak point of the same position index based on the amplitude parameters, takes the candidate peak point with the smaller variance based on the amplitude parameters as the target fusion peak point, obtains the target fusion peak points of the position indexes of the non-target electrocardiogram unit signals, and constructs the fusion peak positioning data of the non-target electrocardiogram unit signals to ensure that the fusion peak positioning data obtained after the fusion processing has better interval stability and amplitude stability.

[0097] S44: Calculate the fused peak interval data of the non-body movement electrocardiogram unit signals according to the position parameters of the fused peak points in the fused peak positioning data of the non-target electrocardiogram unit signals, and obtain the interval consistency quality index of the non-target electrocardiogram unit signals according to the fused peak interval data and a preset second index calculation algorithm.

[0098] The second indicator calculation algorithm is:

[0099]

[0100] In the formula, is the quality index of the interval consistency, is the interval value of the top 15% in the fused peak interval data, The interval values ​​of the top 85% of the fused peak interval data;

[0101] In this embodiment, the detection device calculates the fused peak interval data of several non-body movement ECG unit signals based on the position parameters of several fused peak points in the fused peak positioning data of several non-target ECG unit signals, and obtains the interval consistency quality indicators of several non-target ECG unit signals based on the fused peak interval data and a preset second indicator calculation algorithm, which are used to reflect the interval stability of the non-target ECG unit signals.

[0102] S45: According to the amplitude parameters of several fused peak points in the fused peak positioning data of several non-target electrocardiogram unit signals and a preset amplitude threshold, obtain the amplitude mutation data of several non-target electrocardiogram unit signals, and according to the amplitude mutation data and a preset third indicator calculation algorithm, obtain the amplitude quality indicators of several non-target electrocardiogram unit signals.

[0103] In this embodiment, the detection device obtains amplitude mutation data of several non-target electrocardiogram unit signals based on the amplitude parameters of several fused peak points in the fused peak positioning data of several non-target electrocardiogram unit signals and a preset amplitude threshold, wherein the amplitude mutation data is used to indicate the number of times that the amplitude parameters of the fused peak points in the preset window are greater than the amplitude threshold.

[0104] The detection device obtains a plurality of amplitude quality indicators of the non-target electrocardiogram unit signal according to the amplitude mutation data and a preset third indicator calculation algorithm, which are used to reflect the amplitude mutation degree of the fusion peak point of the non-target electrocardiogram unit signal, wherein the third indicator calculation algorithm is:

[0105]

[0106] In the formula, is the amplitude quality indicator, is the amplitude mutation data;

[0107] S46: Calculate the wave group area data of the non-body movement electrocardiogram unit signals based on the fused peak positioning data of the non-target electrocardiogram unit signals, and obtain the wave group morphology consistency quality index of the non-target electrocardiogram unit signals based on the wave group area data and a preset fourth index calculation algorithm.

[0108] In this embodiment, the detection device calculates the wave group area data of several non-body movement electrocardiogram unit signals based on the fused peak positioning data of several non-target electrocardiogram unit signals, wherein the wave group area data includes wave group area parameters corresponding to several fused peak points.

[0109] Specifically, the detection equipment respectively takes several fused peak points in the fused peak positioning data of the non-target electrocardiogram unit signal as the center, divides the data forward and backward according to a preset time range, constructs several signal segments corresponding to the fused peak points, integrates the signal segments, obtains the result of the integration processing as the wave group area data corresponding to the fused peak points, combines the wave group area data corresponding to several fused peak points of the same non-body movement electrocardiogram unit signal, and constructs several wave group area data of the non-body movement electrocardiogram unit signal.

[0110] The detection device obtains a plurality of wave group morphology consistency quality indicators of the non-target electrocardiogram unit signals according to the wave group area data and a preset fourth indicator calculation algorithm, which is used to reflect the wave group robustness of the non-target electrocardiogram unit signal, wherein the fourth indicator calculation algorithm is:

[0111]

[0112] In the formula, is the wave group morphology consistency quality index, is the number of fusion peak points, For the i The wave group area parameter corresponding to the fusion peak point, For the j The wave group area parameter corresponding to the fusion peak point.

[0113] S5: extracting a plurality of target electrocardiogram unit signals from a plurality of non-target electrocardiogram unit signals according to the quality detection index, and combining the plurality of target electrocardiogram unit signals as a signal extraction result of the electrocardiogram signal to be detected.

[0114] In this embodiment, the detection device extracts several target ECG unit signals from several non-target ECG unit signals according to the quality detection index, and combines the several target ECG unit signals as the signal extraction result of the ECG signal to be detected.

[0115] Based on the extracted time domain features and frequency domain features, the body motion artifacts of the electrocardiogram signal to be detected are removed to obtain a number of non-body motion electrocardiogram unit signals corresponding to the electrocardiogram signal to be detected, and a fast peak finding method is used to perform preliminary availability detection on the number of non-body motion electrocardiogram unit signals, which are divided into target electrocardiogram unit signals and non-target electrocardiogram unit signals, and a number of non-target electrocardiogram unit signal quality detection indicators are extracted. Multi-level information mining is performed on the non-target electrocardiogram unit signals to obtain more sufficient and rich feature information, and according to the quality detection indicators, a number of target electrocardiogram unit signals are extracted from the number of non-target electrocardiogram unit signals, and the several target electrocardiogram unit signals are combined as the signal extraction result of the electrocardiogram signal to be detected, thereby improving the accuracy of extraction of the ballistocardiogram signal.

[0116] See also Figure 5 , Figure 5 The schematic diagram of S5 in the process of the electrocardiogram signal extraction method provided in one embodiment of the present application includes steps S51 to S52, which are specifically as follows:

[0117] S51: Compare the positioning consistency quality index, interval consistency quality index, wave group morphology consistency quality index and amplitude quality index of the quality detection indicators of several non-target electrocardiogram unit signals with the corresponding quality detection indicator thresholds respectively to obtain the first quality detection indicator comparison results of several non-target electrocardiogram unit signals.

[0118] In this embodiment, the detection device compares the positioning consistency quality index, interval consistency quality index, wave group morphology consistency quality index and amplitude quality index of the quality detection indicators of several non-target electrocardiogram unit signals with the corresponding quality detection indicator thresholds, and obtains the first quality detection indicator comparison results of several non-target electrocardiogram unit signals, wherein the first quality detection indicator comparison results include the first quality detection indicator is less than the result.

[0119] S52: If the first quality detection index of the non-target ECG unit signal is less than the result number is less than or equal to the preset comparison number threshold, the non-target ECG unit signal is used as the target ECG unit signal, and several target ECG unit signals are extracted from the several non-target ECG unit signals.

[0120] In this embodiment, if the first quality detection index of the non-target ECG unit signal is less than the result number is less than or equal to the preset comparison number threshold, the detection device uses the non-target ECG unit signal as the target ECG unit signal and extracts several target ECG unit signals from the several non-target ECG unit signals.

[0121] See also Figure 6 , Figure 6 The schematic diagram of S5 in the process of the electrocardiogram signal extraction method provided in another embodiment of the present application further includes steps S53 to S56, which are specifically as follows:

[0122] S53: If the first quality detection index of the non-target electrocardiogram unit signal is less than the result number is greater than the comparison number threshold, construct the template peak positioning data of the non-target electrocardiogram unit signal according to the fused peak positioning data of the non-target electrocardiogram unit signal and the preset first time length.

[0123] If the first quality detection index of the non-target ECG unit signal is less than the result number and is greater than the comparison number threshold, in this embodiment, the detection device constructs template peak positioning data of the non-target ECG unit signal based on the fused peak positioning data of the non-target ECG unit signal and a preset first time length, wherein the template peak positioning data includes peak positioning parameters of several fused peak points within a preset first time length before and after the first fused peak point in the fused peak positioning data.

[0124] S54: Perform correlation analysis on the fused peak positioning data of the non-target ECG unit signal and the template peak positioning data to obtain the correlation coefficients of several fused peak points of the non-target ECG unit signal; and obtain the relevant consistency quality index and the relevant volatility quality index of the non-target ECG unit signal based on the correlation coefficients of several fused peak points of the non-target ECG unit signal and a preset fifth indicator calculation algorithm.

[0125] In this embodiment, the detection device adopts the Pearson correlation coefficient calculation method to perform correlation analysis on the fused peak positioning data of the non-target ECG unit signal and the template peak positioning data to obtain the correlation coefficient of several fused peak points of the non-target ECG unit signal.

[0126] The detection device obtains the relevant consistency quality index and the relevant volatility quality index of the non-target electrocardiogram unit signal according to the correlation coefficient of several fused peak points of the non-target electrocardiogram unit signal and the preset fifth indicator calculation algorithm, wherein the relevant consistency quality index is used to reflect the average similarity between the fused peak positioning data and the template peak positioning data of the non-target electrocardiogram unit signal, and the relevant volatility quality index is used to reflect the fluctuation degree of the correlation coefficient between the fused peak positioning data and the template peak positioning data of the non-target electrocardiogram unit signal, and the fifth indicator calculation algorithm is:

[0127]

[0128] In the formula, is the relevant consistency quality indicator, For the i The correlation coefficient of the fusion peak points is is the relevant volatility quality indicator;

[0129] S55: Compare the positioning consistency quality index, interval consistency quality index, wave group morphology consistency quality index, amplitude quality index, correlation consistency quality index and correlation volatility quality index of the quality detection indicators of the non-target electrocardiogram unit signal with the corresponding quality detection indicator thresholds respectively to obtain the second quality detection indicator comparison result of the non-target electrocardiogram unit signal.

[0130] In this embodiment, the detection device compares the positioning consistency quality index, interval consistency quality index, wave group morphology consistency quality index, amplitude quality index, related consistency quality index and related volatility quality index of the quality detection indicators of the non-target electrocardiogram unit signal with the corresponding quality detection indicator thresholds, and obtains a second quality detection indicator comparison result of the non-target electrocardiogram unit signal, wherein the second quality detection indicator comparison result includes a second quality detection indicator less than result.

[0131] S56: If the second quality detection index of the non-target ECG unit signal is less than the result number is less than or equal to the preset comparison number threshold, the non-target ECG unit signal is used as the target ECG unit signal, and several target ECG unit signals are extracted from the several non-target ECG unit signals.

[0132] If the second quality detection index of the non-target ECG unit signal is less than the result number is less than or equal to the preset comparison number threshold, in this embodiment, the detection device takes the non-target ECG unit signal as the target ECG unit signal and extracts several target ECG unit signals from several non-target ECG unit signals.

[0133] See also Figure 7 , Figure 7 The schematic diagram of S54 in the process of the electrocardiogram signal extraction method provided in one embodiment of the present application also includes step S541, which is as follows:

[0134] S541: Based on the correlation coefficients of several fused peak points of the non-target ECG unit signal and a preset correlation coefficient threshold, if the correlation coefficients of all fused peak points are less than or equal to the correlation coefficient threshold, based on the fused peak positioning data of the non-target ECG unit signal and a preset second time length, reconstruct the template peak positioning data of the non-target ECG unit signal as the updated template peak positioning data.

[0135] In this embodiment, the detection device reconstructs the template peak positioning data of the non-target ECG unit signal according to the correlation coefficient of several fused peak points of the non-target ECG unit signal and a preset correlation coefficient threshold. If the correlation coefficients of all fused peak points are less than or equal to the correlation coefficient threshold, the detection device reconstructs the template peak positioning data of the non-target ECG unit signal according to the fused peak positioning data of the non-target ECG unit signal and a preset second time length as the updated template peak positioning data, so as to improve the accuracy of the calculation of relevant consistency quality indicators and relevant volatility quality indicators.

[0136] Please refer to Figure 8 , Figure 8 This is a schematic diagram of the structure of an electrocardiogram signal extraction device provided in one embodiment of the present application. The device can implement all or part of the electrocardiogram signal extraction device through software, hardware, or a combination of both. The device 8 includes:

[0137] The signal acquisition module 81 is used to obtain the electrocardiogram signal to be detected, divide the electrocardiogram signal to be detected into a plurality of initial electrocardiogram unit signals, and extract the time domain features and frequency domain features of the plurality of initial electrocardiogram unit signals, wherein the electrocardiogram signal to be detected is a single-lead electrocardiogram signal of the buttocks collected by the positive and negative electrodes arranged on the smart toilet mat;

[0138] A body motion artifact removal module 82, configured to remove body motion artifacts from the electrocardiogram signal to be detected according to the time domain features and the frequency domain features, and obtain a plurality of non-body motion electrocardiogram unit signals corresponding to the electrocardiogram signal to be detected;

[0139] A first signal extraction module 83 is used to construct peak location data of a plurality of non-body movement electrocardiogram unit signals by using a fast peak search method, and divide the plurality of non-body movement electrocardiogram unit signals into target electrocardiogram unit signals and non-target electrocardiogram unit signals according to the peak location data;

[0140] The quality detection index calculation module 84 is used to construct peak location data of a plurality of non-target electrocardiogram unit signals by using a peak location method, and obtain quality detection indicators of a plurality of non-target electrocardiogram unit signals according to the peak location data;

[0141] The second signal extraction module 85 is used to extract a plurality of target ECG unit signals from a plurality of non-target ECG unit signals according to the quality detection index, and combine the plurality of target ECG unit signals as the signal extraction result of the ECG signal to be detected.

[0142] In an embodiment of the present application, an electrocardiogram signal to be detected is obtained through a signal acquisition module, the electrocardiogram signal to be detected is divided into a number of initial electrocardiogram unit signals, and time domain features and frequency domain features of the initial electrocardiogram unit signals are extracted, wherein the electrocardiogram signal to be detected is a single-lead electrocardiogram signal of the buttocks collected by positive and negative electrodes set on the smart toilet mat; through a body motion artifact removal module, body motion artifacts are removed from the electrocardiogram signal to be detected according to the time domain features and frequency domain features, and a number of non-body motion electrocardiogram unit signals corresponding to the electrocardiogram signal to be detected are obtained; through a first signal extraction module, a fast peak finding method is adopted to construct a number of the non-body motion electrocardiogram unit signals. The peak location data of the signal is obtained, and according to the peak location data, a plurality of the non-body movement electrocardiogram unit signals are divided into target electrocardiogram unit signals and non-target electrocardiogram unit signals; through a quality detection index calculation module, a peak location method is adopted to construct the peak location data of a plurality of the non-target electrocardiogram unit signals, and according to the peak location data, the quality detection index of a plurality of the non-target electrocardiogram unit signals is obtained; through a second signal extraction module, according to the quality detection index, a plurality of target electrocardiogram unit signals are extracted from a plurality of the non-target electrocardiogram unit signals, and a plurality of the target electrocardiogram unit signals are combined as the signal extraction result of the electrocardiogram signal to be detected. Based on the extracted time domain features and frequency domain features, the body motion artifacts of the electrocardiogram signal to be detected are removed to obtain a number of non-body motion electrocardiogram unit signals corresponding to the electrocardiogram signal to be detected, and a fast peak finding method is used to perform preliminary availability detection on the number of non-body motion electrocardiogram unit signals, which are divided into target electrocardiogram unit signals and non-target electrocardiogram unit signals, and a number of non-target electrocardiogram unit signal quality detection indicators are extracted. Multi-level information mining is performed on the non-target electrocardiogram unit signals to obtain more sufficient and rich feature information, and according to the quality detection indicators, a number of target electrocardiogram unit signals are extracted from the number of non-target electrocardiogram unit signals, and the several target electrocardiogram unit signals are combined as the signal extraction result of the electrocardiogram signal to be detected, thereby improving the accuracy of extraction of the ballistocardiogram signal.

[0143] Please refer to Fig. 9 , Fig. 9 The computer device 9 is a schematic diagram of a structure of a computer device provided in an embodiment of the present application. The computer device 9 includes: a processor 91, a memory 92, and a computer program 93 stored in the memory 92 and executable on the processor 91; the computer device may store a plurality of instructions, which are suitable for being loaded and executed by the processor 91 Figures 1 to 7 The method steps of the embodiment shown in the figure can be found in the specific implementation process. Figures 1 to 7 The specific description of the illustrated embodiment will not be repeated here.

[0144] Among them, the processor 91 may include one or more processing cores. The processor 91 uses various interfaces and lines to connect various parts in the server, and executes various functions and processes data of the electrocardiogram signal extraction device 8 by running or executing instructions, programs, code sets or instruction sets stored in the memory 92, and calling the data in the memory 92. Optionally, the processor 91 can be implemented in at least one hardware form of digital signal processing (Digital Signal Processing, DSP), field programmable gate array (Field-Programmable Gate Array, FPGA), and programmable logic array (Programble Logic Array, PLA). The processor 91 can integrate one or a combination of a central processing unit 91 (Central Processing Unit, CPU), a graphics processing unit 91 (Graphics Processing Unit, GPU) and a modem. Among them, the CPU mainly processes the operating system, user interface and application programs; the GPU is responsible for rendering and drawing the content to be displayed on the touch display screen; the modem is used to process wireless communication. It can be understood that the above-mentioned modem may not be integrated into the processor 91, and it can be implemented by a single chip.

[0145] The memory 92 may include a random access memory 92 (RAM) or a read-only memory 92 (Read-Only Memory). Optionally, the memory 92 includes a non-transitory computer-readable storage medium. The memory 92 may be used to store instructions, programs, codes, code sets or instruction sets. The memory 92 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for at least one function (such as touch instructions, etc.), instructions for implementing the above-mentioned various method embodiments, etc.; the data storage area may store data involved in the above-mentioned various method embodiments, etc. The memory 92 may also be optionally at least one storage device located away from the aforementioned processor 91.

[0146] The present application also provides a storage medium that can store multiple instructions, which are suitable for the processor to load and execute the above-mentioned Figures 1 to 7 The method steps of the embodiment shown in the figure can be found in the specific execution process. Figures 1 to 7 The specific description of the illustrated embodiment will not be repeated here.

[0147] The technicians in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In practical applications, the above-mentioned function allocation can be completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiment can be integrated in a processing unit, or each unit can exist physically separately, or two or more units can be integrated in one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of this application. The specific working process of the units and modules in the above-mentioned system can refer to the corresponding process in the aforementioned method embodiment, which will not be repeated here.

[0148] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0149] Those skilled in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraint algorithm of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.

[0150] In the embodiments provided by the present invention, it should be understood that the disclosed devices / terminal equipment and methods can be implemented in other ways. For example, the device / terminal equipment embodiments described above are only schematic. For example, the division of the modules or units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0151] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0152] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.

[0153] If the integrated module / unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the present invention implements all or part of the processes in the above-mentioned embodiment method, and can also be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and when the computer program is executed by a processor, the steps of the above-mentioned method embodiments can be implemented. Among them, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form, etc.

[0154] The present invention is not limited to the above-mentioned embodiments. If various changes or modifications to the present invention do not depart from the spirit and scope of the present invention, and if these changes and modifications fall within the scope of the claims and equivalent technologies of the present invention, the present invention is also intended to include these changes and modifications.

Claims

1. A method for extracting an electrocardiogram signal, characterized in that: The following steps are involved: Obtaining an electrocardiogram signal to be detected, dividing the electrocardiogram signal to be detected into a plurality of initial electrocardiogram unit signals, and extracting time domain features and frequency domain features of the plurality of initial electrocardiogram unit signals; According to the time domain features and the frequency domain features, the body motion artifacts of the electrocardiogram signal to be detected are removed to obtain a plurality of non-body motion electrocardiogram unit signals corresponding to the electrocardiogram signal to be detected; A fast peak-finding method is used to construct peak location data of a plurality of the non-body movement electrocardiogram unit signals, and according to the peak location data, the plurality of the non-body movement electrocardiogram unit signals are divided into target electrocardiogram unit signals and non-target electrocardiogram unit signals; The peak location data includes peak location parameters of a plurality of peak points, and the peak location parameters include amplitude parameters and position parameters; Calculate the peak interval data of the non-body motion electrocardiogram according to the position parameters of the peak points in the peak positioning data, and obtain the interval stability judgment results of the non-body motion electrocardiogram unit signals according to the interval data between the peak points and the adjacent peak points in the peak interval data and the preset interval threshold, wherein the interval stability judgment results include interval stability results and interval instability results; According to the amplitude parameters of several peak points in the peak positioning data, the amplitude difference data of the non-body movement electrocardiogram unit signal whose interval stability judgment result is the interval stability result is calculated, and according to the amplitude difference parameters between several peak points and adjacent peak points in the amplitude difference data and a preset amplitude difference threshold, the amplitude stability judgment result of the non-body movement electrocardiogram unit signal is obtained, wherein the amplitude stability judgment result includes an amplitude stability result and an amplitude instability result; If the amplitude stability judgment result of the non-body movement electrocardiogram unit signal is an amplitude stability result, the non-body movement electrocardiogram unit signal is classified as a target electrocardiogram unit signal, and other non-body movement electrocardiogram unit signals are classified as non-target electrocardiogram unit signals; A peak location method is adopted to construct peak location data of a plurality of non-target electrocardiogram unit signals, and quality detection indicators of a plurality of non-target electrocardiogram unit signals are obtained according to the peak location data, wherein the quality detection indicators include a location consistency quality indicator, an interval consistency quality indicator, a wave group morphology consistency quality indicator and an amplitude quality indicator; According to the quality detection index, a plurality of target electrocardiogram unit signals are extracted from a plurality of non-target electrocardiogram unit signals, and the plurality of target electrocardiogram unit signals are combined as a signal extraction result of the electrocardiogram signal to be detected.

2. The method for extracting electrocardiogram signals according to claim 1, characterized in that: The time domain features include variance, and the frequency domain features include main frequency, bandwidth, spectrum flatness and spectrum ratio; The method of removing body motion artifacts from the electrocardiogram signal to be detected according to the time domain characteristics and the frequency domain characteristics to obtain a plurality of non-body motion electrocardiogram unit signals corresponding to the electrocardiogram signal to be detected comprises the steps of: According to the variance, main frequency, bandwidth, spectrum flatness, spectrum ratio of several initial electrocardiogram unit signals and a preset threshold construction algorithm, a variance threshold, a main frequency threshold, a bandwidth threshold, a spectrum flatness threshold, and a spectrum ratio threshold are obtained, wherein the threshold construction algorithm is: In the formula, is the variance threshold, is the main frequency threshold, is the bandwidth threshold, is the spectrum flatness threshold, is the spectrum ratio threshold, is the variance, is the main frequency, is the frequency bandwidth, is the spectral flatness, is the spectrum ratio, To find the mean function; The variance, main frequency, bandwidth, spectral flatness and spectrum ratio of several initial electrocardiogram unit signals are compared with the corresponding variance threshold, main frequency threshold, bandwidth threshold, spectral flatness threshold and spectrum ratio threshold respectively to obtain threshold comparison results of several initial electrocardiogram unit signals; based on the threshold comparison results, the initial electrocardiogram unit signals are used as non-body movement electrocardiogram unit signals to obtain several non-body movement electrocardiogram unit signals corresponding to the electrocardiogram signal to be detected.

3. The method for extracting electrocardiogram signals according to claim 1, characterized in that: The peak location data of the non-target electrocardiogram unit signal includes first sub-peak location data and second sub-peak location data, wherein the first sub-peak location data is peak location data obtained by using the Hamilton location algorithm, and the second sub-peak location data is peak location data obtained by using the Engie location algorithm; the first sub-peak location data and the second sub-peak location data both include peak location parameters of a plurality of peak points; The method of obtaining quality detection indicators of a plurality of non-target electrocardiogram unit signals according to the peak location data comprises the following steps: Perform consistency judgment on the position parameters of the peak points under the same position index in the first sub-peak positioning data and the second sub-peak positioning data of the same non-target electrocardiogram unit signal, obtain a number of first peak points of the same position data and a number of second peak points of different position data under the same position index, combine a number of first peak points of the same non-target electrocardiogram unit signal to construct a number of consistent peak positioning data of the non-target electrocardiogram unit signal, and combine a number of second peak points of the same non-target electrocardiogram unit signal to construct a number of inconsistent peak positioning data of the non-target electrocardiogram unit signal; According to the first sub-peak location data, the second sub-peak location data, the consistent peak location data of the non-target electrocardiogram unit signals and the preset first indicator calculation algorithm, the positioning consistency quality indicators of the non-target electrocardiogram unit signals are obtained, wherein the first indicator calculation algorithm is: In the formula, To locate the consistency quality indicator, To locate the peak data, is the first sub-peak location data, Positioning data for the second sub-peak, To find the length function, it is used to indicate the number of peak points; According to the consistent peak location data and the inconsistent peak location data of the same non-target electrocardiogram unit signal, the first sub-peak location data and the second sub-peak location data are fused to construct fused peak location data of a plurality of non-target electrocardiogram unit signals, wherein the fused peak location data includes peak location parameters of a plurality of fused peak points; According to the position parameters of several fused peak points in the fused peak positioning data of several non-target electrocardiogram unit signals, the fused peak interval data of several non-body movement electrocardiogram unit signals are calculated, and according to the fused peak interval data and a preset second indicator calculation algorithm, the interval consistency quality index of several non-target electrocardiogram unit signals is obtained, wherein the second indicator calculation algorithm is: In the formula, is the quality index of the interval consistency, is the interval value of the top 15% in the fused peak interval data, The interval values ​​of the top 85% of the fused peak interval data; According to the amplitude parameters of several fused peak points in the fused peak positioning data of several non-target electrocardiogram unit signals and a preset amplitude threshold, amplitude mutation data of several non-target electrocardiogram unit signals are obtained, and according to the amplitude mutation data and a preset third indicator calculation algorithm, amplitude quality indicators of several non-target electrocardiogram unit signals are obtained, wherein the amplitude mutation data is used to indicate the number of amplitude parameters of fused peak points in a preset window that are greater than the amplitude threshold, and the third indicator calculation algorithm is: In the formula, is the amplitude quality indicator, is the amplitude mutation data; According to the fusion peak location data of the plurality of non-target electrocardiogram unit signals, the wave group area data of the plurality of non-body movement electrocardiogram unit signals are calculated, and according to the wave group area data and a preset fourth indicator calculation algorithm, the wave group morphology consistency quality index of the plurality of non-target electrocardiogram unit signals is obtained, wherein the wave group area data includes the wave group area parameters corresponding to the plurality of fusion peak points, and the fourth indicator calculation algorithm is: In the formula, is the wave group morphology consistency quality index, is the number of fusion peak points, For the i The wave group area parameter corresponding to the fusion peak point, For the j The wave group area parameter corresponding to the fusion peak point.

4. The method for extracting electrocardiogram signals according to claim 3, characterized in that: The step of extracting a plurality of target electrocardiogram unit signals from a plurality of non-target electrocardiogram unit signals according to the quality detection index comprises the steps of: Compare the positioning consistency quality index, the interval consistency quality index, the wave group morphology consistency quality index and the amplitude quality index of the quality detection indicators of the non-target electrocardiogram unit signals with the corresponding quality detection indicator thresholds respectively, and obtain the first quality detection indicator comparison results of the non-target electrocardiogram unit signals, wherein the first quality detection indicator comparison results include the first quality detection indicator less than result; If the first quality detection index of the non-target ECG unit signal is less than the result number is less than or equal to the preset comparison number threshold, the non-target ECG unit signal is used as the target ECG unit signal, and several target ECG unit signals are extracted from several non-target ECG unit signals.

5. The method for extracting electrocardiogram signals according to claim 4, characterized in that: The method of extracting a plurality of target electrocardiogram unit signals from a plurality of non-target electrocardiogram unit signals further comprises the steps of: If the first quality detection index of the non-target electrocardiogram unit signal is less than the result number and greater than the comparison number threshold, construct the template peak positioning data of the non-target electrocardiogram unit signal according to the fused peak positioning data of the non-target electrocardiogram unit signal and the preset first time length, wherein the template peak positioning data includes the peak positioning parameters of a plurality of fused peak points within the preset first time length before and after the first fused peak point in the fused peak positioning data; The fused peak location data of the non-target electrocardiogram unit signal and the template peak location data are subjected to correlation analysis to obtain the correlation coefficients of several fused peak points of the non-target electrocardiogram unit signal. According to the correlation coefficients of several fused peak points of the non-target electrocardiogram unit signal and a preset fifth indicator calculation algorithm, the relevant consistency quality index and the relevant volatility quality index of the non-target electrocardiogram unit signal are obtained, wherein the fifth indicator calculation algorithm is: In the formula, is the relevant consistency quality indicator, For the i The correlation coefficient of the fusion peak points, is the relevant volatility quality indicator; Compare the positioning consistency quality index, the interval consistency quality index, the wave group morphology consistency quality index, the amplitude quality index, the related consistency quality index and the related volatility quality index of the quality detection index of the non-target electrocardiogram unit signal with the corresponding quality detection index thresholds respectively, and obtain a second quality detection index comparison result of the non-target electrocardiogram unit signal, wherein the second quality detection index comparison result includes a second quality detection index less than result; If the second quality detection index of the non-target ECG unit signal is less than the result number is less than or equal to the preset comparison number threshold, the non-target ECG unit signal is used as the target ECG unit signal, and several target ECG unit signals are extracted from several non-target ECG unit signals.

6. The method for extracting electrocardiogram signals according to claim 5, characterized in that: The step of constructing the template peak location data of the non-target electrocardiogram unit signal according to the fused peak location data of the non-target electrocardiogram unit signal also includes the following steps: According to the correlation coefficients of several fused peak points of the non-target electrocardiogram unit signal and a preset correlation coefficient threshold, if the correlation coefficients of all fused peak points are less than or equal to the correlation coefficient threshold, the template peak positioning data of the non-target electrocardiogram unit signal is reconstructed according to the fused peak positioning data of the non-target electrocardiogram unit signal and a preset second time length as the updated template peak positioning data.

7. An electrocardiogram signal extraction device, characterized in that: include: A signal acquisition module, used for obtaining an electrocardiogram signal to be detected, dividing the electrocardiogram signal to be detected into a plurality of initial electrocardiogram unit signals, and extracting time domain features and frequency domain features of the plurality of initial electrocardiogram unit signals; A body motion artifact removal module, used to remove body motion artifacts from the electrocardiogram signal to be detected according to the time domain characteristics and the frequency domain characteristics, and obtain a plurality of non-body motion electrocardiogram unit signals corresponding to the electrocardiogram signal to be detected; A first signal extraction module is used to construct peak location data of a plurality of non-body movement electrocardiogram unit signals by using a fast peak search method, and divide the plurality of non-body movement electrocardiogram unit signals into target electrocardiogram unit signals and non-target electrocardiogram unit signals according to the peak location data; The peak location data includes peak location parameters of a plurality of peak points, and the peak location parameters include amplitude parameters and position parameters; Calculate the peak interval data of the non-body motion electrocardiogram according to the position parameters of the peak points in the peak positioning data, and obtain the interval stability judgment results of the non-body motion electrocardiogram unit signals according to the interval data between the peak points and the adjacent peak points in the peak interval data and the preset interval threshold, wherein the interval stability judgment results include interval stability results and interval instability results; According to the amplitude parameters of several peak points in the peak positioning data, the amplitude difference data of the non-body movement electrocardiogram unit signal whose interval stability judgment result is the interval stability result is calculated, and according to the amplitude difference parameters between several peak points and adjacent peak points in the amplitude difference data and a preset amplitude difference threshold, the amplitude stability judgment result of the non-body movement electrocardiogram unit signal is obtained, wherein the amplitude stability judgment result includes an amplitude stability result and an amplitude instability result; If the amplitude stability judgment result of the non-body movement electrocardiogram unit signal is an amplitude stability result, the non-body movement electrocardiogram unit signal is classified as a target electrocardiogram unit signal, and other non-body movement electrocardiogram unit signals are classified as non-target electrocardiogram unit signals; A quality detection index calculation module, used to construct peak location data of a plurality of non-target electrocardiogram unit signals by using a peak location method, and obtain quality detection indicators of a plurality of non-target electrocardiogram unit signals according to the peak location data, wherein the quality detection indicators include a positioning consistency quality indicator, an interval consistency quality indicator, a wave group morphology consistency quality indicator and an amplitude quality indicator; The second signal extraction module is used to extract a number of target ECG unit signals from a number of non-target ECG unit signals according to the quality detection index, and combine the several target ECG unit signals as the signal extraction result of the ECG signal to be detected.

8. A computer device, characterized in that: The method comprises a processor, a memory and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the electrocardiogram signal extraction method as claimed in any one of claims 1 to 6 when executing the computer program.

9. A storage medium, characterized in that: The storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the electrocardiogram signal extraction method according to any one of claims 1 to 6 are implemented.

Citation Information

Patent Citations

  • Method and system to fully-automatically measure the ST-segment level of electrocardiograms in real-time ecg monitoring

    CN103857330A

  • Multichannel physiological signal-based cardiac feature fusion extraction method

    CN113491522A