A multi-level, multi-stage electrocardiogram signal classification and recognition method, system, and device

By constructing a multi-level feature and multi-stage analysis method for ECG signal classification, combining time-domain, frequency-domain, and ECG dynamic features, and utilizing neural networks and topological difference calculations, the method solves the problems of insufficient classification accuracy and robustness in traditional methods, and achieves more efficient ECG signal recognition.

CN120837086BActive Publication Date: 2026-06-30GUANGDONG UNIV OF TECH

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
GUANGDONG UNIV OF TECH
Filing Date
2025-07-15
Publication Date
2026-06-30

Smart Images

  • Figure CN120837086B_ABST
    Figure CN120837086B_ABST
Patent Text Reader

Abstract

This invention discloses a multi-level, multi-stage electrocardiogram (ECG) signal classification and recognition method, system, and device. The steps of this invention are as follows: Collecting surface ECG signals from subjects; constructing time-domain features, frequency-domain features, and electrocardiographic dynamic features; inputting these three types of features into a preset neural network model to calculate their local confidence scores; calculating the global confidence score based on electrocardiographic dynamic topological differences; and determining whether the current classification should be used as the final result, or whether to use the next feature for further discrimination, based on the relationship between the global confidence score and the local confidence scores of the corresponding features. This invention more comprehensively depicts the dynamic changes of ECG signals and fully utilizes the multi-dimensional information of the signals. This multi-level feature extraction strategy can more comprehensively characterize the properties of ECG signals under different physiological and pathological states; the introduction of a multi-stage mechanism, utilizing the collaborative verification and dynamic decision-making of global and local confidence scores, significantly improves the reliability of the classification results and effectively avoids misjudgments.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of pattern recognition technology, specifically relating to a multi-level, multi-stage electrocardiogram signal classification and recognition method, system, and device. Background Technology

[0002] Traditional electrocardiogram (ECG) signal classification methods typically rely on feature extraction in the time or frequency domains, such as morphological features or spectral analysis of ECG waveforms. However, as a non-stationary temporal physiological signal, ECG signals exhibit diverse characteristics not only in the time and frequency domains but also contain rich dynamic information. Existing methods often utilize single-dimensional feature extraction, which fails to comprehensively characterize the signal's inherent complex structure, thus limiting the accuracy and robustness of classification. Furthermore, these methods have not fully utilized the differences in dynamic characteristics exhibited by the signal under different physiological and pathological states. Against this backdrop, how to introduce multi-level feature analysis into the classification process and combine it with dynamic characteristics to improve the ability to identify complex patterns remains a key problem that urgently needs to be solved in current research. Summary of the Invention

[0003] The purpose of this invention is to overcome the aforementioned problems and provide a more effective and convenient multi-stage electrocardiogram signal classification and recognition method by extracting multi-level features of the signal.

[0004] To solve the above problems, the specific technical solution of the present invention is achieved through the following steps:

[0005] Step 1: Collect the subject's surface electrocardiogram signal, construct time-domain features, frequency-domain features, and electrocardiographic dynamic features, and input the three types of features into a preset neural network model to calculate their local confidence.

[0006] 1-1. Calculate and construct the time-domain features, frequency-domain features, and electrocardiographic dynamic features respectively;

[0007] 1-2. After normalizing the three types of feature vectors, input them into a preset neural network model to calculate their local confidence.

[0008] Step 2: Calculate the global confidence level based on the topological differences in electrocardiogram dynamics;

[0009] 2-1. Based on the classification system of electrocardiographic dynamic characteristics, calculate the in-class centers of each category;

[0010] 2-2. Quantify the electrokinetic topological differences between the subjects and the centers of each category, and calculate the global confidence score based on the electrokinetic topological differences;

[0011] Step 3: Based on the relationship between the global confidence score and the local confidence score of the corresponding feature, determine whether the current classification should be used as the final result, or whether to use the next feature for further discrimination.

[0012] 3-1. Calculate the relationship between local confidence and global confidence based on temporal features to determine the reliability of the current classification. If the consistency criterion is met, output the final result; otherwise, continue the judgment using the following features.

[0013] 3-2. Calculate the relationship between local confidence and global confidence based on frequency domain features to determine the reliability of the current classification. If the consistency criterion is met, the final result is output; otherwise, continue the judgment using the following features.

