Arrhythmia classification method, device, equipment, medium and product using ECG signal

By using the BERT model and twin tower layer structure to process ECG data and patient routine data, extracting and combining feature vectors, the problem of insufficient accuracy and robustness of the incomplete classification diagnosis of central laws in the prior art is solved, and a higher level of classification accuracy and adaptability.

CN119480073APending Publication Date: 2025-02-18PEKING UNION MEDICAL COLLEGE +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411554086.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-01
Publication Date
2025-02-18

AI Technical Summary

Technical Problem

When using ECG signals to diagnose cardiac arrhythmia, there are problems with insufficient accuracy and robustness of classification diagnosis, especially in the case of large individual differences, traditional methods rely on expert experience and are not suitable for large-scale screening. , Machine Learning-based methods require a large amount of data labeling and weak robustness in the diagnosis and judgment of abnormal data.

Method used

Using the BERT model and twin double tower layer structure, ECG data and patient routine data are input into the BERT model to obtain semantic information vectors, and then these vectors are input into the double tower layer to extract the eigenvectors, and feature combinations are performed by calculating the correlation coefficient, and finally The combined features are input to the classification model to achieve a classification diagnosis of arrhythmia.

Benefits of technology

It improves the accuracy and robustness of cardiac arrhythmia classification, can better adapt to individual differences, reduce dependence on expert experience, and achieve higher diagnostic accuracy without requiring a large amount of labeled data.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119480073A_ABST
    Figure CN119480073A_ABST
Patent Text Reader

Abstract

The invention discloses an arrhythmia classification method and device using ECG signals, equipment, a medium and a product, and relates to the field of arrhythmia classification, and the method comprises the steps: obtaining ECG data and conventional data of a patient; constructing a first BERT model and a second BERT model; inputting the ECG data and the patient routine data into a first BERT model and a second BERT model to obtain a first semantic information vector and a second semantic information vector; constructing a first tower layer and a second tower layer; inputting the first semantic information vector and the second semantic information vector into a first tower layer and a second tower layer respectively to obtain a first feature vector and a second feature vector; calculating a correlation coefficient based on the first feature vector and the second feature vector; performing feature combination on the first feature vector, the second feature vector and the correlation coefficient to obtain a combined feature; constructing a classification model; and inputting the combined features into a classification model to obtain a classification category of the arrhythmia. According to the scheme, the accuracy of arrhythmia classification can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of arrhythmia classification, and in particular to a method, device, equipment, medium and product for arrhythmia classification using ECG signals. Background Art

[0002] With the introduction and development of computer neural networks and large models, various cardiovascular diseases are constantly being judged by the application of deep learning and other models, and certain research results have been achieved. However, due to the individual differences caused by specific types of arrhythmia, classification and diagnosis are difficult, and it is difficult for humans to make regular judgments based on the potential characteristics of the data, and it is limited by the generalization ability and accuracy of deep learning and existing models in the disease of arrhythmia.

[0003] The main existing technologies for diagnosing arrhythmias using ECG signals include traditional methods and machine learning-based methods. Traditional methods include manual analysis, rules or threshold definition, etc. Manual analysis requires manual interpretation by cardiologists, who conduct screening and diagnosis based on experience by observing the morphology, interval and amplitude of the P wave, QRS complex and T wave. Not to mention the time-consuming and labor-intensive nature of the method, which relies on expert experience and may have subjective errors or misjudgments, it is not suitable for large-scale screening or diagnosis. The rule-based and threshold-based methods automatically determine whether the RR interval and PR interval are arrhythmias when determining whether the heart rhythm is irregular. Obviously, in the case of individual differences, the threshold or rule is inaccurate and lacks adaptability. It cannot ensure the processing of complex arrhythmias and cannot guarantee accuracy and robustness. The machine learning-based method first extracts features from the ECG signal, such as heart rate variability, waveform morphology features, waveform change features, etc., and then combines classification algorithms, such as support vector machines, decision trees, random forests, etc., to classify and diagnose arrhythmias. The most serious flaw of this process is that it relies on experts in the field of cardiology. The feature selection and model performance are sensitive to data distribution and require a large amount of labeled data for training. In addition, the diagnosis and judgment of abnormal unlabeled data are weakly robust.

[0004] Therefore, the present invention proposes a method, device, equipment, medium and product for classifying arrhythmia using ECG signals. Summary of the invention

[0005] The purpose of the present application is to provide a method, device, equipment, medium and product for classifying arrhythmia using ECG signals, which can improve the accuracy of arrhythmia classification.

[0006] To achieve the above objectives, this application provides the following solutions:

[0007] In a first aspect, the present application provides a method for classifying arrhythmia using ECG signals, comprising:

[0008] Obtain ECG data and routine patient data;

[0009] Build the first BERT model and the second BERT model;

[0010] Inputting the ECG data and the patient's routine data into a first BERT model and a second BERT model to obtain a first semantic information vector and a second semantic information vector;

[0011] Construct the first tower layer and the second tower layer;

[0012] Inputting the first semantic information vector and the second semantic information vector into the first tower layer and the second tower layer respectively to obtain a first feature vector and a second feature vector;

[0013] Calculating a correlation coefficient based on the first eigenvector and the second eigenvector;

[0014] Performing feature combination on the first feature vector, the second feature vector and the correlation coefficient to obtain a combined feature;

[0015] Build a classification model;

[0016] The combined features are input into the classification model to obtain the classification category of arrhythmia.

[0017] Optionally, the patient's routine data includes age, gender, height and weight;

[0018] The ECG data includes conventional ECG data and lead data distribution. The conventional ECG data includes: QRS duration, PR interval, PT interval, T interval, P interval, QRS wave, T wave, P wave, QRST wave and J point; the lead data distribution includes: wave width and amplitude.

[0019] Optionally, the first tower layer is any one of LSTM, GRU, BiLSTM, BiGRU, CNN, RNN, Transformer, and Attention;

[0020] The second tower layer is any one of LSTM, GRU, BiLSTM, BiGRU, CNN, RNN, Transformer, and Attention.

[0021] Optionally, the correlation coefficient is calculated based on the first eigenvector and the second eigenvector by using any one of cosine similarity, Euclidean distance, Jaccard similarity coefficient, Pearson correlation coefficient, Manhattan distance, Spearman rank correlation coefficient, angle similarity, cosine distance, and Chebyshev distance methods.

[0022] Optionally, the correlation coefficient is calculated based on the first eigenvector and the second eigenvector using the following formula:

[0023] or

[0024] K=cosθ

[0025] Where V1={v1,v2,...,v n} represents the first eigenvector, V2={μ1,μ2,...,μ n} represents the second eigenvector.

[0026] Optionally, the classification model is expressed as:

[0027]

[0028] Among them, ω represents the parameter matrix, that is, the weight vector, T represents the transpose calculation, represents a nonlinear mapping function that maps input features to a high-dimensional space, b represents a bias term, n represents the number of patients, i represents the i-th patient, and y i represents the classification category of the i-th arrhythmia patient, y j represents the classification category of the jth arrhythmia patient, α i represents the Lagrange multiplier (coefficient of the support vector) corresponding to the i-th training sample, i.e., the arrhythmia patient, K(x i ,y j ) represents the kernel function, which is used to calculate the similarity between input features.

[0029] In a second aspect, the present application provides an arrhythmia classification device using ECG signals, comprising:

[0030] A data acquisition module, used to acquire ECG data and patient routine data;

[0031] A BERT model building module, used to build a first BERT model and a second BERT model;

[0032] A semantic information vector determination module, used for inputting the ECG data and the patient's routine data into a first BERT model and a second BERT model to obtain a first semantic information vector and a second semantic information vector;

[0033] A tower layer construction module, used to construct a first tower layer and a second tower layer;

[0034] A feature vector determination module, used for inputting the first semantic information vector and the second semantic information vector into the first tower layer and the second tower layer respectively to obtain a first feature vector and a second feature vector;

[0035] A correlation coefficient calculation module, used for calculating the correlation coefficient based on the first eigenvector and the second eigenvector;

[0036] A feature combination module, used for performing feature combination on the first feature vector, the second feature vector and the correlation coefficient to obtain a combined feature;

[0037] A classification model building module, used to build a classification model;

[0038] The classification module is used to input the combined features into the classification model to obtain the classification category of arrhythmia.

[0039] In a third aspect, the present application provides a computer device comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of any of the above-mentioned methods for classifying arrhythmias using ECG signals.

[0040] In a fourth aspect, the present application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of any one of the above-mentioned methods for classifying arrhythmias using ECG signals.

[0041] In a fifth aspect, the present application provides a computer program product, comprising a computer program, which, when executed by a processor, implements the steps of any one of the above-mentioned methods for classifying arrhythmias using ECG signals.

[0042] According to the specific embodiments provided in this application, this application discloses the following technical effects:

[0043] The present application provides a method, device, equipment, medium and product for classifying arrhythmia using ECG signals, which obtain ECG data and routine patient data; construct a first BERT model and a second BERT model; input the ECG data and routine patient data into the first BERT model and the second BERT model to obtain a first semantic information vector and a second semantic information vector; construct a first tower layer and a second tower layer; input the first semantic information vector and the second semantic information vector into the first tower layer and the second tower layer respectively to obtain a first feature vector and a second feature vector; calculate a correlation coefficient based on the first feature vector and the second feature vector; perform feature combination on the first feature vector, the second feature vector and the correlation coefficient to obtain a combined feature; construct a classification model; input the combined feature into the classification model to obtain a classification category of arrhythmia. The present application applies ECG signals to the diagnostic classification of arrhythmia for the first time, which greatly improves the accuracy of classification. BRIEF DESCRIPTION OF THE DRAWINGS

[0044] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments will be briefly introduced below. 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 paying creative work.

[0045] Figure 1 This is a flow chart of a method for classifying arrhythmia using ECG signals in one embodiment of the present application;

[0046] Figure 2 A flowchart showing a method for classifying arrhythmias using ECG signals provided in one embodiment of the present application;

[0047] Figure 3 A schematic diagram of the relationship between 12-lead data channels provided in an embodiment of the present application;

[0048] Figure 4 A diagram showing the correspondence between the composition of each band of the electrocardiogram of an arrhythmia patient and the ECG signal in the twin towers model provided in an embodiment of the present application;

[0049] Figure 5 This is a schematic diagram of the format of input data input1 and input2 according to an embodiment of the present application;

[0050] Figure 6 This is a schematic diagram of the structure of the first tower layer in one embodiment of the present application;

[0051] Figure 7 This is a schematic diagram of the structure of the second tower layer in one embodiment of the present application;

[0052] Figure 8 This is a schematic diagram of an arrhythmia classification device using ECG signals according to an embodiment of the present application;

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

[0054] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0055] In order to make the above-mentioned objects, features and advantages of the present application more obvious and easy to understand, the present application is further described in detail below with reference to the accompanying drawings and specific implementation methods.

[0056] Figure 1 This is a flow chart of a method for classifying arrhythmia using ECG signals in one embodiment of the present application. Figure 2 A flowchart of a method for classifying arrhythmias using ECG signals provided in an embodiment of the present application specifically includes the following steps:

[0057] Step 101: Obtain ECG data and patient routine data.

[0058] Among them, ECG data is collected by ECG lead collection device or obtained from ECG database. The original device for collecting ECG data is 12 leads, among which the classification of leads and the statistics of data dimensions are as follows Figure 3 shown.

[0059] Patient routine data include but are not limited to age, gender, height, weight, etc., see Table 1 for details. ECG data see Figure 4 , specifically including: QRS duration (average value of QRS duration in milliseconds), PR interval, PT interval, T interval, P interval, QRS wave, T wave, P wave, QRST wave, J point, etc., see Table 2 for details. ECG data also includes two sets of lead data distribution, namely wave width (see Table 3) and amplitude (see Table 4).

[0060] Table 1 Routine data of patients with arrhythmia

[0061] General Features (Chinese) General Features (English) Data Characterization age Age Linear gender Sex (0=male; 1=female),Nominal height Height Height in centimeters, linear weight Weight Weight in kilograms, linear … … …

[0062] Table 2 Routine ECG data of patients with arrhythmia

[0063]

[0064] Table 3 Data of ECG signals of patients with arrhythmia in terms of wave width

[0065]

[0066]

[0067]

[0068]

[0069]

[0070]

[0071]

[0072] Table 4 Data of ECG signals of patients with arrhythmia in amplitude dimension

[0073]

[0074]

[0075]

[0076]

[0077]

[0078] Step 102: Build a first BERT model and a second BERT model.

[0079] The model in this step of the present application can also be a model or method with similar functions to the BERT model, which can achieve embeddability of input data, such as DistilBERT, RoBERT, ALBERT, Word2Vec, etc.

[0080] Based on models or methods that support embeddability such as BERT, semantic feature embedding is constructed using patient routine data and ECG signal data. Models such as BERT support embeddability and can effectively capture the contextual semantic features of ECG signals. They are very sensitive to the complex semantic features of ECG in 12 leads and can understand the potential features between these digital signals.

[0081] Step 103: Input the ECG data and the patient's routine data into the first BERT model and the second BERT model to obtain a first semantic information vector and a second semantic information vector.

[0082] like Figure 5 The data input format and splicing method are: regular data + ECG data + ECG signal data (wave width), regular data + ECG data + ECG signal data (amplitude).

[0083] See Figure 5 Part a and part b in , where PE represents position embedding, AE represents block embedding, and TE represents token embedding.

[0084] Step 104: construct the first tower layer and the second tower layer.

[0085] Specifically, the first tower layer and the second tower layer constitute a twin tower model, and the first tower layer and the second tower layer share the same architecture and parameters. The tower layer design in the twin tower includes but is not limited to LSTM, GRU, BiLSTM, BiGRU, CNN, RNN, Transformer, Attention and other deep learning related neural network models or a combination of two or more models.

[0086] Step 105: Input the first semantic information vector and the second semantic information vector into the first tower layer and the second tower layer respectively to obtain a first feature vector and a second feature vector.

[0087] For example:

[0088] See also Figure 6 , is a schematic diagram of the first tower layer structure. The RNN network structure model is used as an example as the training model of the first tower layer. RNN (Recurrent Neural Network) is a recurrent neural network used to process input1 data. Its neural unit h t The calculation process is as follows, and the output vector is V1:

[0089] h t =f(W hh h t-1 +W xh x t )

[0090] V1=[...,h t-1 ,h t ,h t+1 ,...]

[0091] Take the GRU network structure model as an example as the training model of the second tower layer:

[0092] See also Figure 7 , is the structural diagram of GRU, which is used to calculate the input2 of ECG signal. Its neural unit h t The calculation process is as follows, and the output vector V2

[0093] z t =σ(W z [h t-1 ,x t ])

[0094] r t =σ(W r [h t-1 ,x t ])

[0095]

[0096] V2=[...,h t-1 ,h t ,h t+1 ,...].

[0097] Step 106: Calculate a correlation coefficient based on the first eigenvector and the second eigenvector.

[0098] The correlation coefficient K is calculated based on two feature vectors V1 and V2 of the same dimension generated by the twin tower model. The calculation method of the correlation coefficient K here includes but is not limited to cosine similarity, Euclidean distance, Jaccard similarity coefficient, Pearson Correlation Coefficient, Manhattan distance, Spearman's Rank Correlation Coefficient, Angular Similarity, Cosine Distance, Chebyshev distance and other methods. The purpose of designing the correlation coefficient is to ensure that the overall data of the patient are correlated.

[0099] The following is a detailed introduction to the calculation process of the correlation coefficient using cosine similarity as an example:

[0100] V1 and V2 are two vectors of the same dimension, which are assumed to be n-dimensional here. V1 is expressed as: V1 = {v1, v2, ..., v n}, V2 is expressed as: V2={μ1,μ2,...,μ n}. Then the cosine value θ of the angle between V1 and V2 is equal to:

[0101]

[0102] K=cosθ (3)

[0103] The calculation of the cosine value θ is expressed in two forms: Formula 1 and Formula 2, where Formula 3 is an assignment calculation, and the cosine value θ is expressed as the correlation coefficient of V1 and V2.

[0104] Step 107: Perform feature combination on the first feature vector, the second feature vector and the correlation coefficient to obtain a combined feature.

[0105] Combine features based on V1, V2 and K. The feature combination here includes but is not limited to the following two methods. Method 1: Use the Concat operation between vectors to directly combine the features and obtain F C1 =[V1,V2,K], where F C1 The dimension of is 1*(2m+1). Method 2, use the addition operation between vectors to combine features and get F C2 =[(V1+V2),K], where F C2The feature dimension of is 1*(m+1). Other methods use different calculation methods between vectors to obtain different feature combinations F Ci Although different methods of combining features are used, we finally express it uniformly as F C .

[0106] Step 108: Build a classification model.

[0107] Based on F C A classification diagnosis calculation of arrhythmia is performed, and the classification diagnosis calculation method here includes but is not limited to machine learning and deep learning and other related methods. Further, the classification categories of arrhythmia in patients with cardiovascular diseases include normal, ischemic changes (coronary artery disease), old forearm myocardial infarction, old lower arm myocardial infarction, sinus tachycardia, sinus bradycardia, premature ventricular contraction (PVC), supraventricular premature contraction, left bundle branch block, right bundle branch block, first degree atrioventricular block, second degree atrioventricular block, third degree atrioventricular block, left ventricular hypertrophy, atrial fibrillation or flutter, and others.

[0108] Step 109: Input the combined features into the classification model to obtain the classification category of arrhythmia.

[0109] Taking support vector as an example, based on F C The calculation of the classification diagnosis of arrhythmia is explained in detail:

[0110] The combined feature F of the patient C Considered as the patient's feature vector, represented as vector x, all patients are represented as X, and a training data set of patients with arrhythmia is constructed as T = {(x1, y1), (x2, y2), ..., (x n ,y n )},in represents the combined feature vector of patient i, y i ∈{1,2,3,...M},y i represents the classification category of arrhythmia patients, where M represents the number of categories of arrhythmia diseases. In addition, the value of i is 1, 2, …, N.

[0111] Convert N samples related to arrhythmia from low-dimensional space to high-dimensional space. The samples are mapped into feature vectors in high-dimensional space. Different sample data are separated according to the decision function f(x) to maximize the spatial interval between samples of various category labels, that is, divide N samples into M categories. At the same time, the feature vector obtained by converting the sample X space is expressed as Eigenvector The corresponding hyperplane Z is:

[0112]

[0113] The objective function is:

[0114] Using the Lagrange multiplier α i , under the constraint Σ i a i y i =0 and 0≤α i Under the condition of ≤C, the formula is obtained:

[0115]

[0116] Where j = 1, 2, ..., m, and i ≠ j, in order to improve the classification accuracy of arrhythmia disease categories, the kernel function K(x i ,y j ), so that the sample is converted from low-dimensional space to high-dimensional space, the nonlinear multi-class problem is converted to linear separable, and the sample X is converted in high-dimensional space Then we get formula (8)

[0117]

[0118] Substitute the function of formula (8) into formula (6) to calculate the arrhythmia classification function of the SVM model:

[0119]

[0120] In addition, the kernel function required by the present application includes but is not limited to a linear kernel function, a polynomial kernel function, a radial basis function and a sigmoid kernel function. The arrhythmia classification function can be based on the patient's combined feature F C Perform classification diagnosis.

[0121] The present application also provides an application scenario, which applies the above-mentioned arrhythmia classification method using ECG signals. Specifically: two layers of ECG signal data are subjected to joint feature analysis using a model of a combination of two or more neural networks and features related to the type of arrhythmia are mined. The two models are calculated in the form of input constructed in the present application (such as Figure 3 ) is used to perform calculations, two vectors are given, and then correlation calculations are performed to achieve arrhythmia classification.

[0122] Based on the same inventive concept, the embodiment of the present application also provides an arrhythmia classification device using ECG signals for implementing the arrhythmia classification method using ECG signals involved above. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations in one or more embodiments of the arrhythmia classification device using ECG signals provided below can refer to the limitations of the arrhythmia classification method using ECG signals above, and will not be repeated here.

[0123] In an exemplary embodiment, Figure 8 As shown, a device for classifying arrhythmia using ECG signals is provided, comprising:

[0124] A data acquisition module, used to acquire ECG data and patient routine data;

[0125] A BERT model building module, used to build a first BERT model and a second BERT model;

[0126] A semantic information vector determination module, used for inputting the ECG data and the patient's routine data into a first BERT model and a second BERT model to obtain a first semantic information vector and a second semantic information vector;

[0127] A tower layer construction module, used to construct a first tower layer and a second tower layer;

[0128] A feature vector determination module, used for inputting the first semantic information vector and the second semantic information vector into the first tower layer and the second tower layer respectively to obtain a first feature vector and a second feature vector;

[0129] A correlation coefficient calculation module, used for calculating the correlation coefficient based on the first eigenvector and the second eigenvector;

[0130] A feature combination module, used for performing feature combination on the first feature vector, the second feature vector and the correlation coefficient to obtain a combined feature;

[0131] A classification model building module, used to build a classification model;

[0132] The classification module is used to input the combined features into the classification model to obtain the classification category of arrhythmia.

[0133] In an exemplary embodiment, a computer device is provided. The computer device may be a server or a terminal. The internal structure diagram thereof may be as follows: Fig. 9As shown. The computer device includes a processor, a memory, an input / output interface (Input / Output, referred to as I / O) and a communication interface. The processor, the memory and the input / output interface are connected through a system bus, and the communication interface is connected to the system bus through the input / output interface. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store arrhythmia classification data using ECG signals. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a method for classifying arrhythmias using ECG signals is implemented.

[0134] Those skilled in the art will understand that Fig. 9 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0135] In an exemplary embodiment, a computer device is further provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the steps in the above-mentioned method embodiments when executing the computer program.

[0136] In an exemplary embodiment, a computer-readable storage medium is provided, storing a computer program, and when the computer program is executed by a processor, the steps in the above method embodiments are implemented.

[0137] In an exemplary embodiment, a computer program product is provided, including a computer program, and when the computer program is executed by a processor, the steps in the above method embodiments are implemented.

[0138] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant regulations.

[0139] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM may be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM).

[0140] The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. The non-relational database may include a distributed database based on blockchain, etc., but is not limited thereto. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but is not limited thereto.

[0141] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0142] This article uses specific examples to illustrate the principles and implementation methods of this application. The description of the above embodiments is only used to help understand the method and core ideas of this application. At the same time, for those skilled in the art, according to the ideas of this application, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as limiting this application.

Claims

