Method, device and equipment for detecting T wave position in electrocardiosignal and storage medium

CN116327216BActive Publication Date: 2026-08-11SHENZHEN COMEN MEDICAL INSTR
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-03-22
Publication Date
2026-08-11

AI Technical Summary

Technical Problem

[0005]本申请的主要目的在于提供一种心电信号中T波位置的检测方法、装置、设备及存储介质,可以解决现有技术中的对心电信号中T波的位置检测不准确的技术问题

Benefits of technology

[0035]本申请制定了一种心电信号中T波和T波终点的检测过程与决策方法,通过定位相邻R波之间的P波、Q波和J点的位置,来确定T波位置,可以有效准确的识别出心电信号的特征波的位置,准确检测出T波和T波终点位置,降低检测偏差。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116327216B_ABST
    Figure CN116327216B_ABST
Patent Text Reader

Abstract

This application discloses a method, apparatus, device, and storage medium for detecting the T-wave position in an electrocardiogram (ECG) signal. The method includes: performing interference removal processing on the input raw ECG signal; performing R-wave detection and target R-wave selection on the obtained interference-removed ECG signal, and obtaining the heart rate based on the RR interval of the target R-wave; detecting and determining the Q-wave initiation position and J-point position of the Q-wave between the target R-waves; performing P-wave detection, and if a P-wave exists between the target R-waves, obtaining the P-wave initiation position; if a P-wave exists, determining the detection interval of the T-wave between the target R-waves based on the heart rate, the P-wave initiation position, and the J-point position; if no P-wave exists, determining the detection interval of the T-wave based on the heart rate, the Q-wave initiation position, and the J-point position; and detecting the T-wave endpoint of the T-wave between the target R-waves based on the T-wave detection interval. This application can effectively and accurately detect the T-wave and its position.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of medical technology, and in particular to a method, apparatus, device and storage medium for detecting the position of the T wave in an electrocardiogram signal. Background Technology

[0002] An electrocardiogram (ECG) signal is a physiological voltage signal recorded by electrodes attached to the surface of the body, showing the changes in heart activity over time. ECG signals are characterized by periodicity, weakness, and susceptibility to interference. One heartbeat constitutes a cardiac cycle, and the signal within a cardiac cycle includes characteristic waves such as the P wave, QRS complex, and T wave. These characteristics of the ECG signal can reflect whether the heart is in a normal state, assisting doctors in diagnosing and treating heart diseases. The T wave, in particular, reflects the voltage changes during the repolarization process of the left and right ventricles.

[0003] Because electrocardiogram (ECG) signals are extremely weak voltage signals, they are highly susceptible to interference from other environmental factors. For example, breathing, muscle movement, poor electrode contact, and limb tremors can all significantly interfere with ECG signals. Noise interference in the ECG signal can also significantly affect the detection of characteristic waves; therefore, signal preprocessing through filtering is essential. Furthermore, while the location of characteristic waves within a heartbeat cycle follows a regular pattern, significant deviations can occur due to interference factors and under special circumstances.

[0004] In existing technologies, the selection of the detection range in ECG signal T-wave endpoint detection algorithms is generally based on the average heart rate and an empirical threshold to determine the position of the T-wave endpoint within an ECG cycle. This method is suitable for general signals. However, in specific signals such as those with heart rate fluctuations or large T-wave position deviations, the average heart rate and empirical thresholds are not entirely applicable, leading to detection bias or errors. Therefore, relying on a fixed distance threshold for judgment results in unreliable detection outcomes. Summary of the Invention

[0005] The main objective of this application is to provide a method, apparatus, device, and storage medium for detecting the position of the T wave in an electrocardiogram (ECG) signal, which can solve the technical problem of inaccurate detection of the position of the T wave in an ECG signal in the prior art.

[0006] To achieve the above objectives, the first aspect of this application provides a method for detecting the position of the T wave in an electrocardiogram (ECG) signal, the method comprising:

[0007] The input raw ECG signal is processed to remove interference, resulting in a de-interference ECG signal.

[0008] R-wave detection and target R-wave selection are performed on the interference-free ECG signal, and the heart rate is obtained based on the RR interval of the target R-wave.

[0009] Perform Q-wave initiation detection and J-point detection to determine the Q-wave initiation position and J-point position of the Q-wave between the target R waves;

[0010] Perform P-wave detection; if a P-wave exists between the target R-wave and the P-wave, obtain the starting position of the P-wave.

[0011] If a P wave is present, the detection interval of the T wave located between the target R waves is determined based on the heart rate, the starting position of the P wave, and the position of the J point. If a P wave is not present, the detection interval of the T wave located between the target R waves is determined based on the heart rate, the starting position of the Q wave, and the position of the J point.

[0012] Based on the detection interval of the T wave, the T wave endpoint is detected for T waves located between the target R waves.

[0013] To achieve the above objectives, a second aspect of this application provides a device for detecting the position of the T wave in an electrocardiogram (ECG) signal, the device comprising:

[0014] The interference removal module is used to process the input raw ECG signal to obtain an interference-removed ECG signal.

[0015] The first detection module is used to detect the R wave and select the target R wave from the interference-free ECG signal, and obtain the heart rate based on the RR interval of the target R wave.

[0016] The second detection module is used to perform Q-wave initiation detection and J-point detection to determine the Q-wave initiation position and J-point position of the Q-wave between the target R-waves;