[0014] 3-3. Electrocardiographic dynamic characteristics can effectively reflect the differences between deep-level categories, serving as the final judgment basis and directly outputting the final result.

[0015] Preferably, the result is directly output using electrocardiographic dynamics characteristics, for the following reasons:

[0016] Features extracted based on electrocardiographic dynamics have high reliability and uniqueness, and can effectively identify the category to which the subject belongs. Therefore, the category to which the subject belongs can be directly output using this feature.

[0017] Furthermore, the present invention also provides a multi-level, multi-stage electrocardiogram signal classification and recognition system, comprising:

[0018] Data acquisition module: Acquires surface electrocardiogram signals from the subjects;

[0019] Feature extraction module: Based on the surface electrocardiogram signals acquired by the data acquisition module, time-domain features, frequency-domain features, and electrocardiographic dynamic features are constructed.

[0020] Confidence calculation module: Input the three types of features into the preset neural network model respectively, calculate the local confidence of the corresponding features; at the same time, calculate the global confidence based on the electrocardiographic topological differences;

[0021] The judgment module prioritizes time-domain features, frequency-domain features, and electrocardiographic features. Based on the relationship between global confidence and the local confidence of the corresponding feature, it determines whether the current classification should be used as the final result, or whether the next priority feature should be used for discrimination. Specifically:

[0022] First, the relationship between local confidence and global confidence is calculated based on time-domain features to determine whether the current classification is reliable. If the consistency criterion is met, the final result is output; otherwise, the frequency-domain features are used to continue the judgment.

[0023] Secondly, the relationship between local confidence and global confidence is calculated based on frequency domain features to determine whether the current classification is reliable; if the consistency criterion is met, the final result is output; otherwise, electrocardiographic dynamic features are used to continue the judgment.

[0024] Finally, the electrocardiographic features can effectively reflect the differences between deep-level categories, serving as the final judgment criterion and directly outputting the final result.

[0025] Furthermore, the present invention also provides a multi-level, multi-stage electrocardiogram (ECG) signal classification and recognition device, which incorporates a multi-level, multi-stage ECG signal classification and recognition system.

[0026] Compared with using only a single-dimensional feature, the present invention has the following advantages and beneficial effects:

[0027] 1. This invention comprehensively characterizes the dynamic changes of electrocardiogram (ECG) signals by simultaneously extracting time-domain features, frequency-domain features, and electrocardiographic dynamic features, making full use of the multi-dimensional information of the signals. This multi-level feature extraction strategy can more comprehensively represent the characteristics of ECG signals under different physiological and pathological states, thereby significantly improving the accuracy and robustness of classification.

[0028] 2. This invention introduces a multi-stage mechanism, utilizing collaborative verification and dynamic decision-making based on global and local confidence levels. When a certain level of features is insufficient for reliable classification, the system automatically introduces deeper-level features for further discrimination. This method significantly improves the reliability of classification results, especially in complex or ambiguous ECG signal scenarios, effectively avoiding misjudgments and ensuring the accuracy of the final output. Attached Figure Description

[0029] Figure 1 This is a flowchart of a multi-level, multi-stage electrocardiogram signal classification and recognition method proposed in this invention.

[0030] Figure 2 This is a schematic diagram of the start, end, and peak points of the P wave, QRS complex, and T wave in the ECG signal localization lead in the embodiment.

[0031] Figure 3 This is a visualization diagram of the frequency domain characteristics of the same lead in different categories in the example.

[0032] Figures 4(a) and 4(b) are schematic diagrams of the electrocardiographic features extracted from different categories of V4, V5, and V6 leads in the embodiments. Detailed Implementation

[0033] The present invention will be further described in detail below with reference to the embodiments and accompanying drawings, but the embodiments of the present invention are not limited thereto.

[0034] like Figure 1 As shown, a multi-level, multi-stage electrocardiogram (ECG) signal classification and recognition method includes the following steps:

[0035] Step 1: Collect surface electrocardiogram (ECG) signals from the subject, construct time-domain features, frequency-domain features, and electrocardiographic dynamic features, and input these three types of features into a preset neural network model to calculate their local confidence scores. This specifically includes the following steps:

[0036] 1-1 The time-domain features, frequency-domain features, and electrocardiographic dynamic features are calculated and constructed respectively. The specific process is as follows:

[0037] First, the temporal features are constructed, specifically through the following steps:

[0038] (1) Identify and locate the start, end, and peak points of the P wave, QRS complex, and T wave in each lead. Specific location points are as follows: Figure 2 As shown, the corresponding timing and voltage amplitude information is obtained, as detailed below:

[0039] QRS group detection and localization, obtaining the R peak, Q point, and S point respectively, denoted as n. R n Q n S ;

[0040] The R-peak is located using the signal envelope and a sliding window, and the calculation formula is as follows:

[0041]

[0042] τ current =α·max(e[n win ])+(1-α)·τ previous

[0043] n R ={n|e[n]>τ current ∧e[n]=max(e[nk:n+k])}

[0044] Where e[n] represents the signal envelope calculation, Let x[n] represent the Hilbert transform, x[n] be the ECG signal, and τ be the Hilbert transform. current The dynamic threshold is α = 0.1, the forgetting factor is n. win Here is the set of sliding window indices; k represents the sliding window interval;

[0045] Points Q and S are obtained by searching before and after the R peak, and the calculation formula is as follows:

[0046]

[0047] Where |x[n]| is the amplitude of the signal at index n, β∈[0.15,0.25], m=20; It is an indicator function; it returns 1 if the condition is met and 0 if the condition is not met.

[0048] P-wave detection and localization, in n Q The previous search for the P-peak is denoted as n. P The specific calculation formula is as follows:

[0049]

[0050] The constraints are as follows:

[0051]

[0052] Where, Δx[n P ] indicates that the signal is at n P The change at a given point, Δt, represents the time interval and depends on the sampling frequency f. s ,

[0053] T-wave detection and localization, in n S The search for T peaks is denoted as n. T The specific calculation formula is as follows:

[0054]

[0055] The constraints are as follows:

[0056]

[0057] (2) The time-domain features consist of time span features, amplitude span features, and electric axis features. The specific components of the three types of features are as follows:

[0058] The time span characteristic d1 is determined by the coefficient of variation Rab of the RR interval in lead II. II Number of long RR intervals (RC) II Heart rate (HR), slope of ST segment depression in lead V5 (HR, STn) V5 Composition, the time span characteristic is represented as d1={Rab II ,RC II ,HR,STn V5};

[0059] The amplitude span characteristic d2 is determined by the R-wave peak value AR corresponding to leads I, III, aVL, and V1. I AR III AR aVL AR V1 The peak S wave AS values ​​corresponding to leads II, III, and V1 II AS III AS V1 The ratio of the peak R wave value to the peak S wave value in lead V1 (ARS)v1 The sum of the peak value of the R wave in lead aVL and the peak value of the S wave in lead V3 is AR. aVL+V3 Does P-wave reversal occur? retro Composition, ultimately forming the feature vector:

[0060] d2=[AR I AR III AR aVL AR V1 AS II AS III AS V1 ,ARS v1 ,ARS aVL+V3 ,P retro ];

[0061] in,

[0062] in, The direction of the QRS dominant wave is given by f, where Δn represents the duration. s The frequency of the acquired ECG signal is represented by sgn, which is the sign function used to determine the polarity of the signal. When x[n] > 0, sgn(x[n]) = 1; when the latter three conditions are met, it is recorded as a P-wave reversal. retro =1;

[0063] The electric axis feature d3 consists of the electric axis angle α and its classification label c, ultimately forming a feature vector: d3 = [α, c]. The specific calculation is as follows:

[0064]

[0065] AR I AR III These represent the R peak values ​​at the same time in leads I and III of the ECG signal, respectively.

[0066] The above features are combined into a time-domain feature vector. X1 = {d1, d2, d3}, where d = 3 represents a three-dimensional vector.

[0067] Next, frequency domain features are constructed, specifically through the following steps:

[0068] (1) Extract typical heartbeat characteristics from lead L. The specific calculations are as follows:

[0069]

[0070] in, T represents the signal value of lead L at index m in the k-th cycle; L K represents the set of all cycles of a lead.L The total number of cycles for lead L; Let m be the signal value of the heartbeat feature at index m. M = 0.6f s .

[0071] (2) Based on the extracted typical heartbeat characteristics Calculate the frequency domain characteristics S of lead L. L (2) Based on the extracted typical heartbeat features Calculate the frequency domain characteristics S of lead L. L The specific calculations are as follows:

[0072]

