CN111657925A - Electrocardiosignal classification method, system, terminal and storage medium based on machine learning - Google Patents

Electrocardiosignal classification method, system, terminal and storage medium based on machine learning Download PDF

Info

Publication number
CN111657925A
CN111657925A CN202010650905.9A CN202010650905A CN111657925A CN 111657925 A CN111657925 A CN 111657925A CN 202010650905 A CN202010650905 A CN 202010650905A CN 111657925 A CN111657925 A CN 111657925A
Authority
CN
China
Prior art keywords
machine learning
classification
data
layer
electrocardiogram
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202010650905.9A
Other languages
Chinese (zh)
Inventor
陈晓禾
徐文畅
游斌权
郭宇
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Suzhou Institute of Biomedical Engineering and Technology of CAS
Original Assignee
Suzhou Institute of Biomedical Engineering and Technology of CAS
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Suzhou Institute of Biomedical Engineering and Technology of CAS filed Critical Suzhou Institute of Biomedical Engineering and Technology of CAS
Priority to CN202010650905.9A priority Critical patent/CN111657925A/en
Publication of CN111657925A publication Critical patent/CN111657925A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B5/00Measuring for diagnostic purposes; Identification of persons
    • A61B5/72Signal processing specially adapted for physiological signals or for diagnostic purposes
    • A61B5/7235Details of waveform analysis
    • A61B5/7264Classification of physiological signals or data, e.g. using neural networks, statistical classifiers, expert systems or fuzzy systems
    • A61B5/7267Classification of physiological signals or data, e.g. using neural networks, statistical classifiers, expert systems or fuzzy systems involving training the classification device