[0017] The third detection module is used to detect P-waves. If a P-wave exists between the target R-wave, the starting position of the P-wave is obtained.

[0018] The detection interval determination module is used to determine the detection interval of the T wave located between the target R waves based on the heart rate, the starting position of the P wave, and the position of the J point if the P wave exists; and to determine the detection interval of the T wave located between the target R waves based on the heart rate, the starting position of the Q wave, and the position of the J point if the P wave does not exist.

[0019] The endpoint determination module is used to detect the endpoint of T-waves located between the target R-waves, based on the detection interval of the T-wave.

[0020] To achieve the above objectives, a third aspect of this application provides a computer-readable storage medium storing a computer program, which, when executed by a processor, causes the processor to perform the following steps:

[0021] The input raw ECG signal is processed to remove interference, resulting in a de-interference ECG signal.

[0022] R-wave detection and target R-wave selection are performed on the interference-free ECG signal, and the heart rate is obtained based on the RR interval of the target R-wave.

[0023] Perform Q-wave initiation detection and J-point detection to determine the Q-wave initiation position and J-point position of the Q-wave between the target R waves;

[0024] Perform P-wave detection; if a P-wave exists between the target R-wave and the P-wave, obtain the starting position of the P-wave.

[0025] If a P wave is present, the detection interval of the T wave located between the target R waves is determined based on the heart rate, the starting position of the P wave, and the position of the J point. If a P wave is not present, the detection interval of the T wave located between the target R waves is determined based on the heart rate, the starting position of the Q wave, and the position of the J point.

[0026] Based on the detection interval of the T wave, the T wave endpoint is detected for T waves located between the target R waves.

[0027] To achieve the above objectives, a fourth aspect of this application provides a computer device, including a memory and a processor. The memory stores a computer program, and when the computer program is executed by the processor, the processor performs the following steps:

[0028] The input raw ECG signal is processed to remove interference, resulting in a de-interference ECG signal.

[0029] R-wave detection and target R-wave selection are performed on the interference-free ECG signal, and the heart rate is obtained based on the RR interval of the target R-wave.

[0030] Perform Q-wave initiation detection and J-point detection to determine the Q-wave initiation position and J-point position of the Q-wave between the target R waves;

[0031] Perform P-wave detection; if a P-wave exists between the target R-wave and the P-wave, obtain the starting position of the P-wave.

[0032] If a P wave is present, the detection interval of the T wave located between the target R waves is determined based on the heart rate, the starting position of the P wave, and the position of the J point. If a P wave is not present, the detection interval of the T wave located between the target R waves is determined based on the heart rate, the starting position of the Q wave, and the position of the J point.

[0033] Based on the detection interval of the T wave, the T wave endpoint is detected for T waves located between the target R waves.

[0034] The embodiments of this application have the following beneficial effects:

[0035] This application establishes a detection process and decision-making method for the T wave and T wave endpoint in electrocardiogram (ECG) signals. By locating the positions of the P wave, Q wave, and J point between adjacent R waves, the T wave position can be determined. This method can effectively and accurately identify the position of characteristic waves in ECG signals, accurately detect the T wave and T wave endpoint positions, and reduce detection bias. Attached Figure Description

[0036] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0037] in:

[0038] Figure 1 This is a flowchart of the method for detecting the T-wave position in an electrocardiogram signal in an embodiment of this application;

[0039] Figure 2 This is a structural block diagram of the interference removal process in the embodiments of this application;

[0040] Figure 3 This is a schematic diagram of the morphological filtering module in an embodiment of this application;

[0041] Figure 4 This is a structural block diagram of the device for detecting the T-wave position in an electrocardiogram signal in an embodiment of this application;

[0042] Figure 5 This is a structural block diagram of the computer device in the embodiments of this application. Detailed Implementation

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

[0044] like Figure 1 As shown, in one embodiment, a method for detecting the T-wave position in an electrocardiogram (ECG) signal is provided. This method can be applied to both terminals and servers; this embodiment uses a terminal application as an example. The method for detecting the T-wave position in an ECG signal specifically includes the following steps:

[0045] S100: Performs interference removal processing on the input raw ECG signal to obtain an interference-removed ECG signal.

[0046] Specifically, the original electrocardiogram (ECG) signal is the digitized ECG signal. ECG signals are periodic, consisting of multiple heartbeat cycles (one heartbeat is one heartbeat cycle). Each heartbeat cycle mainly includes the P wave, QRS complex, J point, ST segment, T wave, etc.

[0047] The P wave represents the electrical potential change during atrial depolarization; that is, the P wave represents atrial excitation, with the first half representing right atrial excitation and the second half representing left atrial excitation. The P wave duration is 0.12 seconds and the height is 0.25 mV. When the atria enlarge or conduction between the two atria becomes abnormal, the P wave may appear as a tall, peaked or biphasic P wave.

[0048] The QRS complex primarily represents the electrical potential changes during ventricular depolarization. Specifically, the impulse travels downwards through the His bundle and the left and right bundle branches, simultaneously exciting both ventricles to form the QRS complex. The QRS complex represents ventricular depolarization, with an activation duration of less than 0.11 seconds. When conduction block of the left and right bundle branches, ventricular enlargement, or hypertrophy occurs, the QRS complex widens, becomes distorted, and its duration prolongs. In normal adults, the QRS duration should be less than 0.11 seconds.