[0073] in, The sampling interval; for The time-frequency transformation is specifically calculated as follows: j is the time index j = 0, 1, ..., M-1, and the discretized time point τ is... j =jT s ; n is the frequency index n = 0, 1, ..., M-1, the discretized frequency domain points It is a discrete Gaussian window, the width of which varies with frequency n;

[0074] The specific calculations are as follows:

[0075]

[0076] in, The sampling interval; for The time-frequency transformation is specifically calculated as follows: j is the time index j = 0, 1, ..., M-1, and the discretized time point τ is... j =jT s ; n is the frequency index n = 0, 1, ..., M-1, the discretized frequency domain points It is a discrete Gaussian window, the width of which varies with frequency n.

[0077] (3) For each lead L∈{I,II,III,aVR,aVL,aVF,V1,V2,V3,V4,V5,V6}, repeat steps (1) and (2) to finally obtain 12 M×M complex matrices, which constitute the frequency domain feature X2={S I ,S II ,…,S V6}

[0078] Finally, the electrocardiographic dynamics features are constructed, specifically through the following steps:

[0079] (1) Modeling nonlinear electrocardiographic dynamics:

[0080]

[0081] Where, V = [x I ,x II ,…,x V6 ] T The original 12-lead signal is given, and z is the model parameter. F(V;z) is the main component of the nonlinear dynamics, and l(V;z) represents the uncertainty term of the model. F(V;z) and l(V;z) together constitute the complete nonlinear electrocardiographic dynamics model. Since l(V;z) is indivisible in some cases, the complete electrocardiographic dynamics model is represented by φ(V;z):=F(V;z)+l(V;z).

[0082] (2) An adaptive co-learner is used to learn the model. The learning expression of this learner is as follows:

[0083]

[0084] in, A represents the state variable in the adaptive learner; A = diag(a I ,a II ,…,a V6 ) is the stable feedback gain matrix, a i The value range of is [-1, 1]; S is the weight vector corresponding to the k-th neuron; k (V) is the Gaussian kernel function, defined as follows:

[0085]

[0086] Among them, c k σ represents the center of the k-th kernel function. k (t) represents the corresponding adaptive kernel width; the number and distribution of kernel functions determine the sensing range and resolution of the entire network.

[0087] (3) In the adaptive collaborative learner, the weight update rule adopts the form of error feedback driving, and is expressed as follows:

[0088]

[0089] in, It is the learning gain matrix of the neuron, λ k >0 is the regularization decay coefficient, used to suppress excessive weight growth; S represents the state error, which drives the neuron to update along the error direction.k (V) is the Gaussian kernel function. It is the weight vector corresponding to the k-th neuron;

[0090] Meanwhile, the width σ of each kernel function k (t) adopts the following adaptive update rule:

[0091]

[0092] Where, η k >0 is the learning rate for updating the kernel width. This update mechanism can dynamically adjust the response region of each neuron to adapt to non-stationary changes in electrocardiogram signals. Vc represents the variance of the Gaussian kernel function, controlling the response range of the k-th kernel function; k This indicates the relationship between the current ECG signal V and the center c of the k-th kernel function. k The difference measures how close the signal is to the center of the nucleus;

[0093] (4) When the adaptive collaborative learner's learning tends to converge, electrocardiographic features are extracted from the network. The main calculation formula is as follows:

[0094]

[0095] in, For complete nonlinear electrocardiographic dynamics information; S(V) represents the mean weights after convergence, indicating the contribution coefficient of the i-th output dimension; S(V) = [S1(V), S2(V), ..., S... M (V)] T It is the kernel function response vector output by all neurons; Each neuron learns the electrocardiographic dynamic characteristics from the electrocardiographic parameter trajectory; ∈ i This represents the learning error. As shown in Figures 4(a) and 4(b), since 12 dimensions are too high and difficult to present in the image, in this example, the electrocardiographic feature signals of leads V4, V5, and V6 are selected to present a three-dimensional schematic diagram. Figure 4(a) shows a ring shape, while Figure 4(b) shows a discrete state. It can be seen that different categories of electrocardiographic features present different forms of expression.

[0096] Finally, it constitutes the electrocardiographic characteristics.

[0097] 1-2 After normalizing the three types of feature vectors, they are input into a preset neural network model to calculate their local confidence scores. The specific calculation is as follows:

[0098] After normalizing the constructed three types of feature vectors X1, X2, and X3, they are input into a pre-defined neural network model, and the local confidence scores are obtained through the output layer. The specific calculations are as follows:

[0099]

[0100] Among them, W l b is the weight matrix of the l-th layer. l It is a bias vector, which is output as h after passing through a neural network with l layers. last ;P(c j |X i Let z represent the probability distribution calculated from the eigenvectors of the i-th class; j The output layer of the neural network corresponds to category c. j The activation value, where C is the total number of categories; Predict the class index for the i-th class feature vector; The local confidence level is calculated for the i-th type of feature vector.

[0101] Step 2: Calculate the global confidence score based on the electrocardiographic topological differences, which includes the following steps:

[0102] 2-1. Based on the classification system of electrocardiographic dynamic characteristics, calculate the in-class centers of each category. The specific calculation is as follows:

[0103] Based on electrocardiographic characteristics, calculate the in-class centers for each category, specifically as follows: Represents the in-class center of the k-th class, where, N k This represents the number of samples in the k-th class; This indicates that the i-th sample of the k-th class is at lead L and time point t. j The electrodynamic eigenvalues; the complete class center matrix is ​​as follows:

[0104]

[0105] (1) For a single lead L, the new sample feature sequence is: The central feature of class k is For a single lead L only, the mathematical definition of the electrodynamic topological difference between the new sample and the k-th class central feature is:

[0106]

[0107] The goal of describing electrocardiographic topological differences is to find a path from all possible alignment paths that minimizes the sum of local differences between the new sample sequence and the class center sequence.

[0108] in, This represents the local difference at the current time point, specifically calculated as follows: alignment represents all possible alignment paths;

[0109] The specific calculation requires initializing the cumulative distance matrix, i.e. in Then, recursive calculations were performed to obtain the overall electrodynamic topological differences.

[0110]

[0111] Where D[i,j] represents the value of the cumulative distance matrix at (i,j); i represents the feature sequence of the new sample. The i-th time point; j represents the k-th class central feature sequence. The j-th time point; D[i-1,j] represents moving along the new sample sequence; D[i,j-1] represents moving along the class center sequence; D[i-1,j-1] represents moving along the diagonal; D[T,T] is the lower right element of the matrix, i.e., the electrocardiographic topological difference;

[0112] Therefore, the overall electrodynamic topological differences for the 12-lead ECG are as follows:

[0113]

[0114] ε (k) This represents the electrokinetic topological difference between the new sample and the center of class k;

[0115] (2) The topological differences in electrocardiographic dynamics ε (k) Convert to similarity S k as follows:

[0116]

[0117] Where σ is the scale parameter, controlling the similarity decay rate; S k ∈[0,1] represents the new sample X new With the k-th class center k The similarity; therefore, based on k similarity values ​​S k This expresses the global confidence level C. g,k as follows:

[0118]

[0119] Among them, C g,k This represents the global confidence level that a new sample belongs to the k-th class.

[0120] Step 3: Based on the relationship between the global confidence score and the local confidence score of the corresponding feature, determine whether the current classification should be used as the final result, or whether to use the next feature for further discrimination. The specific implementation steps are as follows:

[0121] 3-1. Calculate the relationship between local confidence and global confidence based on time-domain features to determine the reliability of the current classification. If the consistency criterion is met, the final result is output; otherwise, continue the judgment using the following features, specifically as follows:

[0122] A high threshold θ1 = 0.8 and a low threshold θ2 = 0.2 are introduced to measure the reliability of the confidence level; δ = 1.0 is introduced to represent the entropy threshold of the global confidence level distribution to evaluate the stability of the pattern.

[0123] Local confidence level calculated from time-domain features With global confidence when and At times, there are local data contradictions; when and When the class center is not representative or the sample deviates from all classes; and The features cannot distinguish the category, the data quality is poor, or the sample is an outlier; when But entropy H = -∑ k C g,k logC g,k >δ indicates high global confidence, but with similar confidence levels across multiple categories, suggesting an unclear pattern. This indicates that the feature cannot accurately identify the subject's category, so we should move on to a more reliable feature for classification. Only when... and This indicates that the classification result is highly reliable, and the category to which the subject belongs is directly output.

[0124] in This indicates the category predicted using time-domain features; Indicates that the subject is in Global confidence level by category; This represents the local confidence level of the subjects in classifying the data based on time-domain features.

[0125] 3-2. Calculate the relationship between local confidence and global confidence based on frequency domain features to determine the reliability of the current classification. If the consistency criterion is met, the final result is output; otherwise, continue the judgment using the following features, specifically as follows:

[0126] Local confidence level calculated from frequency domain features With global confidence when and At times, there are local data contradictions; when and When the class center is not representative or the sample deviates from all classes; and The features cannot distinguish the category, the data quality is poor, or the sample is an outlier; when But entropy H = -∑ k C g,k logC g,k >δ indicates high global confidence, but with similar confidence levels across multiple categories, suggesting an unclear pattern. This indicates that the feature cannot accurately identify the subject's category, so we should move on to a more reliable feature for classification. Only when... and This indicates that the classification result is highly reliable, and the category to which the subject belongs is directly output.

[0127] in This represents the category predicted using frequency domain features; Indicates that the subject is in Global confidence level by category; This represents the local confidence level of the subjects in classifying the data using frequency domain features.

[0128] 3-3. Electrocardiographic dynamic characteristics can effectively reflect the differences between deeper categories and serve as the final judgment basis, directly outputting the final result. The specific reasons are as follows:

[0129] Features extracted based on electrocardiographic dynamics have high reliability and uniqueness, and can effectively identify the category to which the subject belongs. Therefore, the category to which the subject belongs can be directly output using this feature.

[0130] In summary, this multi-level, multi-stage classification and recognition method can quickly distinguish significantly different categories using time-domain features, with 65% of the total samples being identified as suitable for output, achieving a 96% accuracy rate in ECG category recognition. For categories where the distinction is uncertain, further frequency-domain features are used for classification, again identifying 23% of the total samples as suitable for output, achieving a 94% accuracy rate in ECG category recognition. Finally, ECG dynamic features are used for final classification, achieving a 91% accuracy rate in ECG category recognition.

[0131] The above embodiments are preferred embodiments of the present invention, but the embodiments of the present invention are not limited to the above embodiments. Any changes, modifications, substitutions, combinations, or simplifications made without departing from the spirit and principle of the present invention shall be considered equivalent substitutions and shall be included within the protection scope of the present invention.

Claims

1. A multi-level, multi-stage electrocardiogram (ECG) signal classification and recognition method, characterized in that, It includes the following steps: Step 1: Collect the subject's surface electrocardiogram signal, construct time-domain features, frequency-domain features, and electrocardiographic dynamic features, input the three types of features into the preset neural network model, and calculate the local confidence of the corresponding features; Step 2: Calculate the global confidence level based on the topological differences in electrocardiogram dynamics; Step 3: Prioritize time-domain features, frequency-domain features, and electrocardiographic features. Determine whether the current classification should be used as the final result, or whether the next priority feature should be used, based on the relationship between the global confidence score and the local confidence score of the corresponding feature. 3-1. Calculate the relationship between local confidence and global confidence based on temporal features to determine whether the current classification is reliable; if the consistency criterion is met, the output is the final result; otherwise, continue the judgment using the following features. 3-2. Calculate the relationship between local confidence and global confidence based on frequency domain features to determine whether the current classification is reliable; if the consistency criterion is met, the output is the final result; otherwise, continue the judgment using the following features. 3-3. Electrocardiographic dynamic characteristics can effectively reflect the differences between deep-level categories, serving as the final judgment basis and directly outputting the final result.

2. The multi-level, multi-stage electrocardiogram signal classification and recognition method according to claim 1, wherein in step one, the characteristic is that... The temporal features are constructed as follows: (1) Identify and locate the start, end, and peak points of the P wave, QRS complex, and T wave in each lead, and obtain the corresponding timing and voltage amplitude information, as follows: QRS group detection and localization were performed, and the R peak, Q point, and S point were obtained and denoted as follows: ; The R-peak is located using the signal envelope and a sliding window, and the calculation formula is as follows: in, For signal envelope calculation, Represents the Hilbert transform. ECG signal For dynamic thresholds, Forgetting factor, For the sliding window index set; Indicates the sliding window range; Points Q and S are obtained by searching before and after the R peak, and the calculation formula is as follows: in, The amplitude of the signal at index n. m=20; It is an indicator function; it returns 1 if the condition is met and 0 if the condition is not met. P-wave detection and localization, in Previous search for P-peak record The specific calculation formula is as follows: The constraints are as follows: in, Indicates the signal at The change at that point The time interval is determined by the sampling frequency. , ; T-wave detection and localization, in The search for T-peaks was recorded as follows The specific calculation formula is as follows: The constraints are as follows: (2) The time-domain features consist of time span features, amplitude span features, and electric axis features. The specific components of the three types of features are as follows: Time span characteristics Depend on coefficient of variation of RR interval in leads Number of long RR intervals Heart rate , The slope of ST segment depression in leads Composition, time span characteristics are represented as ; Amplitude span characteristics Depend on R-wave peak value corresponding to lead , S-wave peak value corresponding to the lead The ratio of the peak value of the R wave to the peak value of the S wave in lead V1 The sum of the peak value of the R wave in lead aVL and the peak value of the S wave in lead V3 Does P-wave reversal occur? Composition, ultimately forming the feature vector: ; in, in, The direction of the QRS main wave. express , Indicates the frequency at which the electrocardiogram (ECG) signal is collected. The sign function is used to determine the polarity of a signal. hour, When the last three conditions are met, it is recorded as a P-wave reversal. ; Electric axis characteristics From the electric axis angle and its category tags Composition, ultimately forming the feature vector: The specific calculations are as follows: in They represent In the signal Leads and Leads, peak R value at the same time; The above features are combined into a time-domain feature vector. , ,in Represents a three-dimensional vector.

3. The multi-level, multi-stage electrocardiogram signal classification and recognition method according to claim 2, characterized in that, The construction of the frequency domain features specifically includes the following steps: (1) Extract leads Typical heartbeat characteristics The specific calculations are as follows: in, Indicates lead In the index The first The signal value for one cycle; This represents the set of all cycles for a lead. For leads The total number of cycles; For heartbeat features in the index The signal value at that location, , ; (2) Based on the extracted typical heartbeat characteristics Calculate the leads Frequency domain characteristics The specific calculations are as follows: in, The sampling interval; for The time-frequency transformation is specifically calculated as follows: ; For time index Discretization time point ; Frequency Index Discretized frequency domain points ; It is a discrete Gaussian window, the width of which varies with frequency. change; (3) For each lead Repeat steps (1) and (2) to obtain 12 in total. Complex matrices constitute frequency domain features .

4. The multi-level, multi-stage electrocardiogram signal classification and recognition method according to claim 2, characterized in that, The construction of the electrocardiographic dynamics features specifically includes the following steps: (1) Modeling nonlinear electrocardiographic dynamics; (2) An adaptive co-learner is used to learn the model; (3) In the adaptive collaborative learner, the weight update rule adopts the form of error feedback driving, and is expressed as follows: in, It is the learning gain matrix of the neuron. This is the regularization decay coefficient, used to suppress excessive weight growth; This represents the state error, driving neurons to update along the error direction. For Gaussian kernel function, It is the first The weight vector corresponding to each neuron; At the same time, the width of each kernel function The following adaptive update rules are adopted: in, The learning rate is updated to the kernel width, and this update mechanism can dynamically adjust the response region of each neuron to adapt to non-stationary changes in electrocardiogram signals. The variance of the Gaussian kernel function is used to control the first... The response range of each kernel function; Indicates the current ECG signal With the Kernel function center The difference measures how close the signal is to the center of the nucleus; (4) When the adaptive collaborative learner's learning tends to converge, electrocardiographic features are extracted from the network. The main calculation formula is as follows: in, For complete nonlinear electrocardiographic dynamics information; It is the mean of the weights after learning convergence, representing the first... The contribution coefficient of each output dimension; It is the kernel function response vector output by all neurons; The electrodynamic characteristics learned by each neuron from the trajectory of electrocardiogram parameters; Indicates learning error; Finally, it constitutes the electrocardiographic characteristics. .

5. The multi-level, multi-stage electrocardiogram signal classification and recognition method according to claim 2, characterized in that, The calculation of local confidence is as follows: The three types of feature vectors constructed After normalization, the data are input into a pre-defined neural network model, and the local confidence level is obtained through the output layer. The specific calculations are as follows: in, It is the first The weight matrix of the layer, It is a bias vector, after The output of the layered neural network ; Represented as the first The probability distribution calculated from the class feature vectors; The output layer of the neural network corresponds to the category activation value, The total number of categories; For the first Predicting class index from class feature vectors; For the first The local confidence level calculated from the class feature vectors.

6. The multi-level, multi-stage electrocardiogram signal classification and recognition method according to claim 1, characterized in that, Step two specifically includes the following steps: 2-1. Based on the classification system of electrocardiographic dynamic characteristics, calculate the in-class centers of each category; 2-2. Quantify the electrokinetic topological differences between the subjects and the centers of each category, and calculate the global confidence score based on the electrokinetic topological differences; Step 2-1, based on the obtained electrocardiographic dynamic characteristics, calculates the in-class centers for each category, specifically as follows: , Representing the The class center within the class, where, , Indicates the first Number of samples in the class; Indicates the first Class 1 One sample in the lead Time point The electrodynamic eigenvalues; the complete class center matrix is ​​as follows: 。 7. The multi-level, multi-stage electrocardiogram signal classification and recognition method according to claim 6, characterized in that, Step 2-2, global confidence calculation, specifically includes the following steps: (1) For a single lead The new sample feature sequence is , No. Class center features are For a single lead only The new sample and the first The mathematical definition of class-centric electrodynamic topological differences is: The goal of describing electrocardiographic topological differences is to find a path from all possible alignment paths that minimizes the sum of local differences between the new sample sequence and the class center sequence. in, This represents the local difference at the current time point, specifically calculated as follows: ; Indicates all possible alignment paths; The specific calculation requires initializing the cumulative distance matrix, i.e. ,in Then, recursive calculations were performed to obtain the overall electrodynamic topological differences. : in, Indicates the cumulative distance matrix in The value; Represents the feature sequence of the new sample The A point in time; Indicates the first Class center feature sequence The A point in time; This indicates moving forward along the new sample sequence; This indicates progressing along the class center sequence; Indicates moving diagonally; The element in the bottom right corner of the matrix represents the topological difference in electrocardiographic dynamics. Therefore, the overall electrodynamic topological differences for the 12-lead ECG are as follows: Indicates the new sample and the first Electrodynamic topological differences at class centers; (2) Topological differences in electrocardiographic dynamics Convert to similarity as follows: in, This is a scale parameter that controls the rate of similarity decay. Indicates new sample With the Class Center Similarity; therefore, based on Similarity Expressing global confidence as follows: in, This indicates that the new sample belongs to the first... Global confidence level of the class.

8. The multi-level, multi-stage electrocardiogram signal classification and recognition method according to claim 1, characterized in that, In step three, the consistency determination of the local confidence and global confidence of the time-domain features is as follows: Introducing a high threshold low threshold This is used to measure the reliability of confidence levels; [Introduction] The entropy threshold representing the global confidence distribution is used to assess pattern stability. Local confidence level calculated from time-domain features With global confidence ,when and At times, there are local data contradictions; when and When the class center is not representative or the sample deviates from all classes; and The features cannot distinguish the category, the data quality is poor, or the sample is an outlier; when But entropy This indicates high global confidence, but with similar confidence levels across multiple categories, suggesting an unclear pattern. The presence of this pattern indicates that the feature cannot accurately identify the subject's category, so the system will move to a more reliable feature for classification. Only when... and This indicates that the classification result is highly reliable and directly outputs the category to which the subject belongs. ; in This indicates the category predicted using time-domain features; Indicates that the subjects are Global confidence level by category; This represents the local confidence level of the subjects in classifying the data based on time-domain features.

9. The multi-level, multi-stage electrocardiogram signal classification and recognition method according to claim 1, characterized in that, The consistency determination of the local confidence and global confidence of the frequency domain features is as follows: Local confidence level calculated from frequency domain features With global confidence ,when and At times, there are local data contradictions; when and When the class center is not representative or the sample deviates from all classes; and The features cannot distinguish the category, the data quality is poor, or the sample is an outlier; when But entropy This indicates high global confidence, but with similar confidence levels across multiple categories, suggesting an unclear pattern. The presence of this pattern indicates that the feature cannot accurately identify the subject's category, so the system will move to a more reliable feature for classification. Only when... and This indicates that the classification result is highly reliable and directly outputs the category to which the subject belongs. ; in This represents the category predicted using frequency domain features; Indicates that the subjects are Global confidence level by category; This represents the local confidence level of the subjects in classifying the data using frequency domain features.