| Cardiovascular disease is one of the major diseases that endanger human health.It has the characteristics of strong concealment,high incidence and high mortality.For residents,accurate detection of the type of cardiovascular disease is of great significance for the diagnosis and treatment of cardiovascular disease.Electrocardiogram contains a wealth of information about the heart and is a powerful tool for diagnosing cardiovascular disease.It is one of the important tools for diagnosing heart disease and evaluating cardiac function.Therefore,the type of cardiovascular disease can be further determined by classifying the electrocardiogram.This topic is aimed at the preprocessing of electrocardiogram and automatic classification of electrocardiogram.The main work of this paper is as follows:(1)Electrocardiogram preprocessing.The preprocessing in this paper includes two parts:noise removal of signals and detection of QRS waves.Aiming at the main noise of electrocardiogram,such as power frequency interference,baseline drift and myoelectric interference,a wavelet soft threshold filter is designed to analyze the signal in time domain and frequency domain.Finally,the noise is effectively removed,a clean and effective signal is obtained.According to the morphological characteristics of the signal,an adaptive double threshold algorithm is designed and implemented to accurately locate the R wave of the electrocardiogram.The R wave of the signal is accurately located by means of a high-low-double threshold.At last,the Q wave and the S wave of the signal are located with the R wave as the reference point.The recognition accuracy is 99.63%(2)Three traditional machine learning algorithms,random forest,K-nearest neighbor and C4.5,are used to classify small sample electrocardiogram in MIT-BIH arrhythmia database.Firstly,the signal is decomposed into five scales by discrete wavelet transform,then the frequency domain features and Shannon entropy characteristics are extracted in different frequency domains.Then,the information gain method is used to reduce the characteristics of the signal to obtain more effective features.Finally,the features after dimension reduction are input into the classification model,and the classification effect of the model is verified by using the ten-fold cross.The experimental results show that the random forest has achieved the best classification effect,with sensitivity of 98.1%,specificity of 99.5%,and accuracy of 98.08%.(3)Convolutional neural network model is built to classify large sample electrocardiogram in MIT-BIH arrhythmia database.The model has 10 layers(one input layer,four convolutional layers,three pooling layers,one fully connected layer,and one output layer).The data in the whole database is divided into training set and test set.The data of the training set is trained in batches by convolutional neural network model,the model is continuously optimized,and finally the model of the test set is used to test the model.The sensitivity of the test set is 99.45%,the specificity is 99.86%,and the accuracy is 99.78%.The results show that the algorithm can classify the signal well and has certain significance for the analysis of cardiovascular diseases. |