[0049] Point J is the intersection of the end of the QRS complex and the beginning of the ST segment. It indicates that all ventricular myocytes have completed depolarization.

[0050] The ST segment, or ST segment, is the line segment between the midpoint of the QRS complex and the beginning of the T wave. It represents the slow negative polarization process of the ventricles, specifically the period after complete depolarization of the ventricular myocardium and before repolarization begins. During this time, all parts of the ventricular myocardium are in a depolarizing state, and there is no potential difference between cells. Therefore, under normal circumstances, the ST segment should be on an isoelectric line. When ischemia or necrosis occurs in a part of the myocardium, a potential difference still exists after the ventricles have completed depolarization, which manifests as ST segment deviation on the electrocardiogram. A normal ST segment is mostly isoelectric, but sometimes a slight deviation may be observed.

[0051] The T wave represents the potential changes during rapid ventricular repolarization; that is, the T wave represents ventricular repolarization. In leads where the main QRS wave is upward, the T wave should be in the same direction as the main QRS wave. Changes in the T wave on an electrocardiogram are affected by various factors. For example, myocardial ischemia can manifest as a flattened and inverted T wave. A tall T wave can be seen in hyperkalemia, the hyperacute phase of acute myocardial infarction, etc. Under normal circumstances, the direction of the T wave is mostly consistent with the direction of the main QRS wave, and the amplitude, except for leads III, aVL, aVF, and V1-V3, should generally not be less than 1 / 10 of the R wave in the same lead. The QT interval is the distance from the beginning of the QRS complex to the end of the T wave, representing the time required for the entire process of ventricular depolarization and repolarization. The traditional upper limit of normal QTC is set at 0.44s; exceeding this limit is considered prolonged.

[0052] Of course, the ECG waveform also includes the PR interval (PR segment) between the P wave and the QRS complex. The PR interval refers to the time from the beginning of the P wave to the beginning of the QRS complex, representing the time from the start of atrial depolarization to the start of ventricular depolarization. It represents the time required for the excitation generated by the sinoatrial node to travel through the atrium, atrioventricular junction, and atrioventricular bundle to reach the ventricle and cause ventricular myocardial excitation; hence, it is also called atrioventricular conduction time. A normal PR interval is 0.12–0.20 seconds. When conduction from the atrium to the ventricle is blocked, it manifests as a prolonged PR interval or the disappearance of the ventricular wave after the P wave.

[0053] Interference removal processing specifically includes, but is not limited to, noise reduction, baseline offset removal, and post-denoising smoothing. Interference removal processing can effectively reduce the interference of noise and other factors on the determination of T-wave position, making position detection more accurate.

[0054] S200: Performs R-wave detection and target R-wave selection on the interference-free ECG signal, and obtains the heart rate based on the RR interval of the target R-wave.

[0055] Specifically, multiple consecutive R waves are detected from the de-interference ECG signal sequence. A target R wave is selected from these target R waves, consisting of two consecutive R waves. The RR interval between these two target R waves is then calculated. Heart rate represents the number of heartbeats per minute, and the RR interval is the length of one heartbeat cycle. Therefore, heart rate = 60 / RR interval. The heart rate can be calculated based on the RR interval.

[0056] S300: Perform Q-wave initiation detection and J-point detection to determine the Q-wave initiation position and J-point position of the Q-wave between the target R-waves.

[0057] Specifically, each target R wave corresponds to a QRS complex, two target R waves correspond to two adjacent heartbeat cycles, and the heartbeat cycle signal of each heartbeat cycle includes a QRS complex, J point, ST measurement point, T wave, and may also include a P wave before the QRS complex.

[0058] Therefore, the two target R waves correspond to the following two heartbeat cycle signals:

[0059] P wave 1 (possibly present), QRS complex 1, J point 1, ST measurement point 1, T wave 1, P wave 2 (possibly present), QRS complex 2, J point 2, ST measurement point 2, T wave 2.

[0060] Therefore, it can be seen that there are J points and T waves between two consecutive QRS groups, and there may also be P waves.

[0061] By detecting the Q wave and J point corresponding to the two target R waves, the starting position of the Q wave (e.g., the Q wave in the QRS group 2 mentioned above) located between the two target R waves, i.e., its coordinates in the waveform, and the position of the J point (e.g., J point 1 mentioned above) located between the two target R waves can be determined.

[0062] S400: Perform P-wave detection. If a P-wave exists between the target R-wave and the target R-wave, obtain the starting position of the P-wave.

[0063] Specifically, a P wave may or may not exist between two QRS groups. If a P wave exists, its starting point is determined. For example, if a P wave 2 exists between QRS group 1 and QRS group 2, its starting point is determined.

[0064] S500: If a P wave is present, the detection interval of the T wave between the target R waves is determined based on the heart rate, the starting position of the P wave, and the position of the J point. If a P wave is not present, the detection interval of the T wave between the target R waves is determined based on the heart rate, the starting position of the Q wave, and the position of the J point.

[0065] Specifically, this embodiment is used to determine the detection interval of the T wave located between two target R waves (e.g., T wave 1 mentioned above). For example, if P wave 2 exists, then T wave 1 is located between point J 1 and P wave 2. Based on the heart rate, the starting position of P wave 2, and the position of point J 1, the detection interval of T wave 1 can be further accurately located, reducing the search range.

[0066] If P wave 2 is absent, then the Q wave in QRS complex 2 is closest to T wave 1, and T wave 1 is located between point J 1 and the Q wave in QRS complex 2. Based on heart rate, the starting position of the Q wave in QRS complex 2, and the position of point J 1, the detection interval of T wave 1 can be further accurately located, reducing the search range.

[0067] S600: Based on the detection interval of the T-wave, it performs T-wave endpoint detection for T-waves located between the target R-waves.

[0068] Specifically, after determining the detection interval of the T wave (e.g., T wave 1) between the target R waves, the endpoint of the T wave is detected to determine the endpoint of the T wave, which is located within the detection interval of the T wave.

[0069] This embodiment determines the position of the T wave between two consecutive QRS complexes by locating the starting positions of the P wave, J point, and Q wave, as well as the heart rate. In other words, by locating the positions of the P wave, Q wave, and J point between adjacent R waves, the T wave position is determined. This method is unaffected by heart rate fluctuations, large T wave position deviations, or empirical values. It can effectively and accurately identify the positions of characteristic waves in the ECG signal, accurately detect the T wave and its endpoint, reduce detection errors, and has a wide range of applications.

[0070] In one embodiment, step S200 specifically includes:

[0071] R-wave detection was performed on the interference-free ECG signal to obtain the R-wave position of each segment, thus obtaining a set of R-wave positions.

[0072] Based on the R-wave position, obtain the score for each R-wave segment;

[0073] Calculate the sum of scores for two consecutive R-wave segments, and select the two consecutive R-wave segments with the lowest sum of scores as the target R-waves;

[0074] Calculate the RR interval of the target R wave, and obtain the heart rate based on the RR interval.

[0075] Specifically, by performing R-wave detection on the interference-free ECG signal, multiple R-waves can be detected, and the R-wave position of each R-wave can be obtained. The R-wave position is the interval occupied by the R-wave in the waveform.

[0076] In one embodiment, the score for each R-wave segment is obtained based on the R-wave position, and the specific steps are as follows:

[0077] Based on the position of the R-wave, a waveform including the R-wave for a preset time length is extracted to obtain the extracted waveform;

[0078] The truncated waveform is then subjected to mean filtering;

[0079] The difference between the truncated waveform before and after filtering is calculated, and the mean of the resulting difference sequence is obtained to get the score of the R wave.

[0080] Specifically, the waveform of any R-wave, including the R-wave itself, is captured for a preset time length. This preset time length includes the interval occupied by the R-wave and can be configured according to actual conditions; for example, it can be 1 second. The capture process can be to capture the waveform including the R-wave and the time preceding it, or to capture the waveform including the R-wave and the time following it, or to capture the waveform including the R-wave and the time preceding and following it, totaling a preset time length.

[0081] The truncated waveform is subjected to mean filtering. The difference between the truncated waveform before and after filtering is calculated. The sum of the difference sequences is then calculated and the mean is obtained to obtain the score of the R wave.

[0082] A lower score indicates a smaller difference in waveforms before and after filtering, and a better signal.

[0083] Sum the scores of any two consecutive R waves, and select the two consecutive R waves with the lowest sum of scores as the target R waves.

[0084] Choosing the two consecutive R-waves with the lowest sum of scores is equivalent to choosing two consecutive R-waves with good waveforms.

[0085] The S300 specifically includes:

[0086] The curve integral method is used to detect the Q-wave initiation and J-point of the two QRS groups corresponding to the target R-wave, thereby determining the Q-wave initiation position and J-point position of the Q-wave between the two QRS groups.

[0087] In one embodiment, S400 specifically includes:

[0088] The signal is integrated within a first preset time range from the Q wave initiation position between two QRS groups to point J, and multiple first integration results are obtained.

[0089] Obtain the peak amplitude of the first target interval corresponding to the maximum absolute value of the first integral in the first integral result;

[0090] If the peak amplitude exceeds the product of the R-wave amplitude of the next target R-wave and the first percentage, it is determined that there is a P-wave between the target R-waves. The peak of the first target interval is taken as the peak of the P-wave in the next QRS group. The starting position of the P-wave is determined based on the peak of the P-wave, where the first percentage is less than 1.

[0091] Specifically, the signal can be integrated within a first preset time range from the Q-wave starting point of the next QRS group to point J using the window integration method.

[0092] When using the window integral method, the window width (i.e., the length or width of the sliding window) is set to a first preset window width, such as 120ms, 130ms, etc., without limitation. The length of each slide of the sliding window is set to a first preset length, such as 1ms, 2ms, etc., without limitation.

[0093] The sliding window starts from the Q-wave start position of the Q-wave between two QRS groups and slides towards point J between the two QRS groups by a first set length. Each time the sliding window slides, the waveform signal within the sliding window is integrated to obtain a corresponding first integration result, until the sliding window slides to the target point a first set time away from the Q-wave start position of the Q-wave between the two QRS groups.

[0094] The first preset duration can be set according to the actual situation, for example, it can be set to 200ms, etc., and is not limited to this.

[0095] Select the interval corresponding to the maximum absolute value of the integral from multiple first integral results as the first target interval. This first target interval is a segment of the waveform of the interference-reducing ECG signal. Obtain the peak amplitude of this first target interval.

[0096] If the peak amplitude exceeds the product of the R-wave amplitude of the subsequent target R-wave and the first percentage, then a P-wave is determined to exist between the two target R-waves. For example, a P-wave 2 is determined to exist between QRS complex 1 and QRS complex 2 mentioned above.

[0097] The first percentage is less than 1, for example, the first percentage is 1 / 15. The next target R wave refers to the R wave that is later in time in the waveform of two adjacent target R waves, such as the R wave in QRS group 2 above.

[0098] The peak of the first target interval is taken as the peak of the P wave in the next QRS complex, and the starting position of the P wave is determined based on the peak of the P wave. For example, the peak of the first target interval is taken as the peak of the aforementioned P wave 2, and the starting position of P wave 2 is determined based on the peak of P wave 2.

[0099] The next QRS group refers to the QRS group that is later in time than the waveform of two adjacent QRS groups. For example, QRS group 2 in the above example is the next QRS group.

[0100] This embodiment accurately and effectively determines whether a P-wave exists between two adjacent R-waves through signal integration, and determines the peak and starting point of the P-wave.

[0101] In one embodiment, step S600 specifically includes:

[0102] The ST measurement point location is determined based on heart rate and J point location, and the ST measurement point location is used as the detection starting point for the T wave located between the target R waves;

[0103] If there is a P wave between the target R waves, the starting position of the P wave is taken as the detection endpoint of the T wave between the target R waves. If there is no P wave between the target R waves, the position located before the starting position of the Q wave and at a distance of the second preset time from the starting position of the Q wave is taken as the detection endpoint of the T wave between the target R waves.

[0104] The interval between the detection start point and the detection end point is taken as the detection interval of the T-wave. The signal is integrated within the detection interval of the T-wave to obtain multiple second integral results.

[0105] The second target interval corresponding to the maximum absolute value of the second integral result is taken as the T-wave position between the target R waves;

[0106] Obtain the peak position and peak amplitude of the T-wave in the T-wave location;

[0107] Starting from the peak of the T-wave, a predetermined number of target wave points are determined backward. The target wave point farthest from the peak of the T-wave is determined as the endpoint of the T-wave located between the target R-waves. The amplitude of each target wave point is less than the product of the peak amplitude of the T-wave and a second predetermined percentage.

[0108] Specifically, there is an ST measurement point between the J point and the T wave in a heartbeat cycle signal, therefore, there is an ST measurement point between the two target R waves (e.g., ST measurement point 1 mentioned above).

[0109] The location of the ST measurement point between the target R waves can be determined based on the heart rate and J point position between the two target R waves.

[0110] The ST measurement point is closer to the T wave located between the target R waves, thus the search range for the T wave can be further narrowed.

[0111] If there is a P-wave between two target R-waves, then the P-wave is closer to the T-wave located between the target R-waves. Therefore, by taking the starting point of the P-wave as the detection endpoint of the T-wave located between the target R-waves, the search range of the T-wave can be further narrowed.

[0112] If there is no P wave between two target R waves, then the Q wave located between the two target R waves is closer to the T wave located between the target R waves. Therefore, by taking the position before the Q wave initiation position of the Q wave located between the two target R waves and at a distance of a second preset time from the Q wave initiation position as the detection endpoint of the T wave located between the target R waves, the search range of the T wave can be further narrowed.

[0113] The position at the second preset time from the Q wave origin specifically refers to the position at the second preset time from the Q wave origin in the direction of the T wave located between the target R waves.

[0114] The second preset duration can be, for example, 200ms, etc. This application does not impose any restrictions on this.

[0115] The detection range of the T wave can be determined based on the detection endpoint and detection start point.

[0116] In the detection range of the T-wave, the signal can be integrated using the window integration method. At this time, the window width (i.e., the length or width of the sliding window) is set to a second preset window width, such as 110ms, 120ms, etc., without limitation. The length of each slide of the sliding window is set to a second preset length, such as 1ms, 2ms, etc., without limitation.

[0117] The sliding window starts from the detection start point of the T-wave detection range and slides towards the detection end point by a second predetermined length. Each time the sliding window slides, the waveform signal within the sliding window is integrated to obtain a corresponding second integral result, until the sliding window slides to the detection end point.

[0118] From multiple second integral results, the interval corresponding to the largest absolute value of the integral is selected as the second target interval, and this second target interval is taken as the T wave position located between the target R waves. This second target interval is a segment of the waveform of the de-interference ECG signal. The peak amplitude and peak position of this second target interval are obtained as the peak amplitude and peak position of the T wave.

[0119] Starting from the peak of the T-wave, a predetermined number of target wave points are determined in the direction of the next target R-wave. The amplitude of each target wave point is less than the product of the peak amplitude of the T-wave and a second predetermined percentage.

[0120] The second percentage is less than 1, for example, it can be 1 / 10. The preset number of target wave points can be, for example, 5 consecutive target wave points. The amplitude of each target wave point is less than the product of the peak amplitude of the T wave and the second preset percentage.

[0121] The target wave point furthest from the crest of the T wave is defined as the endpoint of the T wave located between the target R waves.

[0122] This embodiment determines the detection start and end points of the T wave by using the Q wave initiation point, P wave initiation point, heart rate, and J point position. It then determines the peak position and peak amplitude of the T wave by integrating the detection interval, and finally determines the T wave end point based on the peak position and peak amplitude, which is accurate and effective.

[0123] In one embodiment, determining the ST measurement point location based on heart rate and J point location includes:

[0124] Determine the heart rate range into which the heart rate falls;

[0125] Determine the ST segment length corresponding to the heart rate range;

[0126] The location of the ST measurement point is obtained by summing the position of point J and the length of segment ST.

[0127] Specifically, based on the current heart rate signal and the position of the J point between the target R waves, the ST measurement point position STloc between the target R waves can be determined, and the ST measurement point position STloc is used as the starting point for detecting the T wave.

[0128] Where STloc is the position of point J plus the length of the ST segment, and the length of the ST segment is the X value. The X value can be 60ms, 64ms, 72ms, and 80ms, which correspond to heart rate ranges of >120 beats / min, 90~120 beats / min, 60~90 beats / min, and <60 beats / min, respectively.

[0129] Therefore, based on the heart rate corresponding to the target R wave, the heart rate range within which the heart rate falls can be determined, and the corresponding ST segment length (X value) can be determined based on the heart rate range. The sum of the J point location between the target R waves and the ST segment length located between the target R waves yields the ST measurement point location.

[0130] In one embodiment, the input raw electrocardiogram (ECG) signal is subjected to interference removal processing to obtain an interference-removed ECG signal, including:

[0131] The baseline drift of the input raw electrocardiogram signal is removed by morphological filtering to obtain the first signal;

[0132] The high-frequency noise of the original electrocardiogram signal is removed by wavelet transform to obtain the second signal;

[0133] The first signal and the second signal are fused to obtain the adaptive reference signal;

[0134] Adaptive filtering is performed on the original ECG signal and the adaptive reference signal to obtain the interference-free ECG signal.

[0135] Specifically, Figure 2 This is a structural block diagram of the interference removal process in the embodiments of this application; see reference. Figure 2 The raw electrocardiogram (ECG) signals are input into the morphological filtering module, wavelet transform module, and adaptive filter of the interference removal module, respectively.

[0136] The morphological filtering module is used to remove baseline drift signals from the original electrocardiogram signal to obtain the baseline-drift-free first signal.

[0137] The wavelet transform module is used to remove high-frequency noise from the original electrocardiogram signal, resulting in a second signal with some high-frequency noise removed.

[0138] The first and second signals are fused (accumulated) to obtain the adaptive reference signal.

[0139] The original ECG signal and the adaptive reference signal are input into the adaptive filter, and the resulting filtered ECG signal is the interference-removed signal.

[0140] This embodiment uses morphological baseline drift removal, wavelet transform to remove high-frequency noise, and adaptive filtering to perform interference removal processing on the original ECG signal, resulting in an interference-free ECG signal. This reduces the interference of baseline drift and noise, ensuring the accuracy and effectiveness of subsequent T-wave position determination.

[0141] In one embodiment, baseline drift of the input raw electrocardiogram signal is removed by morphological filtering to obtain a first signal, including:

[0142] Obtain the baseline drift signal of the raw electrocardiogram signal;

[0143] The difference between the original ECG signal and the baseline drift signal is used to obtain the baseline-de-drift ECG signal;

[0144] The baseline-drifted ECG signal was denoised to obtain the first signal.

[0145] Specifically, Figure 3 This is a schematic diagram of the morphological filtering module in one embodiment; Reference Figure 3 The morphological filtering module 1 includes a first operation module 11, a difference module 13, and a second operation module 12.

[0146] In this embodiment, the input signal of the morphological filtering module 1 is the raw electrocardiogram (ECG) signal. The raw ECG signal is input to the first arithmetic module 11 and the difference module 13, respectively.

[0147] The first arithmetic module 11 includes a first arithmetic combination module, a second arithmetic combination module, and a fusion module arranged in parallel. The output terminal of the opening operation in the first arithmetic combination module is connected to the input terminal of the closing operation in the first arithmetic combination module, and the input terminal of the opening operation is input with the original electrocardiogram (ECG) signal. The output terminal of the closing operation in the second arithmetic combination module is connected to the input terminal of the opening operation in the second arithmetic combination module, and the input terminal of the closing operation is input with the original ECG signal. The fourth signal output from the closing operation in the first arithmetic combination module and the fifth signal output from the opening operation in the second arithmetic combination module are input to the fusion module for fusion to obtain the baseline drift signal of the original ECG signal.

[0148] The fusion module inputs the baseline drift signal to the difference module 13. The difference module 13 subtracts the input baseline drift signal from the original ECG signal to obtain the baseline-free ECG signal.

[0149] The difference module 13 inputs the baseline-drift ECG signal to the second arithmetic module 12. The second arithmetic module 12 performs noise reduction processing on the baseline-drift ECG signal, and the resulting output signal is the first signal.

[0150] The second operation module 12 includes a third operation combination module, a fourth operation combination module, and a fusion module arranged in parallel. The output terminal of the opening operation in the third operation combination module is connected to the input terminal of the closing operation in the third operation combination module, and the input terminal of the opening operation receives the baseline drift-reduced ECG signal. The output terminal of the closing operation in the fourth operation combination module is connected to the input terminal of the opening operation in the fourth operation combination module, and the input terminal of the closing operation receives the baseline drift-reduced ECG signal. The sixth signal output from the closing operation in the third operation combination module and the seventh signal output from the opening operation in the fourth operation combination module are input to the fusion module for fusion to obtain the first signal.

[0151] This embodiment achieves baseline drift removal and partial noise reduction of the original electrocardiogram signal.

[0152] refer to Figure 4 This application also provides a device for detecting the position of the T wave in an electrocardiogram signal, the device comprising:

[0153] The interference removal module 100 is used to perform interference removal processing on the input raw ECG signal to obtain an interference-removed ECG signal;

[0154] The first detection module 200 is used to detect R waves and select target R waves from the interference-free ECG signal, and obtain the heart rate based on the RR interval of the target R wave.

[0155] The second detection module 300 is used to perform Q-wave initiation detection and J-point detection to determine the Q-wave initiation position and J-point position corresponding to the target R-wave.

[0156] The third detection module 400 is used to detect P-waves. If a P-wave is present, the starting position of the P-wave is obtained.

[0157] The detection interval determination module 500 is used to determine the detection interval of the T wave based on heart rate, the starting position of the P wave, and the position of the J point if the P wave is present, and to determine the detection interval of the T wave based on heart rate, the starting position of the Q wave, and the position of the J point if the P wave is not present.

[0158] The endpoint determination module 600 is used to perform T-wave endpoint detection based on the detection interval of the T-wave.

[0159] Figure 5 An internal structural diagram of a computer device in one embodiment is shown. This computer device can specifically be a terminal or a server. Figure 5As shown, the computer device includes a processor, memory, and network interface connected via a system bus. The memory includes a non-volatile storage medium and internal memory. The non-volatile storage medium stores an operating system and may also store a computer program. When executed by the processor, this computer program causes the processor to perform the steps in the above-described method embodiments. The internal memory may also store a computer program, which, when executed by the processor, causes the processor to perform the steps in the above-described method embodiments. Those skilled in the art will understand that... Figure 5 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.

[0160] In one embodiment, a computer device is provided, including a memory and a processor, the memory storing a computer program that, when executed by the processor, causes the processor to perform the following steps:

[0161] The input raw ECG signal is processed to remove interference, resulting in a de-interference ECG signal.

[0162] R-wave detection and target R-wave selection are performed on the interference-free ECG signal, and the heart rate is obtained based on the RR interval of the target R-wave.

[0163] Perform Q-wave initiation detection and J-point detection to determine the Q-wave initiation position and J-point position of the Q-wave between the target R waves;

[0164] Perform P-wave detection; if a P-wave exists between the target R-wave and the P-wave, obtain the starting position of the P-wave.

[0165] If a P wave is present, the detection interval of the T wave located between the target R waves is determined based on the heart rate, the starting position of the P wave, and the position of the J point. If a P wave is not present, the detection interval of the T wave located between the target R waves is determined based on the heart rate, the starting position of the Q wave, and the position of the J point.

[0166] Based on the detection interval of the T wave, the T wave endpoint is detected for T waves located between the target R waves.

[0167] In one embodiment, a computer-readable storage medium is provided storing a computer program that, when executed by a processor, causes the processor to perform the following steps:

[0168] The input raw ECG signal is processed to remove interference, resulting in a de-interference ECG signal.

[0169] R-wave detection and target R-wave selection are performed on the interference-free ECG signal, and the heart rate is obtained based on the RR interval of the target R-wave.

[0170] Perform Q-wave initiation detection and J-point detection to determine the Q-wave initiation position and J-point position of the Q-wave between the target R waves;

[0171] Perform P-wave detection; if a P-wave exists between the target R-wave and the P-wave, obtain the starting position of the P-wave.

[0172] If a P wave is present, the detection interval of the T wave located between the target R waves is determined based on the heart rate, the starting position of the P wave, and the position of the J point. If a P wave is not present, the detection interval of the T wave located between the target R waves is determined based on the heart rate, the starting position of the Q wave, and the position of the J point.

[0173] Based on the detection interval of the T wave, the T wave endpoint is detected for T waves located between the target R waves.

[0174] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, storage, databases, or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), RAMbus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and RAMbus dynamic RAM (RDRAM), etc.

[0175] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0176] The above embodiments merely illustrate several implementation methods of this application, and while the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this patent application should be determined by the appended claims.

Claims

1. A method for detecting a T-wave position in an electrocardiosignal, characterized in that The method includes: The input raw ECG signal is processed to remove interference, resulting in a de-interference ECG signal. R-wave detection and target R-wave selection are performed on the interference-free ECG signal, and the heart rate is obtained based on the RR interval of the target R-wave, wherein the target R-wave is two consecutive R-waves; Perform Q-wave initiation detection and J-point detection to determine the Q-wave initiation position and J-point position of the Q-wave between the target R waves; Perform P-wave detection; if a P-wave exists between the target R-wave, then obtain the starting position of the P-wave. If a P wave is present, the detection interval of the T wave located between the target R waves is determined based on the heart rate, the starting position of the P wave, and the position of the J point. If a P wave is not present, the detection interval of the T wave located between the target R waves is determined based on the heart rate, the starting position of the Q wave, and the position of the J point. Based on the detection interval of the T wave, the T wave endpoint is detected for the T wave located between the target R waves; Specifically, if a P wave exists, the detection interval for the T wave located between the target R waves is determined based on the heart rate, the P wave origin position, and the J point position. If a P wave does not exist, the detection interval for the T wave located between the target R waves is determined based on the heart rate, the Q wave origin position, and the J point position. This includes: The ST measurement point location is determined based on the heart rate and J point location, and the ST measurement point location is used as the detection starting point for the T wave located between the target R waves; If there is a P wave between the target R waves, the starting position of the P wave is taken as the detection endpoint of the T wave between the target R waves. If there is no P wave between the target R waves, the position located before the starting position of the Q wave and at a distance of a second preset time from the starting position of the Q wave is taken as the detection endpoint of the T wave between the target R waves. The interval between the detection start point and the detection end point is defined as the detection interval of the T wave.

2. The method of claim 1, wherein, The step of detecting and selecting the target R wave from the interference-free ECG signal, and obtaining the heart rate based on the RR interval of the target R wave, includes: R-wave detection is performed on the interference-free ECG signal to obtain the R-wave position of each R-wave segment, thus obtaining a set of R-wave positions; Based on the R-wave position, obtain the score for each R-wave segment; Calculate the sum of scores for two consecutive R-wave segments, and select the two consecutive R-wave segments with the lowest sum of scores as the target R-waves; Calculate the RR interval of the target R wave, and obtain the heart rate based on the RR interval; The step of performing Q-wave initiation detection and J-point detection to determine the Q-wave initiation position and J-point position of the Q-wave between the target R waves includes: The Q-wave initiation point and J-point are detected for the two QRS groups corresponding to the target R-wave using the curve integral method, thereby determining the Q-wave initiation point and J-point position of the Q-wave between the two QRS groups.

3. The method of claim 2, wherein, The step of obtaining a score for each R-wave segment based on the R-wave position includes: Based on the position of the R-wave, a waveform including the R-wave for a preset time length is extracted to obtain the extracted waveform; The truncated waveform is then subjected to mean filtering; The difference between the truncated waveform before and after filtering is calculated, and the mean of the resulting difference sequence is obtained to get the score of the R wave.

4. The method of claim 2, wherein, The step of P-wave detection, if a P-wave exists between the target R-wave and the P-wave origin position, includes: The signal within a first preset time range from the Q-wave initiation position between the two QRS groups to point J is integrated to obtain multiple first integration results; Obtain the peak amplitude of the first target interval corresponding to the maximum absolute value of the first integral result; If the peak amplitude exceeds the product of the R-wave amplitude of the next target R-wave and the first percentage, it is determined that there is a P-wave between the target R-waves. The peak of the first target interval is taken as the peak of the P-wave in the next QRS complex. The starting position of the P-wave is determined based on the peak of the P-wave, wherein the first percentage is less than 1.

5. The method of claim 2, wherein, The detection of the T-wave endpoint based on the T-wave detection interval, for T-waves located between the target R-waves, includes: The signal is integrated within the detection range of the T-wave to obtain multiple second integral results; The second target interval corresponding to the maximum absolute value of the second integral result is taken as the T-wave position located between the target R waves; Obtain the peak position and peak amplitude of the T-wave at the specified T-wave position; Starting from the peak position of the T-wave, a predetermined number of target wave points are determined backwards. The target wave point farthest from the peak position of the T-wave is determined as the endpoint of the T-wave located between the target R-waves. The amplitude of each target wave point is less than the product of the peak amplitude of the T-wave and a second predetermined percentage.

6. The method of claim 5, wherein, Determining the ST measurement point location based on the heart rate and J point location includes: Determine the heart rate range into which the heart rate falls; Determine the ST segment length corresponding to the heart rate range; The location of the ST measurement point is obtained by summing the position of point J and the length of segment ST.

7. The method of claim 1, wherein, The process of removing interference from the input raw ECG signal to obtain a de-interference ECG signal includes: The baseline drift of the input raw electrocardiogram signal is removed by morphological filtering to obtain the first signal; The high-frequency noise of the original electrocardiogram signal is removed by wavelet transform to obtain the second signal; The first signal and the second signal are fused to obtain an adaptive reference signal; The original ECG signal and the adaptive reference signal are subjected to adaptive filtering to obtain a de-interference ECG signal.

8. An apparatus for detecting a T-wave position in an electrocardiosignal, characterized in that The device includes: The interference removal module is used to process the input raw ECG signal to obtain an interference-removed ECG signal. The first detection module is used to detect the R wave and select the target R wave in the interference-free ECG signal, and obtain the heart rate based on the RR interval of the target R wave. The second detection module is used to perform Q-wave initiation detection and J-point detection to determine the Q-wave initiation position and J-point position of the Q-wave between the target R-waves; The third detection module is used to perform P-wave detection. If a P-wave exists between the target R-wave, the starting position of the P-wave is obtained. The detection interval determination module is used to determine the detection interval of the T wave located between the target R waves based on the heart rate, the starting position of the P wave, and the position of the J point if the P wave exists; and to determine the detection interval of the T wave located between the target R waves based on the heart rate, the starting position of the Q wave, and the position of the J point if the P wave does not exist. The endpoint determination module is used to perform T-wave endpoint detection on T-waves located between the target R-waves, based on the detection interval of the T-wave.

9. A computer readable storage medium storing a computer program, characterized in that, When the computer program is executed by a processor, it causes the processor to perform the steps of the method as described in any one of claims 1 to 7. 10.A computer device, comprising a memory and a processor, and characterized in that, The memory stores a computer program that, when executed by the processor, causes the processor to perform the steps of the method as described in any one of claims 1 to 7.

Citation Information

Patent Citations

  • Classification of ST waves and ST segment type

    US11134882B1

  • Three dimensional vector cardiograph and method for detecting and monitoring ischemic events

    US20040111021A1