1. A method for classifying arrhythmia using ECG signals, characterized in that: The arrhythmia classification method using ECG signals comprises: Obtain ECG data and routine patient data; Build the first BERT model and the second BERT model; Inputting the ECG data and the patient's routine data into a first BERT model and a second BERT model to obtain a first semantic information vector and a second semantic information vector; Construct the first tower layer and the second tower layer; Inputting the first semantic information vector and the second semantic information vector into the first tower layer and the second tower layer respectively to obtain a first feature vector and a second feature vector; Calculating a correlation coefficient based on the first eigenvector and the second eigenvector; Performing feature combination on the first feature vector, the second feature vector and the correlation coefficient to obtain a combined feature; Build a classification model; The combined features are input into the classification model to obtain the classification category of arrhythmia.

2. The arrhythmia classification method using ECG signals according to claim 1, characterized in that: The patient's routine data includes age, gender, height and weight; The ECG data includes conventional ECG data and lead data distribution. The conventional ECG data includes: QRS duration, PR interval, PT interval, T interval, P interval, QRS wave, T wave, P wave, QRST wave and J point; the lead data distribution includes: wave width and amplitude.

3. The arrhythmia classification method using ECG signals according to claim 1, characterized in that: The first tower layer is any one of LSTM, GRU, BiLSTM, BiGRU, CNN, RNN, Transformer, and Attention; The second tower layer is any one of LSTM, GRU, BiLSTM, BiGRU, CNN, RNN, Transformer, and Attention.

4. The arrhythmia classification method using ECG signals according to claim 1, characterized in that: The correlation coefficient is calculated based on the first eigenvector and the second eigenvector using any one of the following methods: cosine similarity, Euclidean distance, Jaccard similarity coefficient, Pearson correlation coefficient, Manhattan distance, Spearman rank correlation coefficient, angle similarity, cosine distance, and Chebyshev distance.

5. The arrhythmia classification method using ECG signals according to claim 1, characterized in that: The following formula is specifically used to calculate the correlation coefficient based on the first eigenvector and the second eigenvector: K=cosθ Where V1={v1,v2,...,v n } represents the first eigenvector, V2={μ1,μ2,...,μ n } represents the second eigenvector.

6. The arrhythmia classification method using ECG signals according to claim 1, characterized in that: The expression of the classification model is: Among them, ω represents the parameter matrix, that is, the weight vector, T represents the transpose calculation, represents a nonlinear mapping function that maps input features to a high-dimensional space, b represents a bias term, n represents the number of patients, i represents the i-th patient, and y i represents the classification category of the i-th arrhythmia patient, y j represents the classification category of the jth arrhythmia patient, α i represents the Lagrange multiplier corresponding to the i-th training sample, K(x i ,y j ) represents the kernel function, which is used to calculate the similarity between input features.

7. A device for classifying arrhythmias using ECG signals, characterized in that: The arrhythmia classification device using ECG signals comprises: A data acquisition module, used to acquire ECG data and patient routine data; A BERT model building module, used to build a first BERT model and a second BERT model; A semantic information vector determination module, used for inputting the ECG data and the patient's routine data into a first BERT model and a second BERT model to obtain a first semantic information vector and a second semantic information vector; A tower layer construction module, used to construct a first tower layer and a second tower layer; A feature vector determination module, used for inputting the first semantic information vector and the second semantic information vector into the first tower layer and the second tower layer respectively to obtain a first feature vector and a second feature vector; A correlation coefficient calculation module, used for calculating the correlation coefficient based on the first eigenvector and the second eigenvector; A feature combination module, used for performing feature combination on the first feature vector, the second feature vector and the correlation coefficient to obtain a combined feature; A classification model building module, used to build a classification model; The classification module is used to input the combined features into the classification model to obtain the classification category of arrhythmia.

8. A computer device comprising: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the arrhythmia classification method using ECG signals according to any one of claims 1 to 6.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the arrhythmia classification method using ECG signals according to any one of claims 1 to 6 are implemented.

10. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the arrhythmia classification method using ECG signals according to any one of claims 1 to 6 are implemented.