Landscapes

  • Health & Medical Sciences (AREA)
  • Engineering & Computer Science (AREA)
  • Artificial Intelligence (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Physics & Mathematics (AREA)
  • Biophysics (AREA)
  • Biomedical Technology (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Physiology (AREA)
  • Psychiatry (AREA)
  • Signal Processing (AREA)
  • Fuzzy Systems (AREA)
  • Evolutionary Computation (AREA)
  • Pathology (AREA)
  • Mathematical Physics (AREA)
  • Heart & Thoracic Surgery (AREA)
  • Medical Informatics (AREA)
  • Molecular Biology (AREA)
  • Surgery (AREA)
  • Animal Behavior & Ethology (AREA)
  • General Health & Medical Sciences (AREA)
  • Public Health (AREA)
  • Veterinary Medicine (AREA)
  • Measurement And Recording Of Electrical Phenomena And Electrical Characteristics Of The Living Body (AREA)

Abstract

The application relates to an electrocardiosignal classification method, an electrocardiosignal classification system, an electrocardiosignal classification terminal and a storage medium based on machine learning. The method comprises the following steps: acquiring electrocardiogram data of a patient; constructing an electrocardiosignal classification model; and inputting the electrocardiogram data into the electrocardiogram signal classification model to classify the electrocardiogram data, and outputting a prediction result of the myocardial infarction disease type of the patient according to the electrocardiogram data classification result. The embodiment of the application applies the machine learning algorithm to the classification and identification of the myocardial infarction disease types, can effectively improve the treatment efficiency of patients, improves the working efficiency of doctors, and reduces the death rate of myocardial infarction diseases.

Description

Electrocardiosignal classification method, system, terminal and storage medium based on machine learning
Technical Field
The application belongs to the technical field of electrocardiosignal processing, and particularly relates to an electrocardiosignal classification method, system, terminal and storage medium based on machine learning.
Background
The twelve-lead Electrocardiogram (ECG) is a main means and basis for judging myocardial infarction in clinical medicine, and the diagnosis of myocardial infarction has high requirement on timeliness, so that the intelligent classification prediction of myocardial infarction diseases based on the electrocardiogram is significant and has clinical significance in timeliness of clinical medicine treatment in order to improve the diagnosis efficiency of doctors and enable patients to find early treatment.
At present, a machine learning algorithm is applied to the classification of electrocardiosignals to be used as an auxiliary means for diagnosing related diseases, so that the existing medical diagnosis mode is greatly changed. For example, a heart beat signal is input, and the heart beat signal is deeply learned using LSTM (Long Short-term memory network) or CNN (Convolutional Neural network), thereby establishing an intelligent classification prediction model of arrhythmia. The intelligent classification prediction is used as an auxiliary means for diagnosing related diseases, so that precious treatment time can be saved for patients, the diagnosis process can be optimized, medical human resources can be saved, and the diagnosis time can be shortened. However, the existing classification method of the electrocardiosignals based on the machine learning algorithm needs to carry out denoising pretreatment on the electrocardiosignals in advance, and has time limitation for the clinical real-time performance; the existing electrocardiosignal classification method based on the machine learning algorithm can only be applied to classification and prediction of arrhythmia diseases, and a technology for applying the method to classification and prediction of myocardial infarction diseases does not exist at present.
Disclosure of Invention
The application provides an electrocardiosignal classification method, an electrocardiosignal classification system, an electrocardiosignal classification terminal and a storage medium based on machine learning, and aims to solve the technical problem that a machine learning algorithm is not applied to myocardial infarction disease classification prediction in the prior art.
In order to solve the above problems, the present application provides the following technical solutions:
an electrocardiosignal classification method based on machine learning comprises the following steps:
acquiring electrocardiogram data of a patient;
constructing an electrocardiosignal classification model;
and inputting the electrocardiogram data into the electrocardiogram signal classification model to classify the electrocardiogram data, and outputting a prediction result of the myocardial infarction disease type of the patient according to the electrocardiogram data classification result.
The technical scheme adopted by the embodiment of the application further comprises the following steps: the acquiring electrocardiographic data of the patient comprises:
acquiring electrocardiogram data of a patient by using a portable electrocardiogram detector, wherein the electrocardiogram data comprises RR interphase, Q wave, R wave and S wave amplitude values;
and screening case characteristics of the electrocardiogram data to obtain a characteristic data set.
The technical scheme adopted by the embodiment of the application further comprises the following steps: the electrocardiosignal classification model is a machine learning classifier, and the construction of the electrocardiosignal classification model specifically comprises the following steps:
splitting the characteristic data set into a training set and a test set according to a set proportion;
dividing the training set into a training set and a verification set of 4: 1 according to a five-fold cross verification method, training a machine learning classifier through the training set obtained through division, and verifying the machine learning classifier obtained through training through the verification set to obtain a machine learning classifier;
the five-fold cross validation method is repeatedly executed five times to obtain five machine learning classifiers;
evaluating the five machine learning classifiers by using a model evaluation method to obtain an optimal machine learning classifier;
and testing the optimal machine learning classifier by using a test set to obtain a final electrocardiosignal classification model.
The technical scheme adopted by the embodiment of the application further comprises the following steps: the evaluation of the five machine learning classifiers by using the model evaluation method specifically comprises the following steps:
and performing model evaluation on the five machine learning classifiers by adopting precision and sensitivity, wherein an evaluation formula is as follows:
Figure BDA0002574930630000031
Figure BDA0002574930630000032
in the above formula, precision is precision, sensitivity is sensitivity, TP represents the number of correctly classified classes, FP represents the number of other classes classified into the present class, and FN represents the number of erroneously classified classes.
The technical scheme adopted by the embodiment of the application further comprises the following steps: the acquiring electrocardiographic data of the patient comprises:
acquiring electrocardiogram data of a patient by adopting a 12-lead electrocardiograph; wherein, the electrocardiogram data is 12-lead basic electrocardiogram information, which comprises: RR interval, ST segment length, Q wave amplitude, R wave amplitude and S wave amplitude.
The technical scheme adopted by the embodiment of the application further comprises the following steps: the acquiring electrocardiographic data of the patient further comprises:
carrying out QRS wave group positioning according to the 12-lead basic electrocardio information;
and carrying out isometric heart beat segmentation on the QRS wave group to construct a heart beat data set.
The technical scheme adopted by the embodiment of the application further comprises the following steps: the electrocardiosignal classification model is a deep neural network, and the constructing of the electrocardiosignal classification model comprises the following steps: and constructing a deep neural network by adopting a five-fold cross validation method, and performing iterative optimization on the deep neural network by adopting a model iterative optimization algorithm.
The technical scheme adopted by the embodiment of the application further comprises the following steps: the deep neural network comprises a convolutional layer, a principal component analysis layer, a data reconstruction layer, an LSTM layer, an inverse LSTM layer, a full connection layer and an iteration optimization layer; assuming that X is used as the heart beat information of the equal-length target, and 12 leads are provided in total, the matrix size of the input characteristic X (1) is 12 m, and m is the length of the heart beat information;
the convolution layer carries out local feature extraction on X (1) by using a one-dimensional convolution kernel with the step size of 1 and the convolution kernel of 1 × N to obtain a local feature dimension k of (N-N +1), and outputs X (2) with the matrix size of 12 × N (N-N + 1);
the principal component analysis layer preferentially selects i features from X (2), and outputs X (3) with the matrix size of 12X i;
the data reconstruction layer processes X (3) and outputs X (4) with the matrix size of 1X 12 i;
the LSTM layer converts the matrix form of X (4) into a tensor form, wherein the input dimension of the LSTM layer is set as a tensor (12i, 1), the hidden layer of the LSTM core unit is set as j, and the output X (5) is expressed as a tensor (1, 12i × j, 1);
the inverse LSTM layer processes X (4) using the same parameters as the LSTM layer and outputs X (6) of the tensor (1, 12i j, 1);
inputting X (5) and X (6) into a full connection layer at the same time, setting a weight size to be (12i X j, N), setting a bias size to be (N, none), wherein N represents that the task is divided into N types, and outputting X (7) with the length of N;
and the iteration layer optimizes the output result of the X (7) by using a model iteration optimization algorithm, and outputs X (8) with the length of N, wherein N is the classification result of the deep neural network.
Another technical scheme adopted by the embodiment of the application is as follows: a machine learning-based cardiac electrical signal classification system, comprising:
a data acquisition module: for acquiring electrocardiogram data of a patient;
a model construction module: the method is used for constructing an electrocardiosignal classification model;
a data classification module: and the electrocardiogram data is input into the electrocardiogram signal classification model to classify the electrocardiogram data, and the prediction result of the myocardial infarction disease type of the patient is output according to the electrocardiogram data classification result.
The embodiment of the application adopts another technical scheme that: a terminal comprising a processor, a memory coupled to the processor, wherein,
the memory stores program instructions for implementing the machine learning-based cardiac electrical signal classification method;
the processor is configured to execute the program instructions stored by the memory to control machine learning-based classification of cardiac electrical signals.
The embodiment of the application adopts another technical scheme that: a storage medium storing program instructions executable by a processor to perform the machine learning-based classification of cardiac electrical signals.
Compared with the prior art, the embodiment of the application has the advantages that: the electrocardiosignal classification method, the electrocardiosignal classification system, the electrocardiosignal classification terminal and the storage medium based on machine learning are characterized in that a machine learning algorithm is applied to classification and identification of the myocardial infarction disease types, the myocardial infarction disease types are preliminarily predicted according to basic electrocardio parameters of a portable electrocardiograph at the early stage of disease incidence, a patient is reminded to see a doctor in time, and the myocardial infarction disease types are accurately identified according to 12-lead basic electrocardio information after the doctor sees the doctor, so that the overall and effective treatment efficiency of the patient is improved, the working efficiency of a doctor is improved, and the death rate of the myocardial infarction disease is reduced.
Drawings
Fig. 1 is a flowchart of a machine learning-based cardiac electrical signal classification method according to a first embodiment of the present application;
FIG. 2 is a schematic representation of cardiac data according to a first embodiment of the present application;
FIG. 3 is a flow chart of the construction of a machine learning classifier according to the first embodiment of the present application;
FIG. 4 is a flowchart of a machine learning-based classification method for cardiac electrical signals according to a second embodiment of the present application;
fig. 5 is a diagram illustrating a QRS complex positioning manner;
FIG. 6 is a diagram of a deep neural network architecture according to a second embodiment of the present application;
FIG. 7 is a schematic core cell structure diagram of a deep neural network LSTM _ cell according to a second embodiment of the present application;
FIG. 8 is a schematic structural diagram of a machine learning-based classification system for cardiac electrical signals according to an embodiment of the present application;
fig. 9 is a schematic structural diagram of a terminal according to an embodiment of the present application;
fig. 10 is a schematic structural diagram of a storage medium according to an embodiment of the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the present application and are not intended to limit the present application.
Please refer to fig. 1, which is a flowchart illustrating a machine learning-based electrocardiographic signal classification method according to a first embodiment of the present application. The electrocardiosignal classification method based on machine learning in the first embodiment of the application comprises the following steps:
step 100: acquiring electrocardiogram data of a patient by adopting an electrocardiogram detector;
the electrocardio detection equipment is a wearable or portable electrocardio detector, such as a monitoring bracelet and the like; the acquired electrocardiogram data includes waveform parameters such as RR interval, Q wave, R wave, S wave amplitude, and the like, and is specifically a schematic heartbeat diagram acquired by the electrocardiograph.
Step 110: carrying out case characteristic screening on electrocardiogram data to obtain a characteristic data set;
step 120: constructing an electrocardiosignal classification model, inputting the characteristic data set into the electrocardiosignal classification model to classify the electrocardiosignals, and outputting a prediction result of the myocardial infarction disease type of the patient according to the electrocardiosignal classification result;
in step 120, the cardiac signal classification model is a machine learning classifier, and a construction process of the machine learning classifier is shown in fig. 3, which specifically includes the following steps:
step 121: splitting the characteristic data set according to a set proportion, taking 80% of data samples as a training set, and taking 20% of data samples as a testing set;
step 122: dividing a training set into a training set and a verification set by 4: 1 according to a five-fold cross verification method, namely taking 80% of sample data in an original training set as the training set and taking 20% of sample data in the original training set as the verification set;
step 123: training the machine learning classifier through the training set obtained by division, and verifying the machine learning classifier obtained by training through the verification set to obtain a machine learning classifier;
the machine learning classifier includes but is not limited to an SVM, a random forest, a decision tree, and the like, and the SVM classifier is taken as an example in the embodiment of the application, and the training mode of the SVM classifier specifically includes:
setting RR interval, Q wave, R wave, S wave amplitude and other waveform parameters in the training set as characteristic vectors
Figure BDA0002574930630000081
Where n represents the number of samples and d represents the feature vector dimension in each sample;
feature vector
Figure BDA0002574930630000082
Inputting the data into an SVM classifier for training to obtain an SVM classifier; assuming that the classification type includes N types, determining a probability that an output result of the SVM classifier belongs to each type of classification type, obtaining probability values of the N classification types, selecting a maximum probability value of the N probability values, and if the maximum probability value is greater than or equal to a set value (the value is set to be 60% in the embodiment of the present application, which can be specifically adjusted according to an actual situation), taking the classification type of the maximum probability value as a classification result of the output result of the SVM classifier. And calculating the deviation of the classification result and the actual result, and feeding the deviation back to the next classification.
In the training process, the SVM classifier adopts different nonlinear kernel functions according to different characteristics, including polynomial kernel functions: 'poly' kernel, Gaussian kernel: a 'rbf' kernel function, etc. Let x (i) be the input of the ith feature in the feature set, y (i) be the corresponding output label, K represent the result of the kernel function, and the polynomial kernel function (poly) is represented by equation (1), where n ≧ 1, represented as the polynomial degree:
K(x(i),x(j))=(xT(i)x(j))n(1)
the Gaussian kernel function (rbf) is expressed as equation (2), where σ > 0, represents the bandwidth of the Gaussian kernel:
Figure BDA0002574930630000091
step 124: step 122 and step 123 are executed in a circulating manner five times, and five machine learning classifiers are obtained;
step 125: evaluating the five machine learning classifiers by using a model evaluation method to obtain an optimal machine learning classifier;
the model evaluation method comprises the following steps: model evaluation is carried out by adopting precision (precision) and sensitivity (sensitivity), and the calculation formula is as follows:
Figure BDA0002574930630000092
Figure BDA0002574930630000093
in equations (3) and (4), TP represents the number of correctly classified classes, FP represents the number of classes classified into the present class, and FN represents the number of classes classified into the present class.
Step 126: and testing the optimal machine learning classifier by using the test set to obtain a final electrocardiosignal classification model.
Based on the above, the myocardial infarction disease types comprise lower wall myocardial infarction, anterior wall myocardial infarction, extensive anterior wall myocardial infarction and other infarctions of various different parts, the myocardial infarction disease types can be rapidly and accurately predicted through the electrocardiosignal classification model in the first embodiment of the application, and before a patient reaches a hospital, the prediction result can be used as primary intelligent auxiliary diagnosis of myocardial infarction to remind the patient to seek medical advice in time; after arriving at the hospital, the prediction result can also provide reference for the doctor so that the doctor can quickly take corresponding measures for treatment. Meanwhile, the first embodiment of the application carries out preliminary prediction of disease types by directly deriving the electrocardiosignal data acquired by the wearable or portable electrocardio detector, omits complex work such as extraction, signal decoding, signal denoising, heartbeat segmentation and the like of 12-lead electrocardiosignals, does not need to depend on the acquisition quality of the 12-lead electrocardiosignals, is convenient for quick detection of wearable electrocardio equipment, improves the diagnosis efficiency of patients, effectively reduces the mortality of myocardial infarction diseases, and has prediction accuracy up to more than 97%.
Please refer to fig. 4, which is a flowchart illustrating a machine learning-based cardiac signal classification method according to a second embodiment of the present application. The electrocardiosignal classification method based on machine learning in the second embodiment of the application comprises the following steps:
step 200: acquiring electrocardiogram data of a patient by adopting electrocardiogram detection equipment;
in step 200, the electrocardiograph detection equipment is a 12-lead electrocardiograph; the acquired electrocardiogram data is 12-lead basic electrocardiogram information, and specifically comprises the following steps: RR interval, ST segment length, Q wave amplitude, R wave amplitude, S wave amplitude and the like. In particular, the pathological Q wave is mostly formed by myocardial necrosis and appears relatively late, and ST-T changes reflect myocardial ischemia and myocardial damage and have obvious changes in the early stage of acute myocardial infarction, so the ST-T changes are particularly important in the diagnosis of acute myocardial infarction.
Step 210: carrying out QRS wave group positioning according to the 12-lead basic electrocardio information;
in step 210, the embodiment of the present application uses an optimized Pan-tompkins (pt) algorithm to perform QRS complex positioning operation on 12 leads, I, II, III, V1, V2, V3, V4, V5, V6, avR, avL, and avF, respectively. The QRS complex positioning is shown in fig. 5, which specifically includes a band-pass filter, differentiation, square, sliding window integration, etc.
Step 220: carrying out isometric heart beat segmentation on the QRS wave group obtained by positioning to construct a heart beat data set;
step 230: inputting the heart beat data set into an electrocardiosignal classification model to classify electrocardiosignals, and outputting the identification result of the myocardial infarction disease type of the patient according to the classification result of the electrocardiosignals;
in step 230, the electrocardiosignal classification model is a deep neural network, the construction process of the deep neural network is the same as the construction mode of the machine learning classifier in the first embodiment of the present application, a five-fold cross validation method is also adopted to divide, train, evaluate and test the data set, and a model iterative optimization algorithm is adopted to perform iterative optimization on the deep neural network in the training process, wherein the model iterative optimization algorithm comprises an Adam algorithm, a random gradient descent algorithm, an adagard algorithm, a RMSProp algorithm, an adagard algorithm, an adaelta algorithm, an Adamax algorithm and the like.
Please refer to fig. 6, which is a diagram illustrating a deep neural network structure according to an embodiment of the present application. The deep neural network includes convolutional layer F1, principal component analysis layer F2, data reconstruction layer F3, LSTM layer F4, inverse LSTM layer F5, fully-connected layer F6, and iterative optimization layer F7.
Assuming that X represents the heart beat information of the target with equal length (length is m), and 12 leads are arranged in total, the matrix size of the input characteristic X (1) is set as 12X m; the convolution layer F1 performs local feature extraction on each heartbeat of each lead in X (1) by using a one-dimensional convolution kernel with a step size of 1 and a convolution kernel of 1 × N, respectively, without using an excitation function, obtains a local feature dimension k of each lead heartbeat as (N-N +1), and outputs X (2) with a matrix size of 12 × N +1, and is also represented as 12 × k;
the principal component analysis layer F2 selects i features from k features of each heart beat in X (2) preferentially, normalizes the i features simultaneously and outputs X (3) with the matrix size of 12X i;
the data reconstruction layer F3 processes X (3) and outputs X (4) with a matrix size of 1 × 12 i;
the LSTM layer F4 converts the matrix form of X (4) into a tensor form, where the input dimension of the LSTM layer is set as a tensor (12i, 1), the hidden layer of the LSTM core unit is set as j, and then X (5) is output and expressed as a tensor (1, 12i × j, 1) after passing through the LSTM layer;
the inverse LSTM layer F5 processes X (4) using the same parameters as the F4 layer and outputs X (6) of the tensor (1, 12i j, 1);
inputting X (5) and X (6) into a full connection layer F6 at the same time, setting a weight size to be (12i X j, N), and setting a bias size to be (N, none), wherein N represents that the task is divided into N types, and outputting X (7) with the length of N;
and the iteration layer F7 optimizes the output result of the X (7) by using a model iteration optimization algorithm, outputs the optimized iteration result, and outputs X (8) with the length of N, wherein N is the classification result of the model under the condition of changing the parameter setting. The model iterative optimization algorithm comprises an Adam algorithm, a random gradient descent algorithm, an Adagrad algorithm, a RMSProp algorithm, an Adagrad algorithm, an Adadelta algorithm, an Adamax algorithm and the like.
Further, the deep neural network in the embodiment of the present application is CNN, LSTM, BiLSTM, or the like. Taking LSTM as an example, the LSTM network includes LSTM _ cell and a full connection layer, based on the above layers F4, F5, and F6, a core unit structure of the LSTM _ cell is as shown in fig. 7, and includes a forgetting gate (forgetgate), an input gate (inputgate), and an output gate (outputgate), where the forgetting gate is controlled by a simple feedforward neural network to control a forgetting degree of information of a previous time period, and a parameter formula is expressed as:
ft=σ(Wf[xt,ht-1]+bf) (5)
Figure BDA0002574930630000121
Figure BDA0002574930630000122
wherein xtFor an input heart beat sequence, ht-1Is the output of the last sequential module. WfWeight vector of forgetting gate, bfFor the corresponding offset vector, σ is a sigmoid function, and if the output of the function is close to 0, the cell state of the previous time sequence will be forgotten.
Based on the above, through the deep neural network of this application second embodiment can carry out accurate discernment to myocardial infarction disease type fast, help the doctor carry out myocardial infarction's accurate diagnosis, can also help the doctor long-time carry out clinical observation to the patient, and discernment accuracy can reach more than 99.6%.
Based on the above, the first embodiment and the second embodiment of the present application can be effectively combined, before a patient arrives at a hospital, the first embodiment of the present application can be used for preliminarily predicting the myocardial infarction disease type of the patient, after the patient arrives at the hospital, the prediction result can provide effective reference for a doctor, and then the second embodiment can be used for accurately identifying the myocardial infarction disease type of the patient, so that the efficiency of the patient in treatment is effectively improved, the mortality of the myocardial infarction is reduced as a whole, and unnecessary work of the doctor is reduced.
Please refer to fig. 8, which is a schematic structural diagram of an electrocardiographic signal classification system based on machine learning according to an embodiment of the present application. The electrocardiosignal classification system based on machine learning of the embodiment of the application includes:
a data acquisition module: for acquiring electrocardiogram data of a patient;
a model construction module: the method is used for constructing an electrocardiosignal classification model;
a data classification module: and the electrocardiogram data is input into the electrocardiogram signal classification model to classify the electrocardiogram data, and the prediction result of the myocardial infarction disease type of the patient is output according to the electrocardiogram data classification result.
In order to verify the feasibility and effectiveness of the embodiments of the present application, experiments are performed below on the classification effect of the machine learning classifier classification model of the first embodiment and the deep neural network classification model of the second embodiment, respectively. Basic parameters such as RR interval, ST interval, QR interval, Q wave, R wave, S wave amplitude and the like extracted from an electrocardio instrument are input into a machine learning classifier classification model for myocardial infarction disease type prediction, and experimental results show that the prediction accuracy of the model reaches 97.8%.
The segmented heart beat data is input into a BilSTM model, and experimental results show that the deep learning loss value is effectively reduced, the model is not over-fitted, and the accuracy of a test set gradually rises along with the training of a neural network to reach stability, and finally reaches more than 99%.
Please refer to fig. 9, which is a schematic diagram of a terminal structure according to an embodiment of the present application. The terminal 50 comprises a processor 51, a memory 52 coupled to the processor 51.
The memory 52 stores program instructions for implementing the above-described machine learning-based electrocardiographic signal classification method.
The processor 51 is operative to execute program instructions stored in the memory 52 to control machine learning-based classification of cardiac electrical signals.
The processor 51 may also be referred to as a CPU (Central Processing Unit). The processor 51 may be an integrated circuit chip having signal processing capabilities. The processor 51 may also be a general purpose processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic, discrete hardware components. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
Please refer to fig. 10, which is a schematic structural diagram of a storage medium according to an embodiment of the present application. The storage medium of the embodiment of the present application stores a program file 61 capable of implementing all the methods described above, where the program file 61 may be stored in the storage medium in the form of a software product, and includes several instructions to enable a computer device (which may be a personal computer, a server, or a network device) or a processor (processor) to execute all or part of the steps of the methods of the embodiments of the present invention. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a mobile hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, or terminal devices, such as a computer, a server, a mobile phone, and a tablet.
The electrocardiosignal classification method, the electrocardiosignal classification system, the electrocardiosignal classification terminal and the storage medium based on machine learning are characterized in that a machine learning algorithm is applied to classification and identification of the myocardial infarction disease types, the myocardial infarction disease types are preliminarily predicted according to basic electrocardio parameters of a portable electrocardiograph at the early stage of disease incidence, a patient is reminded to see a doctor in time, and the myocardial infarction disease types are accurately identified according to 12-lead basic electrocardio information after the doctor sees the doctor, so that the overall and effective treatment efficiency of the patient is improved, the working efficiency of a doctor is improved, and the death rate of the myocardial infarction disease is reduced.
The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present application. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the application. Thus, the present application is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (11)

1. An electrocardiosignal classification method based on machine learning is characterized by comprising the following steps:
acquiring electrocardiogram data of a patient;
constructing an electrocardiosignal classification model;
and inputting the electrocardiogram data into the electrocardiogram signal classification model to classify the electrocardiogram data, and outputting a prediction result of the myocardial infarction disease type of the patient according to the electrocardiogram data classification result.
2. The machine-learning based classification method for cardiac electrical signals according to claim 1 wherein said acquiring cardiac electrical data of a patient comprises:
acquiring electrocardiogram data of a patient by using a portable electrocardiogram detector, wherein the electrocardiogram data comprises RR interphase, Q wave, R wave and S wave amplitude values;
and screening case characteristics of the electrocardiogram data to obtain a characteristic data set.
3. The machine learning-based electrocardiographic signal classification method according to claim 2, wherein the electrocardiographic signal classification model is a machine learning classifier, and the constructing of the electrocardiographic signal classification model specifically includes:
splitting the characteristic data set into a training set and a test set according to a set proportion;
dividing the training set into a training set and a verification set of 4: 1 according to a five-fold cross verification method, training a machine learning classifier through the training set obtained through division, and verifying the machine learning classifier obtained through training through the verification set to obtain a machine learning classifier;
the five-fold cross validation method is repeatedly executed five times to obtain five machine learning classifiers;
evaluating the five machine learning classifiers by using a model evaluation method to obtain an optimal machine learning classifier;
and testing the optimal machine learning classifier by using a test set to obtain a final electrocardiosignal classification model.
4. The machine-learning-based classification method for cardiac electrical signals according to claim 3, wherein the evaluation of the five machine-learning classifiers using the model evaluation method is specifically:
and performing model evaluation on the five machine learning classifiers by adopting precision and sensitivity, wherein an evaluation formula is as follows:
Figure FDA0002574930620000021
Figure FDA0002574930620000022
in the above formula, precision is precision, sensitivity is sensitivity, TP represents the number of correctly classified classes, FP represents the number of other classes classified into the present class, and FN represents the number of erroneously classified classes.
5. The machine-learning based classification method for cardiac electrical signals according to claim 1 wherein said acquiring cardiac electrical data of a patient comprises:
acquiring electrocardiogram data of a patient by adopting a 12-lead electrocardiograph; wherein, the electrocardiogram data is 12-lead basic electrocardiogram information, which comprises: RR interval, ST segment length, Q wave amplitude, R wave amplitude and S wave amplitude.
6. The machine-learning based classification method for cardiac electrical signals according to claim 5 wherein said acquiring cardiac electrical data of a patient further comprises:
carrying out QRS wave group positioning according to the 12-lead basic electrocardio information;
and carrying out isometric heart beat segmentation on the QRS wave group to construct a heart beat data set.
7. The machine learning-based classification method for cardiac electrical signals according to claim 6, wherein the classification model for cardiac electrical signals is a deep neural network, and the constructing the classification model for cardiac electrical signals comprises: and constructing a deep neural network by adopting a five-fold cross validation method, and performing iterative optimization on the deep neural network by adopting a model iterative optimization algorithm.
8. The machine-learning-based cardiac signal classification method according to claim 7, wherein the deep neural network comprises a convolutional layer, a principal component analysis layer, a data reconstruction layer, an LSTM layer, an inverse LSTM layer, a fully-connected layer, and an iterative optimization layer; assuming that X is used as the heart beat information of the equal-length target, and 12 leads are provided in total, the matrix size of the input characteristic X (1) is 12 m, and m is the length of the heart beat information;
the convolution layer carries out local feature extraction on X (1) by using a one-dimensional convolution kernel with the step size of 1 and the convolution kernel of 1 × N to obtain a local feature dimension k of (N-N +1), and outputs X (2) with the matrix size of 12 × N (N-N + 1);
the principal component analysis layer preferentially selects i features from X (2), and outputs X (3) with the matrix size of 12X i;
the data reconstruction layer processes X (3) and outputs X (4) with the matrix size of 1X 12 i;
the LSTM layer converts the matrix form of X (4) into a tensor form, wherein the input dimension of the LSTM layer is set as a tensor (12i, 1), the hidden layer of the LSTM core unit is set as j, and the output X (5) is expressed as a tensor (1, 12i × j, 1);
the inverse LSTM layer processes X (4) using the same parameters as the LSTM layer and outputs X (6) of the tensor (1, 12i j, 1);
inputting X (5) and X (6) into a full connection layer at the same time, setting a weight size to be (12i X j, N), setting a bias size to be (N, none), wherein N represents that the task is divided into N types, and outputting X (7) with the length of N;
and the iteration layer optimizes the output result of the X (7) by using a model iteration optimization algorithm, and outputs X (8) with the length of N, wherein N is the classification result of the deep neural network.
9. An electrocardiosignal classification system based on machine learning is characterized by comprising:
a data acquisition module: for acquiring electrocardiogram data of a patient;
a model construction module: the method is used for constructing an electrocardiosignal classification model;
a data classification module: and the electrocardiogram data is input into the electrocardiogram signal classification model to classify the electrocardiogram data, and the prediction result of the myocardial infarction disease type of the patient is output according to the electrocardiogram data classification result.
10. A terminal, comprising a processor, a memory coupled to the processor, wherein,
the memory stores program instructions for implementing the machine learning-based classification method for cardiac electrical signals according to any one of claims 1-8;
the processor is configured to execute the program instructions stored by the memory to control machine learning-based classification of cardiac electrical signals.
11. A storage medium storing program instructions executable by a processor to perform the machine learning-based classification method for cardiac electrical signals according to any one of claims 1 to 8.
CN202010650905.9A 2020-07-08 2020-07-08 Electrocardiosignal classification method, system, terminal and storage medium based on machine learning Pending CN111657925A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010650905.9A CN111657925A (en) 2020-07-08 2020-07-08 Electrocardiosignal classification method, system, terminal and storage medium based on machine learning

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010650905.9A CN111657925A (en) 2020-07-08 2020-07-08 Electrocardiosignal classification method, system, terminal and storage medium based on machine learning

Publications (1)

Publication Number Publication Date
CN111657925A true CN111657925A (en) 2020-09-15

Family

ID=72391804

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010650905.9A Pending CN111657925A (en) 2020-07-08 2020-07-08 Electrocardiosignal classification method, system, terminal and storage medium based on machine learning

Country Status (1)

Country Link
CN (1) CN111657925A (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113035346A (en) * 2021-02-22 2021-06-25 北京信息科技大学 Medical knowledge map-based disease category assessment device and method
CN113080984A (en) * 2021-03-25 2021-07-09 南京蝶谷健康科技有限公司 Myocardial infarction identification and positioning method based on CNN and LSTM
CN113208609A (en) * 2021-05-08 2021-08-06 黑龙江省医院 Electrocardio information management system
CN113616214A (en) * 2021-08-11 2021-11-09 上海数创医疗器械有限公司 Resting twelve-lead electrocardiosignal processing method, storage medium and processor
CN114081502A (en) * 2021-11-11 2022-02-25 中国科学院深圳先进技术研究院 Non-invasive heart disease diagnosis method and device based on machine learning

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113035346A (en) * 2021-02-22 2021-06-25 北京信息科技大学 Medical knowledge map-based disease category assessment device and method
CN113035346B (en) * 2021-02-22 2023-09-22 北京信息科技大学 Disease category assessment device and method based on medical knowledge graph
CN113080984A (en) * 2021-03-25 2021-07-09 南京蝶谷健康科技有限公司 Myocardial infarction identification and positioning method based on CNN and LSTM
CN113208609A (en) * 2021-05-08 2021-08-06 黑龙江省医院 Electrocardio information management system
CN113616214A (en) * 2021-08-11 2021-11-09 上海数创医疗器械有限公司 Resting twelve-lead electrocardiosignal processing method, storage medium and processor
CN114081502A (en) * 2021-11-11 2022-02-25 中国科学院深圳先进技术研究院 Non-invasive heart disease diagnosis method and device based on machine learning

Similar Documents

Publication Publication Date Title
Li et al. Patient-specific ECG classification by deeper CNN from generic to dedicated
KR102451795B1 (en) ECG signal detection method
Acharya et al. Automated detection of arrhythmias using different intervals of tachycardia ECG segments with convolutional neural network
Xu et al. Interpretation of electrocardiogram (ECG) rhythm by combined CNN and BiLSTM
Khafaga et al. Optimization of Electrocardiogram Classification Using Dipper Throated Algorithm and Differential Evolution.
CN111657925A (en) Electrocardiosignal classification method, system, terminal and storage medium based on machine learning
Murugesan et al. Ecgnet: Deep network for arrhythmia classification
CN111565633A (en) Time series data learning and analyzing method using artificial intelligence
CN110664395B (en) Image processing method, image processing apparatus, and storage medium
CN110638430B (en) Method for building cascade neural network ECG signal arrhythmia classification model
Zhou et al. ECG quality assessment using 1D-convolutional neural network
CN112690802B (en) Method, device, terminal and storage medium for detecting electrocardiosignals
CN115666387A (en) Electrocardiosignal identification method and electrocardiosignal identification device based on multiple leads
Ullah et al. An End‐to‐End Cardiac Arrhythmia Recognition Method with an Effective DenseNet Model on Imbalanced Datasets Using ECG Signal
Khan et al. Electrocardiogram heartbeat classification using convolutional neural networks for the detection of cardiac Arrhythmia
Borghi et al. Atrial fibrillation classification based on MLP networks by extracting Jitter and Shimmer parameters
Zhao et al. An explainable attention-based TCN heartbeats classification model for arrhythmia detection
Li et al. DeepECG: Image-based electrocardiogram interpretation with deep convolutional neural networks
CN115281688A (en) Cardiac hypertrophy multi-label detection system based on multi-mode deep learning
Islam et al. Robust detection of atrial fibrillation using classification of a linearly-transformed window of RR intervals tachogram
Zhang et al. A signal quality assessment method for electrocardiography acquired by mobile device
Guo et al. Machine learning-based automatic cardiovascular disease diagnosis using two ecg leads
Nasim et al. An Evolutionary-Neural Mechanism for Arrhythmia Classification With Optimum Features Using Single-Lead Electrocardiogram
Eleyan et al. Multi-Classifier Deep Learning based System for ECG Classification Using Fourier Transform
Popa et al. Comparing two different types of deep neural networks to improve accuracy in ECG intepretation

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination