Electrocardiogram signal processing method, device, equipment and storage medium
By intelligently classifying ECG signals and analyzing voltage values, the problem of ST segment abnormality detection being time-consuming, labor-intensive, and prone to missed detection is solved, and efficient and accurate ST segment abnormality detection is achieved.
Patent Information
- Application Number
- CN202210778843.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-06-30
- Publication Date
- 2025-09-16
- Estimated Expiration
- 2042-06-30
AI Technical Summary
In the prior art, detecting ST segment abnormalities in long-term electrocardiographic signals is time-consuming and labor-intensive and is prone to missed detections.
The classification model is used to intelligently classify multiple cardiac signal segments, determine the voltage value and baseline voltage value of the potential abnormal ST segment, and use the difference between the voltage value and the baseline voltage value to determine whether the ST segment is abnormal.
The accuracy and efficiency of ST segment abnormality detection are improved, and the probability of missed detection is reduced.
Smart Images

Figure CN115349866B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of information processing technology, and in particular to an electrocardiogram signal processing method, apparatus, device, and storage medium. Background Art
[0002] An electrocardiogram (ECG) signal refers to the bioelectrical signal generated by myocardial excitation at each moment of cardiac activity, as recorded by an electrocardiograph. It is an important basis for the clinical diagnosis of cardiovascular disease. ECG signals typically include the P wave, QRS complex, and T wave. The signal between the end point of the S wave and the beginning point of the T wave in the QRS complex is called the ST segment, where the end point of the S wave is the starting point of the ST segment, and the beginning point of the T wave is the end point of the ST segment. When multiple consecutive ST segments are abnormal, the ECG signal can be determined to be abnormal.
[0003] In the related art, after obtaining a long-term ECG signal, doctors usually search for abnormal ST segments in the ECG signal, which is time-consuming and labor-intensive and prone to missed detection. Summary of the Invention
[0004] The present invention provides an electrocardiogram (ECG) signal processing method, apparatus, device, and storage medium, which can improve the efficiency and accuracy of ST segment abnormality detection in ECG signals. The technical solution is as follows:
[0005] In one aspect, a method for processing an electrocardiogram signal is provided, the method comprising:
[0006] extracting multiple heartbeat signal segments from the electrocardiogram signal;
[0007] Classifying the multiple heartbeat signal segments using a classification model to obtain a classification result for each heartbeat signal segment, wherein the classification result is used to indicate whether an ST segment in the heartbeat signal segment is a potential abnormal ST segment;
[0008] Determining a voltage value of a potential abnormal ST segment and a corresponding baseline voltage value in the plurality of heartbeat signal segments based on the classification result of each heartbeat signal segment;
[0009] Based on the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value, a detection result of the potential abnormal ST segment is determined, where the detection result is used to indicate whether the potential abnormal ST segment is abnormal.
[0010] Optionally, classifying the multiple heartbeat signal segments using a classification model to obtain a classification result for each heartbeat signal segment includes:
[0011] determining a heartbeat vector corresponding to each heartbeat signal segment in the plurality of heartbeat signal segments;
[0012] sorting the determined multiple heartbeat vectors according to the time sequence of the multiple heartbeat signal segments to obtain a heartbeat vector sequence;
[0013] The heartbeat vector sequence is processed by the classification model to obtain a classification result for each heartbeat signal segment.
[0014] Optionally, when the classification result indicates that the cardiac signal segment is a potential abnormal ST segment, the classification result further includes an abnormality type of the potential abnormal ST segment, and the abnormality type includes one of ST segment elevation and ST segment depression;
[0015] The step of determining the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value in the plurality of heartbeat signal segments based on the classification result of each heartbeat signal segment includes:
[0016] If the ST segment in each heartbeat signal segment is a potential abnormal ST segment and the abnormal type is ST segment elevation or ST segment depression, then determine the Q wave starting point, S wave ending point, T wave starting point, and T wave ending point in each heartbeat signal segment;
[0017] The average value of the voltage between the end point of the S wave and the start point of the T wave in each heartbeat signal segment is used as the voltage value of the potential abnormal ST segment in the corresponding heartbeat signal segment;
[0018] Interpolation is performed between the Q wave start point and the T wave end point in each heartbeat signal segment to obtain multiple interpolation points, and baseline fitting is performed based on the Q wave start point, the T wave end point and the multiple interpolation points in each heartbeat signal segment to obtain a fitted baseline corresponding to the potential abnormal ST segment in the corresponding heartbeat signal segment;
[0019] The average of the voltage values on the fitted baseline corresponding to each potential abnormal ST segment is used as the baseline voltage value corresponding to the corresponding potential abnormal ST segment.
[0020] Optionally, when the classification result indicates that the ST segment in the cardiac signal segment is a potential abnormal ST segment, the classification result further includes an abnormality type of the potential abnormal ST segment, and the abnormality type includes one of ST segment elevation, ST segment depression, abnormal ST segment start, and abnormal ST segment end;
[0021] The step of determining the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value in the plurality of heartbeat signal segments based on the classification result of each heartbeat signal segment includes:
[0022] If the multiple heartbeat signal segments include a potential abnormal ST segment with an abnormal ST segment start or an abnormal ST segment end and a normal heartbeat signal segment, determining an S wave end point and a T wave start point in the normal heartbeat signal segment among the multiple heartbeat signal segments, wherein the normal heartbeat signal segment refers to a heartbeat signal segment whose ST segment is not a potential abnormal ST segment as indicated by the classification result;
[0023] Based on the S wave end point and the T wave start point in the normal heartbeat signal segment, the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value are determined.
[0024] Optionally, there are multiple normal heartbeat signal segments;
[0025] The determining of the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value based on the S wave end point and the T wave start point in the normal heartbeat signal segment includes:
[0026] Determine the starting point position and the ending point position based on the S wave ending point and the T wave starting point in the plurality of normal heartbeat signal segments;
[0027] determining a baseline voltage value corresponding to the potential abnormal ST segment based on voltage values corresponding to respective abscissa positions between the starting point and the ending point in the plurality of normal heartbeat signal segments;
[0028] The voltage value of the potential abnormal ST segment is determined based on the voltage values corresponding to the respective abscissa positions between the starting point and the ending point in the abnormal heartbeat signal segment including the potential abnormal ST segment.
[0029] Optionally, determining the starting point position and the ending point position based on the S wave ending points and the T wave starting points in the plurality of normal heartbeat signal segments includes:
[0030] Determining a center of mass of a plurality of S wave end points included in the plurality of normal heartbeat signal segments, and using the abscissa position of the center of mass of the plurality of S wave end points as the starting point position;
[0031] The centroids of the plurality of T wave starting points included in the plurality of normal heartbeat signal segments are determined, and the abscissa positions of the centroids of the plurality of T wave ending points are used as the ending point positions.
[0032] Optionally, determining the detection result of the potential abnormal ST segment based on the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value includes:
[0033] If the absolute value of the difference between the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value is greater than a reference threshold, an abnormality detection result is generated, where the abnormality detection result is used to indicate that the potential abnormal ST segment is abnormal.
[0034] In another aspect, an electrocardiographic signal processing device is provided, the device comprising:
[0035] An extraction module, used for extracting multiple heartbeat signal segments from the electrocardiogram signal;
[0036] a classification module, configured to classify the plurality of heartbeat signal segments using a classification model to obtain a classification result for each heartbeat signal segment, wherein the classification result is used to indicate whether an ST segment in the heartbeat signal segment is a potential abnormal ST segment;
[0037] a determination module, configured to determine a voltage value of a potential abnormal ST segment and a corresponding baseline voltage value in the plurality of heartbeat signal segments based on the classification result of each heartbeat signal segment;
[0038] The detection module is used to determine a detection result of the potential abnormal ST segment based on the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value, wherein the detection result is used to indicate whether the potential abnormal ST segment is abnormal.
[0039] Optionally, the classification module is mainly used to:
[0040] determining a heartbeat vector corresponding to each heartbeat signal segment in the plurality of heartbeat signal segments;
[0041] sorting the determined multiple heartbeat vectors according to the time sequence of the multiple heartbeat signal segments to obtain a heartbeat vector sequence;
[0042] The heartbeat vector sequence is processed by the classification model to obtain a classification result for each heartbeat signal segment.
[0043] Optionally, when the classification result indicates that the cardiac signal segment is a potential abnormal ST segment, the classification result further includes an abnormality type of the potential abnormal ST segment, and the abnormality type includes one of ST segment elevation and ST segment depression;
[0044] The determination module is mainly used for:
[0045] If the ST segment in each heartbeat signal segment is a potential abnormal ST segment and the abnormal type is ST segment elevation or ST segment depression, then determine the Q wave starting point, S wave ending point, T wave starting point, and T wave ending point in each heartbeat signal segment;
[0046] The average value of the voltage between the end point of the S wave and the start point of the T wave in each heartbeat signal segment is used as the voltage value of the potential abnormal ST segment in the corresponding heartbeat signal segment;
[0047] Interpolation is performed between the Q wave start point and the T wave end point in each heartbeat signal segment to obtain multiple interpolation points, and baseline fitting is performed based on the Q wave start point, the T wave end point and the multiple interpolation points in each heartbeat signal segment to obtain a fitted baseline corresponding to the potential abnormal ST segment in the corresponding heartbeat signal segment;
[0048] The average of the voltage values on the fitted baseline corresponding to each potential abnormal ST segment is used as the baseline voltage value corresponding to the corresponding potential abnormal ST segment.
[0049] Optionally, when the classification result indicates that the ST segment in the cardiac signal segment is a potential abnormal ST segment, the classification result further includes an abnormality type of the potential abnormal ST segment, and the abnormality type includes one of ST segment elevation, ST segment depression, abnormal ST segment start, and abnormal ST segment end;
[0050] The determination module is mainly used for:
[0051] If the multiple heartbeat signal segments include a potential abnormal ST segment with an abnormal ST segment start or an abnormal ST segment end and a normal heartbeat signal segment, determining an S wave end point and a T wave start point in the normal heartbeat signal segment among the multiple heartbeat signal segments, wherein the normal heartbeat signal segment refers to a heartbeat signal segment whose ST segment is not a potential abnormal ST segment as indicated by the classification result;
[0052] Based on the S wave end point and the T wave start point in the normal heartbeat signal segment, the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value are determined.
[0053] Optionally, there are multiple normal heartbeat signal segments;
[0054] The determination module is mainly used for:
[0055] Determine the starting point position and the ending point position based on the S wave ending point and the T wave starting point in the plurality of normal heartbeat signal segments;
[0056] determining a baseline voltage value corresponding to the potential abnormal ST segment based on voltage values corresponding to respective abscissa positions between the starting point and the ending point in the plurality of normal heartbeat signal segments;
[0057] The voltage value of the potential abnormal ST segment is determined based on the voltage values corresponding to the respective abscissa positions between the starting point and the ending point in the abnormal heartbeat signal segment including the potential abnormal ST segment.
[0058] Optionally, the determining module is mainly used to:
[0059] Determining a center of mass of a plurality of S wave end points included in the plurality of normal heartbeat signal segments, and using the abscissa position of the center of mass of the plurality of S wave end points as the starting point position;
[0060] The centroids of the plurality of T wave starting points included in the plurality of normal heartbeat signal segments are determined, and the abscissa positions of the centroids of the plurality of T wave ending points are used as the ending point positions.
[0061] Optionally, the detection module is mainly used to:
[0062] If the absolute value of the difference between the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value is greater than a reference threshold, an abnormality detection result is generated, where the abnormality detection result is used to indicate that the potential abnormal ST segment is abnormal.
[0063] On the other hand, a computer device is provided, comprising: a processor and a memory, wherein the memory stores a computer program, and the computer program is loaded by the processor and executes the above-mentioned electrocardiogram signal processing method.
[0064] On the other hand, a computer-readable storage medium is provided, wherein the storage medium stores a computer program, and when the computer program is executed by a computer, the steps of the above-mentioned electrocardiogram signal processing method are implemented.
[0065] On the other hand, a computer program product comprising instructions is provided, which, when executed on a computer, enables the computer to execute the steps of the above-mentioned electrocardiogram signal processing method.
[0066] The beneficial effects of the technical solutions provided in the embodiments of the present application include at least:
[0067] In an embodiment of the present application, a classification model is first used to intelligently classify multiple cardiac signal segments, thereby identifying potential abnormal ST segments in each cardiac signal segment. Subsequently, the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value are determined based on the classification results of each cardiac signal segment. Furthermore, based on the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value, it is further determined whether the potential abnormal ST segment is a truly abnormal ST segment. This not only ensures the accuracy of ST segment abnormality detection and reduces the probability of missed detection, but also is more efficient than manually searching for abnormal ST segments from electrocardiogram signals. BRIEF DESCRIPTION OF THE DRAWINGS
[0068] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0069] Figure 1 is a schematic diagram of an electrocardiogram signal provided in an embodiment of the present application;
[0070] Figure 2 This is a flow chart of an electrocardiogram signal processing method provided in an embodiment of the present application;
[0071] Figure 3 is a schematic diagram of a heartbeat signal segment provided in an embodiment of the present application;
[0072] Figure 4 is a flowchart of another electrocardiogram signal processing method provided in an embodiment of the present application;
[0073] Figure 5 This is a structural block diagram of an electrocardiogram signal processing device provided in an embodiment of the present application;
[0074] Figure 6 This is a structural diagram of a computer device for processing electrocardiogram signals provided in an embodiment of the present application. DETAILED DESCRIPTION
[0075] In order to make the objectives, technical solutions and advantages of this application clearer, the implementation methods of this application will be further described in detail below with reference to the accompanying drawings.
[0076] Before explaining the embodiments of the present application in detail, the application scenarios involved in the embodiments of the present application are first introduced.
[0077] As people's living standards improve, the incidence of cardiovascular disease in the elderly is increasing. ECG signals are an important basis for clinical diagnosis of cardiovascular disease. The normality of the ST segment in an ECG signal is closely related to physical health. Therefore, it is crucial to help doctors accurately and quickly identify abnormal ST segments in ECG signals. The ECG signal processing method provided in the embodiments of the present application is used to intelligently detect abnormal ST segments in ECG signals, thereby improving the efficiency and accuracy of identifying abnormal ST segments.
[0078] Next, the relevant terms involved in the embodiments of this application are introduced.
[0079] ECG signal: The bioelectrical signal generated by myocardial excitation during cardiac activity recorded by an electrocardiograph. Figure 1, ECG signals usually include P wave, QRS complex, and T wave. Among them, Figure 1 The horizontal axis of the coordinate system is time, and the vertical axis is voltage value. That is, the electrocardiogram signal is actually a curve showing the change of voltage value generated by myocardial excitation over time during cardiac activity.
[0080] P wave: Reflects the electrical potential changes during atrial activation. The first half represents right atrial activation, while the second half represents left atrial activation. In a normal heart, electrical activation begins in the sinoatrial node. Because the sinoatrial node is located at the junction of the right atrium and the superior vena cava, activation of the sinoatrial node is first transmitted to the right atrium, then through the atrial bundle to the left atrium, forming the P wave in the ECG signal.
[0081] QRS wave group: reflects the electrical excitation process of the left and right ventricles. Figure 1 As shown in Figure 1, the first downward wave is the Q wave, the upward wave is the R wave, and the subsequent downward wave is the S wave.
[0082] T wave: reflects the potential changes during ventricular myocardial repolarization.
[0083] ST segment: The signal segment from the end of the S wave to the beginning of the T wave.
[0084] Isopotential line: When myocardial cells are in a resting state or polarized state, the electric couple on the membrane surface disappears, the potential at each point is equal and there is no potential difference. The straight line recorded by the ammeter is the isopotential line.
[0085] Baseline: Under normal circumstances, the baseline and the isoelectric line are located on the same straight line, which is the reference standard line for judging the direction of each wave in the ECG signal and measuring the amplitude.
[0086] Since the end point of the S wave, the starting point of the T wave and the baseline in the electrocardiogram signal are difficult to locate accurately and automatically, the current related technologies all manually locate the ST segment and baseline from the electrocardiogram signal to determine the abnormal ST segment. The electrocardiogram signal processing method provided in the embodiment of the present application first intelligently classifies multiple heartbeat signal segments through a classification model, thereby finding the potential abnormal ST segment in each heartbeat signal segment. Afterwards, the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value are determined based on the classification result of each heartbeat signal segment, and then based on the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value, it is further determined whether the potential abnormal ST segment is a truly abnormal ST segment. In this way, not only can the accuracy of ST segment abnormality detection be guaranteed and the probability of missed detection be reduced, but it is also more efficient than manually searching for abnormal ST segments from electrocardiogram signals.
[0087] Next, the electrocardiogram signal processing method provided in the embodiment of the present application is introduced.
[0088] It should be noted that each step in the ECG signal processing method provided in the embodiment of the present application can be performed by a computer device. The computer device may have the function of processing ECG signals. Optionally, the computer device may also have the function of displaying ECG signals. For example, the computer device may be connected to the lead and receive and display the ECG signals sent by the lead. Exemplarily, the computer device may be a terminal device such as a personal computer, a tablet computer or a smart phone. Of course, it may also be a background server, which is not limited in the embodiment of the present application. The following embodiments are introduced by taking the terminal device executing the ECG signal processing method as an example.
[0089] Figure 2 This is a flow chart of an electrocardiogram signal processing method provided in an embodiment of the present application. Figure 2 As shown, the method includes the following steps:
[0090] Step 201: extract multiple heartbeat signal segments from the electrocardiogram signal.
[0091] In an embodiment of the present application, a terminal device may acquire an ECG signal, which may be a long-term ECG signal of any one lead, for example, a long-term ECG signal of any one of the 12 leads.
[0092] After acquiring the ECG signal, the terminal device may divide the ECG signal to extract multiple heartbeat signal segments.
[0093] For example, the terminal device can detect the end point of the T wave in the electrocardiogram signal and use the signal segment between the end points of two adjacent T waves as a heartbeat signal segment. That is, a heartbeat signal segment is a signal segment starting from the end point of one T wave to the end point of the next T wave. For example, Figure 3 As shown, a heartbeat signal segment includes a P wave, a QRS complex, and a T wave. Optionally, in the ECG signals of certain leads, a heartbeat signal segment may also include a U wave, which is located after the T wave of the previous heartbeat signal segment and before the P wave of the current heartbeat signal segment.
[0094] Step 202: Classify the multiple heartbeat signal segments using a classification model to obtain a classification result for each heartbeat signal segment. The classification result is used to indicate whether the ST segment in the heartbeat signal segment is a potential abnormal ST segment.
[0095] After extracting multiple heartbeat signal segments from the electrocardiogram signal, the terminal device can determine the heartbeat vector corresponding to each of the multiple heartbeat signal segments; sort the determined multiple heartbeat vectors according to the time sequence of the multiple heartbeat signal segments to obtain a heartbeat vector sequence; and process the heartbeat vector sequence through a classification model to obtain a classification result for each heartbeat signal segment.
[0096] For example, taking any heartbeat signal segment as an example, the terminal device may arrange the voltage values corresponding to various time points within the heartbeat signal segment in chronological order, thereby obtaining a one-dimensional heartbeat vector.
[0097] After obtaining the heartbeat vector corresponding to each heartbeat signal segment, the terminal device sorts the heartbeat vectors corresponding to each heartbeat signal segment in chronological order to obtain a heartbeat vector sequence. The terminal device then uses this heartbeat vector sequence as input to a classification model, which processes the heartbeat vector sequence and outputs a classification result corresponding to each heartbeat vector. The classification result corresponding to each heartbeat vector is the classification result for the heartbeat signal segment corresponding to that heartbeat vector.
[0098] It should be noted that the classification result of the heartbeat signal segment can indicate whether the ST segment in the heartbeat signal segment is a potential abnormal ST segment. That is, the suspected abnormal ST segments in the multiple heartbeat signal segments can be preliminarily screened out through the classification model. Moreover, when the classification result of the heartbeat signal segment indicates that the ST segment in the heartbeat signal segment is a potential abnormal ST segment, the classification result also includes the abnormal type of the potential abnormal ST segment. Exemplarily, the abnormal type of the potential abnormal ST segment included in any heartbeat signal segment is one of ST segment elevation, ST segment depression, abnormal ST segment start and abnormal ST segment end.
[0099] In addition, the above-mentioned classification model can be an AI (Artificial Intelligence) model that has been pre-trained through a large number of heartbeat vector sequence samples. For example, the classification model can be an RNN (Recurrent Neural Network) model. There is labeling information corresponding to the heartbeat vector in each heartbeat vector sequence sample, and the labeling information is used to indicate whether the ST segment in the heartbeat signal segment corresponding to the heartbeat vector is an abnormal ST segment, and when it is indicated as an abnormal ST segment, the labeling information is also used to indicate the abnormal type of the abnormal ST segment. Based on this, when the trained classification model is used to classify the heartbeat vector sequences corresponding to the multiple extracted heartbeat signal segments, the heartbeat signal segments with potential abnormal ST segments in the multiple heartbeat signal segments can be screened out more accurately.
[0100] It is worth noting that in an embodiment of the present application, multiple heartbeat vectors are organized into a heartbeat vector sequence in corresponding chronological order, and the heartbeat vector sequence is used as the input of the classification model. In this way, when processing the heartbeat vector sequence, the classification model fully utilizes the relationship and mutual influence between each heartbeat vector, thereby making the final output classification result more accurate.
[0101] Step 203: Based on the classification result of each heartbeat signal segment, determine the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value in the multiple heartbeat signal segments.
[0102] After obtaining the classification results of each heartbeat signal segment, the terminal device can integrate the classification results of multiple heartbeat signal segments and use different methods to determine the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value according to different classification results.
[0103] The first implementation method: If it is determined based on the classification results of multiple heartbeat signal segments that the ST segments in each heartbeat signal segment are all potentially abnormal ST segments and the abnormal type is ST segment elevation or ST segment depression, then the Q wave starting point, S wave ending point, T wave starting point and T wave ending point are determined in each heartbeat signal segment; the average value of the voltage values between the S wave ending point and the T wave starting point in each heartbeat signal segment is used as the voltage value of the potential abnormal ST segment in the corresponding heartbeat signal segment; linear interpolation is performed between the Q wave starting point and the T wave ending point in each heartbeat signal segment to obtain multiple interpolation points, and baseline fitting is performed based on the Q wave starting point, T wave ending point and multiple interpolation points in each heartbeat signal segment to obtain a fitted baseline corresponding to the potential abnormal ST segment in each heartbeat signal segment; the average value of the voltage values on the fitted baseline corresponding to each potential abnormal ST segment is used as the baseline voltage value corresponding to the corresponding potential abnormal ST segment.
[0104] If the ST segments in each heartbeat signal segment are all potentially abnormal ST segments, and the abnormality type is ST-segment elevation or ST-segment depression, with no other abnormality types present, then each ST segment has no abnormal start or end. In this case, false detection of each S-wave end point and T-wave start point will have little impact on determining whether the ST segment is abnormal. In this case, the terminal device can directly detect the S-wave end point and T-wave start point in each heartbeat signal segment to determine the potential abnormal ST segment in each heartbeat signal segment, and then determine the voltage value of each potential abnormal ST segment. Furthermore, since each ST segment in each heartbeat signal segment is a potential abnormal ST segment, there are no normal ST segments to use as a reference for baseline determination. Therefore, in this case, the terminal device can determine the Q-wave start point and T-wave end point in each heartbeat signal segment, perform a linear interpolation between the Q-wave start point and the T-wave end point, and then perform baseline fitting based on the interpolation points to obtain a fitted baseline corresponding to the corresponding heartbeat signal segment. In this way, by segmentally fitting the baseline, the resulting baseline corresponding to each heartbeat signal segment will be unaffected by the potential abnormal ST segment and more accurate.
[0105] For example, after locating the potential abnormal ST segment in each cardiac signal segment, the terminal device may calculate an average value of multiple voltage values between the potential abnormal ST segments and use the average value as the voltage value of the potential abnormal ST segment.
[0106] Furthermore, when performing baseline fitting, for any heartbeat signal segment, linear interpolation is performed between the Q wave start point and the T wave end point based on the voltage values at the Q wave start point and the T wave end point within the heartbeat signal segment, obtaining multiple interpolation points. The line connecting these multiple interpolation points replaces the ECG signal between Q and T for baseline fitting, obtaining a fitted baseline. This prevents the influence of other waves between the Q wave start point and the T wave end point on the baseline fitting. The terminal device can then calculate the average of the multiple voltage values on the fitted baseline to obtain the baseline voltage value corresponding to the heartbeat signal segment.
[0107] The second implementation method: If multiple heartbeat signal segments include a potential abnormal ST segment with an abnormal type of ST segment abnormal start or ST segment abnormal end and a normal heartbeat signal segment, then determine the S wave end point and T wave start point in the normal heartbeat signal segment among the multiple heartbeat signal segments, and the normal heartbeat signal segment refers to the heartbeat signal segment whose classification result indicates that the ST segment is not a potential abnormal ST segment; based on the S wave end point and T wave start point in the normal heartbeat signal segment, determine the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value.
[0108] If a normal heartbeat signal segment is included in multiple heartbeat signal segments, the terminal device can determine the baseline based on the normal ST segment in the normal heartbeat signal segment. The normal heartbeat signal segment refers to a heartbeat signal segment whose ST segment is a normal ST segment. Furthermore, if multiple heartbeat signal segments also include a potential abnormal ST segment whose abnormal type is an abnormal ST segment start or an abnormal ST segment end, since the accuracy of determining the abnormal ST segment start or abnormal ST segment end depends on the positioning accuracy of the S wave end point and the T wave start point, in this case, the S wave end point and the T wave start point in the normal heartbeat signal segment can be combined to locate the potential abnormal ST segment in the abnormal heartbeat signal segment, thereby reducing the impact of the erroneous detection of the S wave end point and the T wave start point on the ST segment abnormality detection. The abnormal heartbeat signal segment refers to a heartbeat signal segment whose ST segment is indicated by the classification result as a potential abnormal ST segment.
[0109] Exemplarily, when there are multiple normal heartbeat signal segments among multiple heartbeat signal segments, the terminal device can determine the starting point position and the ending point position based on the S wave ending point and the T wave starting point in the multiple normal heartbeat signal segments; determine the baseline voltage value corresponding to the potential abnormal ST segment based on the voltage values corresponding to each horizontal coordinate position between the starting point position and the ending point position in the multiple normal heartbeat signal segments; determine the voltage value of the potential abnormal ST segment based on the voltage values corresponding to each horizontal coordinate position between the starting point position and the ending point position in the abnormal heartbeat signal segment including the potential abnormal ST segment.
[0110] In one possible implementation, the terminal device may determine the centroid of multiple S-wave ending points included in multiple normal heartbeat signal segments, and use the horizontal coordinate position of the centroid as the starting point. Alternatively, the terminal device may determine the centroid of multiple T-wave starting points included in multiple normal heartbeat signal segments, and use the horizontal coordinate position of the centroid as the ending point. In this case, the starting point is the corrected ST segment starting point, and the ending point is the corrected ST segment ending point.
[0111] It should be noted that the terminal device can calculate the position of the centroid of multiple S-wave end points based on the horizontal and vertical coordinate positions of the multiple S-wave end points. The position of the centroid of multiple T-wave starting points can be calculated based on the horizontal and vertical coordinate positions of multiple T-wave starting points. The specific calculation method can refer to the relevant technology, and the embodiments of this application will not be described in detail. It is worth noting that the above-mentioned centroid can also be the cluster center point. That is, the centroid of multiple S-wave end points can also be the cluster center point of multiple S-wave end points. The centroid of multiple T-wave starting points can be the cluster center point of multiple T-wave starting points.
[0112] In the embodiment of the present application, the horizontal coordinate position of the centroid of the multiple S-wave end points is used as the starting point position. This can reduce the influence of the more distant S-wave end points on the corrected ST segment start point position. Similarly, the horizontal coordinate position of the centroid of the multiple T-wave end points is used as the starting point position. This can reduce the influence of the more distant T-wave end points on the corrected ST segment start point position. In this way, the accuracy of the subsequently located ST segment can be improved.
[0113] Optionally, in another possible implementation, the terminal device can also align the horizontal coordinates of multiple normal heartbeat signal segments. That is, the horizontal coordinate position of the starting point of each normal heartbeat signal segment is set to 0, and the difference between the horizontal coordinate positions of other points in each normal heartbeat signal segment and the horizontal coordinate position of the starting point is used as the horizontal coordinate position of the corresponding point after alignment. In this way, after the horizontal coordinates of the normal heartbeat signal segments are aligned, the average value of the horizontal coordinate positions of the S wave end points in the aligned multiple normal heartbeat signal segments is calculated to obtain the starting point position. The average value of the horizontal coordinate positions of the T wave starting points in the aligned multiple normal heartbeat signal segments is calculated to obtain the end point position.
[0114] For example, assume that multiple heartbeat signal segments include normal heartbeat signal segments V1, V2, and V3. The horizontal coordinate position of the starting point of V1 is t1, and the horizontal coordinate position of the starting point is set to 0. Then, for the horizontal coordinate position tn of any point in V1, (tn-t1) is used as the horizontal coordinate position corresponding to tn after alignment. Thus, assuming that the horizontal coordinate position of the S wave end point in V1 after alignment is s1, the horizontal coordinate position of the S wave end point in V2 after alignment is s2, and the horizontal coordinate position of the S wave end point in V3 after alignment is s3, the starting point position is (s1+s2+s3) / 3.
[0115] After obtaining the starting point position and the ending point position, the terminal device can calculate the average value of all voltage values between the starting point position and the ending point position in the aligned multiple normal heartbeat signal segments, and use the average value as the baseline voltage value corresponding to each potential abnormal ST segment.
[0116] In addition, for any abnormal heartbeat signal segment among the multiple heartbeat signal segments, the terminal device can use the above-mentioned method to align the abscissas of the abnormal heartbeat signal segment with the abscissas of the multiple normal heartbeat signal segments. Thereafter, the terminal device can calculate the average voltage value between the starting point and the ending point within the abnormal heartbeat signal segment to obtain the voltage value of the potential abnormal ST segment in the abnormal heartbeat signal segment. In other words, the signal segment between the starting point and the ending point within the abnormal heartbeat signal segment is the potential abnormal ST segment in the abnormal heartbeat signal segment.
[0117] Thus, in an embodiment of the present application, when multiple heartbeat signal segments contain a potential abnormal ST segment with an abnormal ST segment start or abnormal ST segment end, as well as multiple normal heartbeat signal segments, the terminal device can superimpose the positions of the S wave end points within the multiple normal heartbeat signal segments and average the starting point position on the time-voltage value two-dimensional coordinate system. This starting point position is actually the corrected S wave end point position, that is, the corrected ST segment starting point position. Similarly, the positions of the T wave start points within the multiple normal heartbeat signal segments are superimposed and averaged on the time-voltage value two-dimensional coordinate system to obtain the ending point position. This ending point position is actually the corrected T wave start point position, that is, the corrected ST segment ending point position. On this basis, it is more accurate to use the average voltage value between the starting point position and the ending point position within the normal heartbeat signal segment as the baseline voltage value. Furthermore, using the signal segment between the starting point position and the ending point position within the abnormal heartbeat signal segment as the potential abnormal ST segment makes the positioning of the potential abnormal ST segment more accurate, and the voltage value of the potential abnormal ST segment ultimately obtained is also more accurate.
[0118] Optionally, in some possible situations, if there is no normal heartbeat signal segment among the multiple heartbeat signal segments, the terminal device may also use the method in the first implementation mode described above to determine the voltage value and corresponding baseline voltage value of the potential abnormal ST segment within each heartbeat signal segment. Alternatively, the terminal device may use the heartbeat signal segment with an abnormal type of ST segment elevation or ST segment depression among the multiple heartbeat signal segments as the target heartbeat signal segment, and then use the method in the first implementation mode described above to determine the fitting baseline corresponding to each target heartbeat signal segment, and then use the average of the voltage values on all fitting baselines as the baseline voltage value corresponding to each potential abnormal ST segment. In addition, referring to the first implementation mode described above, the voltage value of the potential abnormal ST segment in each target heartbeat signal segment is determined. At the same time, the terminal device may also use the method described in the second implementation mode described above to determine the starting point position and the ending point position based on the target heartbeat signal segment, and then locate the potential abnormal ST segment within the heartbeat signal segment with an abnormal type of ST segment abnormal start or ST segment abnormal end based on the starting point position and the ending point position, and then calculate the voltage value of the potential abnormal ST segment within such heartbeat signal segment.
[0119] Step 204: Determine a detection result of the potential abnormal ST segment based on the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value. The detection result is used to indicate whether the potential abnormal ST segment is abnormal.
[0120] After determining the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value within each abnormal heartbeat signal segment, for any abnormal heartbeat signal segment, the terminal device calculates the difference between the voltage value of the potential abnormal ST segment within the abnormal heartbeat signal segment and the corresponding baseline voltage value, compares the absolute value of the difference with a reference threshold, and generates an abnormal detection result if the absolute value of the difference is greater than the reference threshold, indicating that the potential abnormal ST segment is an abnormal ST segment. If the absolute value of the difference is not greater than the reference threshold, a normal detection result is generated, indicating that the potential abnormal ST segment is not an abnormal ST segment but a normal ST segment.
[0121] The reference threshold value can be set according to the lead corresponding to the ECG signal. For ECG signals collected from different leads, the reference threshold value can be different or the same, which is not limited in the present embodiment.
[0122] Optionally, if it is determined in the above manner that the ST segments included in N consecutive heartbeat signal segments in the electrocardiogram signal are all abnormal, then the electrocardiogram signal may be determined to be abnormal, where N is not less than 2.
[0123] In an embodiment of the present application, a classification model is first used to intelligently classify multiple cardiac signal segments, thereby identifying potential abnormal ST segments in each cardiac signal segment. Subsequently, the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value are determined based on the classification results of each cardiac signal segment. Furthermore, based on the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value, it is further determined whether the potential abnormal ST segment is a truly abnormal ST segment. This not only ensures the accuracy of ST segment abnormality detection and reduces the probability of missed detection, but also is more efficient than manually searching for abnormal ST segments from electrocardiogram signals.
[0124] Furthermore, in an embodiment of the present application, if the ST segment in each heartbeat signal segment is a potentially abnormal ST segment, the terminal device can perform baseline fitting based on the Q wave start point and T wave end point in each heartbeat signal segment to obtain a fitted baseline corresponding to the corresponding heartbeat signal segment. In this way, by performing segmented baseline fitting, the resulting baseline corresponding to each heartbeat signal segment will be unaffected by potentially abnormal ST segments and will be more accurate.
[0125] If multiple heartbeat signal segments contain potential abnormal ST segments with abnormal ST segment start or abnormal ST segment end, as well as multiple normal heartbeat signal segments, the terminal device can superimpose the positions of the S wave end points in the multiple normal heartbeat signal segments and average them to obtain the corrected ST segment start point position. Superimpose the positions of the T wave start points in the multiple normal heartbeat signal segments and average them to obtain the corrected ST segment end point position. On this basis, it will be more accurate to use the average voltage value between the start point position and the end point position in the normal heartbeat signal segment as the baseline voltage value. In addition, using the signal segment between the start point position and the end point position in the abnormal heartbeat signal segment as the potential abnormal ST segment makes the positioning of the potential abnormal ST segment more accurate, and the voltage value of the potential abnormal ST segment finally obtained is also more accurate, reducing the impact caused by the misdetection of the S wave end point and the T wave start point.
[0126] Figure 4 This is an exemplary ECG signal processing flow chart provided in the embodiment of the present application. Figure 4 As shown, the process includes the following steps:
[0127] Step 401: Divide the long-term ECG signal into multiple heartbeat signal segments.
[0128] The division method refers to the division method in step 301 in the above embodiment.
[0129] Step 402: extracting a heartbeat vector from each heartbeat signal segment, and arranging the heartbeat vectors in chronological order to obtain a heartbeat vector sequence.
[0130] Step 403: Process the heartbeat vector sequence through the classification model to obtain a classification result for each heartbeat signal segment.
[0131] Step 404: Based on the classification results of the multiple heartbeat signal segments, determine whether the multiple heartbeat signal segments are all abnormal heartbeat signal segments including potential abnormal ST segments. If yes, execute step 405; if not, execute step 408.
[0132] Step 405: Determine whether the abnormal type of the potential abnormal ST segment in each cardiac signal segment is ST segment elevation or ST segment depression. If yes, execute steps 406, 407 and 412 in sequence.
[0133] Step 406: interpolate between the Q wave start point and the T wave end point in each heartbeat signal segment, perform baseline fitting based on the interpolation result, and determine the potential abnormal ST segment in each heartbeat signal segment.
[0134] Step 407: Determine the baseline voltage value of the fitted baseline and the voltage value of the potential abnormal ST segment in each heartbeat signal segment.
[0135] Step 408: Determine whether the multiple heartbeat signal segments include an abnormal heartbeat signal segment with an abnormal type of ST segment abnormal start or ST segment abnormal end. If yes, execute steps 409 to 412.
[0136] Step 409: The horizontal coordinate position of the centroid of the S wave end point in the normal heartbeat signal segment among the multiple heartbeat signal segments is used as the starting point position, and the horizontal coordinate position of the centroid of the T wave start point in the normal heartbeat signal segment is used as the ending point position.
[0137] Step 410: The average voltage value between the starting point and the ending point of the normal heartbeat signal segment is used as the baseline voltage value.
[0138] Step 411: taking the average voltage value between the starting point and the ending point of the abnormal heartbeat signal segment as the voltage value of the potential abnormal ST segment in the abnormal heartbeat signal segment.
[0139] Step 412: Determine whether the absolute value of the difference between the baseline voltage value and the voltage value of the potential abnormal ST segment is greater than a reference threshold; if yes, execute step 413; if no, execute step 414.
[0140] Step 413: Determine potential abnormal ST segment abnormality.
[0141] Step 414: Determine whether the potentially abnormal ST segment is normal.
[0142] Next, the electrocardiogram signal processing device provided in the embodiment of the present application is introduced.
[0143] See also Figure 5 The embodiment of the present application provides an electrocardiogram signal processing device 500, which includes:
[0144] Extraction module 501, for extracting multiple heartbeat signal segments from the electrocardiogram signal;
[0145] a classification module 502 for classifying the plurality of heartbeat signal segments using a classification model to obtain a classification result for each heartbeat signal segment, wherein the classification result is used to indicate whether an ST segment in the heartbeat signal segment is a potential abnormal ST segment;
[0146] a determination module 503, configured to determine a voltage value of a potential abnormal ST segment and a corresponding baseline voltage value in a plurality of heartbeat signal segments based on the classification result of each heartbeat signal segment;
[0147] The detection module 504 is configured to determine a detection result of the potential abnormal ST segment based on the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value, where the detection result indicates whether the potential abnormal ST segment is abnormal.
[0148] Optionally, the classification module 502 is mainly used for:
[0149] determining a heartbeat vector corresponding to each heartbeat signal segment among a plurality of heartbeat signal segments;
[0150] sorting the determined multiple heartbeat vectors according to a time sequence of the multiple heartbeat signal segments to obtain a heartbeat vector sequence;
[0151] The heartbeat vector sequence is processed by the classification model to obtain the classification result of each heartbeat signal segment.
[0152] Optionally, when the classification result indicates that the cardiac signal segment is a potential abnormal ST segment, the classification result further includes an abnormality type of the potential abnormal ST segment, and the abnormality type includes one of ST segment elevation and ST segment depression;
[0153] The determination module 503 is mainly used for:
[0154] If the ST segment in each heartbeat signal segment is a potential abnormal ST segment and the abnormal type is ST segment elevation or ST segment depression, then determine the Q wave starting point, S wave ending point, T wave starting point, and T wave ending point in each heartbeat signal segment;
[0155] The average value of the voltage between the end point of the S wave and the start point of the T wave in each heartbeat signal segment is used as the voltage value of the potential abnormal ST segment in the corresponding heartbeat signal segment;
[0156] Interpolation is performed between the Q wave start point and the T wave end point in each heartbeat signal segment to obtain multiple interpolation points, and baseline fitting is performed based on the Q wave start point, the T wave end point and the multiple interpolation points in each heartbeat signal segment to obtain a fitted baseline corresponding to the potential abnormal ST segment in the corresponding heartbeat signal segment;
[0157] The average of the voltage values on the fitted baseline corresponding to each potential abnormal ST segment is used as the baseline voltage value corresponding to the corresponding potential abnormal ST segment.
[0158] Optionally, when the classification result indicates that the ST segment in the cardiac signal segment is a potential abnormal ST segment, the classification result further includes an abnormality type of the potential abnormal ST segment, where the abnormality type includes one of ST segment elevation, ST segment depression, abnormal ST segment start, and abnormal ST segment end;
[0159] The determination module 503 is mainly used for:
[0160] If the multiple heartbeat signal segments include a potential abnormal ST segment whose abnormality type is an abnormal ST segment start or an abnormal ST segment end and a normal heartbeat signal segment, determining an S wave end point and a T wave start point in the normal heartbeat signal segment among the multiple heartbeat signal segments, the normal heartbeat signal segment being a heartbeat signal segment whose ST segment is indicated by the classification result as not being a potential abnormal ST segment;
[0161] Based on the S wave end point and T wave start point in the normal heartbeat signal segment, the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value are determined.
[0162] Optionally, there are multiple normal heartbeat signal segments;
[0163] The determination module 503 is mainly used for:
[0164] Determine the starting point position and the ending point position based on the S wave ending points and the T wave starting points in the plurality of normal heartbeat signal segments;
[0165] Determining a baseline voltage value corresponding to a potential abnormal ST segment based on voltage values corresponding to respective abscissa positions between a starting point position and an ending point position in a plurality of normal heartbeat signal segments;
[0166] The voltage value of the potential abnormal ST segment is determined based on the voltage values corresponding to the respective abscissa positions between the starting point position and the ending point position in the abnormal heartbeat signal segment including the potential abnormal ST segment.
[0167] Optionally, the determination module 503 is mainly used to:
[0168] Determine the centroid of multiple S wave end points included in multiple normal heartbeat signal segments, and use the abscissa position of the centroid of the multiple S wave end points as the starting point position;
[0169] The centroids of the plurality of T wave start points included in the plurality of normal heartbeat signal segments are determined, and the abscissa positions of the centroids of the plurality of T wave end points are used as the end point positions.
[0170] Optionally, the detection module 504 is mainly used to:
[0171] If the absolute value of the difference between the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value is greater than the reference threshold, an abnormality detection result is generated, and the abnormality detection result is used to indicate that the potential abnormal ST segment is abnormal.
[0172] In summary, in the embodiment of the present application, a classification model is first used to intelligently classify multiple cardiac signal segments, thereby identifying potential abnormal ST segments in each cardiac signal segment. Subsequently, the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value are determined based on the classification results of each cardiac signal segment. Furthermore, based on the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value, it is further determined whether the potential abnormal ST segment is a truly abnormal ST segment. This not only ensures the accuracy of ST segment abnormality detection and reduces the probability of missed detection, but is also more efficient than manually searching for abnormal ST segments from electrocardiogram signals.
[0173] It should be noted that the ECG signal processing device provided in the above embodiment is only used as an example to illustrate the division of the above functional modules when detecting whether the ST segment in the ECG signal is abnormal. In actual application, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above. In addition, the ECG signal processing device provided in the above embodiment and the ECG signal processing method embodiment are based on the same concept. The specific implementation process is detailed in the method embodiment and will not be repeated here.
[0174] Figure 6 FIG1 is a block diagram of a computer device 600 for processing ECG signals according to an exemplary embodiment. The terminal device in the above embodiment can be implemented by the computer device 600. The computer device 600 can be a smartphone, tablet computer, laptop computer, desktop computer, etc.
[0175] Typically, the computer device 600 includes a processor 601 and a memory 602 .
[0176] The processor 601 may include one or more processing cores, such as a 4-core processor, an 8-core processor, etc. The processor 601 may be implemented in at least one hardware form of DSP (Digital Signal Processing), FPGA (Field-Programmable Gate Array), or PLA (Programmable Logic Array). The processor 601 may also include a main processor and a coprocessor. The main processor is a processor for processing data in the awake state, also known as a CPU (Central Processing Unit); the coprocessor is a low-power processor for processing data in the standby state. In some embodiments, the processor 601 may be integrated with a GPU (Graphics Processing Unit), which is responsible for rendering and drawing the content to be displayed on the display screen. In some embodiments, the processor 601 may also include an AI (Artificial Intelligence) processor, which is used to process computing operations related to machine learning.
[0177] The memory 602 may include one or more computer-readable storage media, which may be non-transitory. The memory 602 may also include high-speed random access memory and non-volatile memory, such as one or more disk storage devices and flash memory storage devices. In some embodiments, the non-transitory computer-readable storage medium in the memory 602 is used to store at least one instruction, wherein the at least one instruction is used to be executed by the processor 601 to implement the electrocardiogram signal processing method provided in the method embodiment of the present application.
[0178] In some embodiments, computer device 600 may optionally include a peripheral device interface 603 and at least one peripheral device. Processor 601, memory 602, and peripheral device interface 603 may be connected via a bus or signal lines. Each peripheral device may be connected to peripheral device interface 603 via a bus, signal lines, or circuit boards. Specifically, the peripheral device may include at least one of a radio frequency circuit 604, a display screen 605, a camera assembly 606, an audio circuit 607, a positioning assembly 608, and a power supply 609.
[0179] The peripheral device interface 603 can be used to connect at least one I / O (Input / Output)-related peripheral device to the processor 601 and the memory 602. In some embodiments, the processor 601, the memory 602, and the peripheral device interface 603 are integrated on the same chip or circuit board; in some other embodiments, any one or two of the processor 601, the memory 602, and the peripheral device interface 603 can be implemented on separate chips or circuit boards, which is not limited in this embodiment.
[0180] The radio frequency circuit 604 is used to receive and transmit RF (Radio Frequency) signals, also known as electromagnetic signals. The radio frequency circuit 604 communicates with communication networks and other communication devices via electromagnetic signals. The radio frequency circuit 604 converts electrical signals into electromagnetic signals for transmission, or converts received electromagnetic signals into electrical signals. Optionally, the radio frequency circuit 604 includes: an antenna system, an RF transceiver, one or more amplifiers, a tuner, an oscillator, a digital signal processor, a codec chipset, a user identity module card, etc. The radio frequency circuit 604 can communicate with other terminals via at least one wireless communication protocol. Such wireless communication protocols include, but are not limited to, the World Wide Web, a metropolitan area network, an intranet, various generations of mobile communication networks (2G, 3G, 4G, and 5G), a wireless local area network, and / or a WiFi (Wireless Fidelity) network. In some embodiments, the radio frequency circuit 604 may also include circuits related to NFC (Near Field Communication), which is not limited in this application.
[0181] The display screen 605 is used to display a UI (User Interface). The UI may include graphics, text, icons, videos, and any combination thereof. When the display screen 605 is a touch screen display, the display screen 605 also has the ability to collect touch signals on the surface or above the surface of the display screen 605. The touch signal can be input as a control signal to the processor 601 for processing. At this time, the display screen 605 can also be used to provide virtual buttons and / or virtual keyboards, also known as soft buttons and / or soft keyboards. The display screen 605 can be made of materials such as LCD (Liquid Crystal Display) and OLED (Organic Light-Emitting Diode).
[0182] The camera component 606 is used to capture images or videos.
[0183] The audio circuit 607 may include a microphone and a speaker. The microphone is used to collect sound waves from the user and the environment, and convert the sound waves into electrical signals that are input into the processor 601 for processing, or input into the radio frequency circuit 604 to achieve voice communication. For the purpose of stereo sound collection or noise reduction, there can be multiple microphones, each located in different parts of the computer device 600. The microphone can also be an array microphone or an omnidirectional collection microphone. The speaker is used to convert electrical signals from the processor 601 or the radio frequency circuit 604 into sound waves. The speaker can be a traditional thin film speaker or a piezoelectric ceramic speaker. When the speaker is a piezoelectric ceramic speaker, it can not only convert electrical signals into sound waves audible to humans, but also convert electrical signals into sound waves inaudible to humans for purposes such as distance measurement. In some embodiments, the audio circuit 607 may also include a headphone jack.
[0184] The positioning component 608 is used to locate the current geographic location of the computer device 600 to implement navigation or LBS (Location Based Service). The positioning component 608 can be a positioning component based on the GPS (Global Positioning System), Beidou system or Galileo system.
[0185] Power supply 609 is used to power various components in computer device 600. Power supply 609 can be AC power, DC power, a disposable battery, or a rechargeable battery. When power supply 609 includes a rechargeable battery, the rechargeable battery can be a wired rechargeable battery or a wireless rechargeable battery. A wired rechargeable battery is a battery that is charged via a wired line, while a wireless rechargeable battery is a battery that is charged via a wireless coil. The rechargeable battery can also be used to support fast charging technology.
[0186] Those skilled in the art will understand that Figure 6 The structure shown in the figure does not constitute a limitation on the computer device 600, and the computer device 600 may include more or fewer components than shown in the figure, or combine some components, or adopt a different arrangement of components.
[0187] An embodiment of the present application also provides a non-transitory computer-readable storage medium. When the instructions in the storage medium are executed by a processor of a computer device, the computer device is able to execute the electrocardiogram signal processing method provided in the above embodiment.
[0188] The present application also provides a computer program product comprising instructions, which, when executed on a computer, enables the computer to execute the above Figure 2 or Figure 4 The illustrated embodiment provides a method for processing electrocardiogram signals.
[0189] It should be noted that the information (including but not limited to user device information, user personal information, etc.), data (including but not limited to data used for analysis, stored data, and displayed data) and signals involved in the embodiments of this application are all authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with the relevant laws, regulations and standards of relevant countries and regions.
[0190] The above description is not intended to limit the embodiments of the present application. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the embodiments of the present application should be included in the scope of protection of the embodiments of the present application.
Claims
1. A method for processing an electrocardiogram signal, characterized in that: The method comprises: extracting multiple heartbeat signal segments from the electrocardiogram signal; Classifying the multiple heartbeat signal segments using a classification model to obtain a classification result for each heartbeat signal segment, wherein the classification result is used to indicate whether an ST segment in the heartbeat signal segment is a potential abnormal ST segment; Determining a voltage value of a potential abnormal ST segment and a corresponding baseline voltage value in the plurality of heartbeat signal segments based on the classification result of each heartbeat signal segment; Based on the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value, a detection result of the potential abnormal ST segment is determined, where the detection result is used to indicate whether the potential abnormal ST segment is abnormal.
2. The method according to claim 1, characterized in that The classifying the plurality of heartbeat signal segments by using a classification model to obtain a classification result for each heartbeat signal segment includes: determining a heartbeat vector corresponding to each heartbeat signal segment in the plurality of heartbeat signal segments; sorting the determined multiple heartbeat vectors according to the time sequence of the multiple heartbeat signal segments to obtain a heartbeat vector sequence; The heartbeat vector sequence is processed by the classification model to obtain a classification result for each heartbeat signal segment.
3. The method according to claim 1, characterized in that When the classification result indicates that the cardiac signal segment is a potential abnormal ST segment, the classification result further includes an abnormality type of the potential abnormal ST segment, and the abnormality type includes one of ST segment elevation and ST segment depression; The step of determining the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value in the plurality of heartbeat signal segments based on the classification result of each heartbeat signal segment includes: If the ST segment in each heartbeat signal segment is a potential abnormal ST segment and the abnormal type is ST segment elevation or ST segment depression, then determine the Q wave starting point, S wave ending point, T wave starting point, and T wave ending point in each heartbeat signal segment; The average value of the voltage between the end point of the S wave and the start point of the T wave in each heartbeat signal segment is used as the voltage value of the potential abnormal ST segment in the corresponding heartbeat signal segment; Performing linear interpolation between the Q wave start point and the T wave end point in each heartbeat signal segment to obtain multiple interpolation points, and performing baseline fitting based on the Q wave start point, the T wave end point, and the multiple interpolation points in each heartbeat signal segment to obtain a fitted baseline corresponding to the potential abnormal ST segment in the corresponding heartbeat signal segment; The average of the voltage values on the fitted baseline corresponding to each potential abnormal ST segment is used as the baseline voltage value corresponding to the corresponding potential abnormal ST segment.
4. The method according to claim 1, wherein When the classification result indicates that the ST segment in the cardiac signal segment is a potential abnormal ST segment, the classification result further includes an abnormality type of the potential abnormal ST segment, the abnormality type including one of ST segment elevation, ST segment depression, abnormal ST segment start, and abnormal ST segment end; The step of determining the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value in the plurality of heartbeat signal segments based on the classification result of each heartbeat signal segment includes: If the multiple heartbeat signal segments include a potential abnormal ST segment with an abnormal ST segment start or an abnormal ST segment end and a normal heartbeat signal segment, determining an S wave end point and a T wave start point in the normal heartbeat signal segment among the multiple heartbeat signal segments, wherein the normal heartbeat signal segment refers to a heartbeat signal segment whose ST segment is not a potential abnormal ST segment as indicated by the classification result; Based on the S wave end point and the T wave start point in the normal heartbeat signal segment, the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value are determined.
5. The method according to claim 4, characterized in that There are multiple normal heartbeat signal segments; The determining of the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value based on the S wave end point and the T wave start point in the normal heartbeat signal segment includes: Determine the starting point position and the ending point position based on the S wave ending point and the T wave starting point in the plurality of normal heartbeat signal segments; determining a baseline voltage value corresponding to the potential abnormal ST segment based on voltage values corresponding to respective abscissa positions between the starting point and the ending point in the plurality of normal heartbeat signal segments; The voltage value of the potential abnormal ST segment is determined based on the voltage values corresponding to the respective abscissa positions between the starting point and the ending point in the abnormal heartbeat signal segment including the potential abnormal ST segment.
6. The method according to claim 5, characterized in that The determining of the starting point position and the ending point position based on the S wave ending points and the T wave starting points in the plurality of normal heartbeat signal segments includes: Determining a center of mass of a plurality of S wave end points included in the plurality of normal heartbeat signal segments, and using the abscissa position of the center of mass of the plurality of S wave end points as the starting point position; The centroids of the plurality of T wave starting points included in the plurality of normal heartbeat signal segments are determined, and the abscissa positions of the centroids of the plurality of T wave ending points are used as the ending point positions.
7. The method according to any one of claims 1 to 6, characterized in that: The determining the detection result of the potential abnormal ST segment based on the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value includes: If the absolute value of the difference between the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value is greater than a reference threshold, an abnormality detection result is generated, where the abnormality detection result is used to indicate that the potential abnormal ST segment is abnormal.
8. An electrocardiogram signal processing device, characterized in that: The device comprises: An extraction module, used for extracting multiple heartbeat signal segments from the electrocardiogram signal; a classification module, configured to classify the plurality of heartbeat signal segments using a classification model to obtain a classification result for each heartbeat signal segment, wherein the classification result is used to indicate whether an ST segment in the heartbeat signal segment is a potential abnormal ST segment; a determination module, configured to determine a voltage value of a potential abnormal ST segment and a corresponding baseline voltage value in the plurality of heartbeat signal segments based on the classification result of each heartbeat signal segment; The detection module is used to determine a detection result of the potential abnormal ST segment based on the voltage value of the potential abnormal ST segment and the corresponding baseline voltage value, wherein the detection result is used to indicate whether the potential abnormal ST segment is abnormal.
9. A computer device, characterized in that: The computer device includes a processor and a memory, wherein the memory stores a computer program, and the computer program is loaded by the processor and executes the electrocardiogram signal processing method according to any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, and when the computer program is executed by a computer, the electrocardiogram signal processing method according to any one of claims 1 to 7 is implemented.
Citation Information
Patent Citations
Electrocardiogram ST segment abnormity discrimination system based on causal analysis
CN114176600A
Method and device for training electrocardiogram ST segment raising recognition model and ST segment raising recognition method and device
CN114219028A