ECG signal analysis using continuous wavelet transformation and deep neural network

Page 1

International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056

Volume: 09 Issue: 09 | Sep 2022 www.irjet.net p-ISSN: 2395-0072

ECG signal analysis using continuous wavelet transformation and deep neural network

1Professor Grade2, SENSE, Vellore Institute of Technology, Katpadi, Tamil Nadu-632014 2,3,4,5 Student, SENSE, Vellore Institute of Technology, Katpadi, Tamil Nadu-632014 ***

Abstract - Theobjectiveofthisresearchistodevelopan algorithm that can identify and classify various electrocardiogram (ECG) data beat kinds. Using the Deep TheneuralnetworkandtheContinuousWaveletTransform (CWT). The goal is to teach a CNN how to distinguish betweenARR,CHF,andNSR.Identificationandtreatmentof arrhythmias can reduce the risk of mortality from cardiovasculardisease(CVD).Theelectrocardiogram(ECG) is examined beat by beat in clinical practise to make the diagnosis, but this is frequently time-consuming and challenging.Inthisstudy,wedescribeanautomatedmethod forclassifyingECGsbasedonContinuousWaveletTransform (CWT) and Convolutional Neural Network (CNN) (CNN). WhileCNNisusedtoextractfeaturesfromthe2D-scalogram createdfromthetime-frequencycomponentsstatedabove, CWTisusedtobreakdownECGsignalsintodiscretetimefrequencycomponents.FourRRintervalcharacteristicsare collected,combinedwithCNNfeatures,andtheninputintoa fully connected layer for ECG classification because the surroundingRpeakinterval,alsoknownastheRRinterval, is crucial for identifying arrhythmia. In the MITBIH arrhythmia database, our method achieves an overall performance of70.75%, 67.47%,68.76%,and 98.74% for positivepredictivevalue,sensitivity,F1-score,andaccuracy, respectively. In comparison to earlier methods, our techniqueraisestheoverallF1-scoreby4.7516.85%.

1. INTRODUCTION

Anirregularheartbeatknownasanarrhythmiaisoneofthe mainreasons whypeople diefromcardiovasculardisease (CVD).Whilethemajorityofarrhythmiasarebenign,some can be deadly. For instance, atrial fibrillation can cause cardiacarrestandstrokes.Itneedstobetreatedrightaway becauseitissodangerous.TheWorldHealthOrganization (WHO)estimatesthat17.5milliondeathsworldwidewere attributable to CVD in 2012. By 2030, 23 million fatalities from CVD are expected to have occurred. Additionally, treatmentsforCVD,includingmedicalcare,areprohibitively expensive. Over US $3.8 trillion is expected to be spent in low-andmiddle-incomecountriesbetween2011and2025. For this goal, researchers have developed a system that

automaticallycategorisesheartbeatsinECGmeasurements. Mostmethodsinvolvecategorizationandfeatureextraction. RR interval characteristics and heartbeat morphology are frequently used. For categorization, a variety of methods were used, including continuous wavelet transformation, deepneuralnetworks,andartificialneuralnetworks(ANNs). Even though these methods have a high level of effectiveness, different people have ECG waves with very diversemorphologies,andeventhesamepatientcanhave differentECGwavesatdifferenttimes.Thefixedfeaturesof these methods are insufficient for consistently differentiatingarrhythmiaindifferentindividuals.Therapid advancement of deep neural networks has led to a recent riseinpopularityformethodsbasedondeeplearning.Deep learning can automatically derive discriminant properties from training data as a representation learning strategy. Numerous studies indicate that deep learning-based methods for classifying ECGs may be able to extract more abstracttraitsandeliminatepatient-specificdiscrepancies. BecausetheECGsignalcontainssomanydifferenttypesof frequencies,itwillbechallengingtocategorisethedifferent signals of the ECG, which will be made even more challenging if we utilise straightforward deep neural networking for the extraction. Shifting the ECG signal to time-frequency domain is one easily imaginable way to lessen the effects of aliasing of different frequency components. Two well-liked time frequency methods are Wavelet Transform (WT) and Short-Temporal Fourier Transform(STFT).AlthoughSTFTservedasinspirationfor WT, WT has the ability to provide both high frequency resolution and low time resolution at low frequencies, as wellashightimeresolutionandlowfrequencyresolutionat high frequencies. WT typically performs better in timefrequencydomainanalysisthanSTFT.UsingtheContinuous WaveletTransform(CWT),whichisaWTwithacontinuous wavelet function, and the Convolutional Neural Network (CNN),wedevelopanautomaticECGcategorizationmethod. CNN is a deep learning tool that has been used for categorising images and successfully mimics the human visualsystem.TheECGheartbeatsignalisconvertedtothe time-frequency domain using the CWT, and features are extracted from the 2D scalogram created from the timefrequency components using CNN. The method combines CNN's visual feature extraction capabilities with CWT's expertise in multidimensional signal processing. To fully

Factor value: 7.529 | ISO 9001:2008 Certified Journal |

© 2022, IRJET | Impact
Page773
: Cardiovascular
Deep
network;ECGsignalclassification;ARR;CHF;NSR
Key Words
disease;
neural
Malaya kumar hota1, Somalaraju chenchu babu2, B. Bhargav reddy3 , A. Varun chowdary 4 , R. Sai sumanth 5

International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056

utiliseallofthedataforECGclassification,theRRinterval characteristicsarealsoobtainedandfusedintoourCNN.

2. LITERATURE REVIEW

Over the past 20 years, numerous automatic ECG categorizationtechniqueshavebeenputout.Ithereforeopt for the journal that uses the CNN neural network to distinguishbetweenthevarioustypesofECGreadings.

beat. rhythm characterising the average heartbeat of a healthyhumanbeingthatcomesfromthesinusnode.The NSR%istypicallyconstant,butitcanchangedependingon the autonomic inputs that the sinus node receives. Therefore,wepreviouslyusedallthreeECGsignalkinds.We previouslyutilisedCWTtoclassifythemanddeterminetheir correctness.usingadeepneuralnetworkasatool.

Using an electrocardiogram (ECG), arrhythmias can be identified (ARR). It involves checking the pulse and the attitude. The clinical illness known as congestive heart failure(CHF)occurswhentheheartisunabletopumpblood attheraterequiredbythebody'susingtissuesorwhenthe heart can only do so with a height in filling weight. When referring to a specific type of sinus rhythm, NSR used to meanthatallotherECGreadingsfellwithinthetypicalrange ofthebreakingpoint,asdepictedinthediagram.

Figure 1: ECG classification flow diagram

2.1 ECG-SIGNAL CLASSIFICATION

ArrhythmiaThereareseveralformsofECGsignals,andin thisstudy,wehavemostlyusedthefollowingECGsignalsfor categorization.

ARRstandsforarrhythmias.

CHFstandsforCongestiveHeartFailure.

NSRstandsforNormalSinusRhythm.

2.1.1 Arrhythmias

A problem with the rate or rhythm of the heartbeat is knownasanarrhythmia.Theheartwillbeatirregularly,too rapidly,ortooslowlyasaresultofarrhythmias.Thedisease knownastachycardiacausesthehearttobeattoofast.

2.1.2 Congestive heart failure

Bradycardiaisaconditionwheretheheartbeatstooslowly. Congestiveheartfailurecanresultinheartfailure.Theheart cannot efficiently fill or pump blood (systolic) (diastolic). Symptomsincludeshortnessofbreath,fatigue,andswollen legs.havingarapidheartbeatLesssaltmaybeconsumedas atreatment.

2.1.3 Normal sinus rhythm

usingprescriptionmedicationandlimitingfluidintakeInIn some circumstances, a pacemaker or defibrillator may be placed.Theterm"normalsinusrhythm"(NSR)referstothis

2: Arrhythmia, CHF, normal ECG signals

2.2 CONTINUOUS WAVELET TRANSFORM

Thecontinuouswavelettransformisasignalprocessingand mathematics technique that is frequently used for image compression, denoising, and other similar tasks. It is also usedinmanyotherfields,suchassolvingpartialdifferential equations, financial time series analysis, and biomedical signalprocessing,whichincludesECGandEEGanalysis.The input layer of the convolutional neural network receives coefficients right away as a "image," creating a "Transfer learning" scenario. For this task, we only used Mortlet Wavelet.

2.3 DEEP NEURAL NETWORK

Manydifferentapplicationshavemadeuseofdeepneural networks. Natural language processing and pattern recognition are two examples. processing and computerbased learning Machine learning has provided enormous benefitsfordecadespriortonow.examplesofhowthishas an impact on our daily lives include effective web search, self-driving automobiles, computer vision, and others Understanding optical characteristics Particularly deep neural networks have developed into effective machine

Volume: 09 Issue: 09 | Sep 2022 www.irjet.net p-ISSN: 2395-0072 © 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page774

Figure

International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056

Volume: 09 Issue: 09 | Sep 2022 www.irjet.net p-ISSN: 2395-0072

learning tools. both machine learning and artificial intelligence A multi-layer artificial neural network is referredtoasalargeneuralnetwork(DNN)(ANN).between theinputandoutputlayersarefurtherlayers.

Thesuccessofdeepneural networkshasledtosignificant advances, such as a 30% reduction in word error rates in speechrecognitionoverconventionalmethods(thelargest gainin20years)oraradicallylowererrorrateinanimage recognition competition since 2011 (from 26% to 3.5%, comparedto5%forhumans).Inordertoanalysephotosof variedsignals,wethereforeusethe"ALEX"neuralnetwork inthisresearch.

2.4 ALEXA NEURLA NETWORK

Oneofthelarge-scaleimagenetvisualrecognitionnetworks, the Alex neural network, was utilised to recognise every distinctpicturewitharangeoffrequencies.Thereareeight layersofparametersintheAlexnetthatcanbetaught.Five layersmakeupthemodel;thefirstisamaxpoolinglayer, followedbythreefullyconnectedlayers.Alloftheselayers, withtheexceptionoftheoutputlayer,useReluactivation. Theyfoundthatthetrainingprocesswasroughlysixtimes fasterwhenthereluwasusedasanactivationfunction.To prevent overfitting, they also used dropout layers in their model.TheImageNetdatasetisusedtotrainthemodelas well. About 14 million images from a thousand distinct classifications are included in the Image Net dataset. As a result,wechosethisvariantoftheAlexneuralnetworkto analysethevarioustypesofECGdatabecauseithadallthe characteristicsoftheAlexneuralnetwork.

There are three types of neural networks that are often employedinallofthem:

A.Multi-LayerPerceptrons(MLP);

B.ConvolutionalNeuralNetworks(CNN)

C.RecurrentNeuralNetworks (RNN)

A.Multiple-Neuralnetwork

A A feed forward artificial neural network is called a multilayerperceptron(MLP)(ANN).AnMLPhasaninput layer, a hidden layer, and an output layer as its minimum number of node layers. All nodes aside from the input nodes areneuronswithnonlinearactivationfunctions.The bulkofdevelopersutilisethisneuralnetworkbecauseitis oneofthebestones.

B.Convolutionalneuralnetwork

An artificial neural network called a convolutional neural network(CNN)isdesignedspecificallytoanalysepixelinput duringimagerecognitionandprocessing.CNNsarepowerful artificialintelligence(AI)systemsthatrecogniseimagesand videos using deep learning in addition to recommender

systemsandnaturallanguageprocessing(NLP).Amultilayer perceptron-liketechniqueusedbyCNNshasbeentunedfor reducedprocessingrequirements.

Input,output,andahiddenlayerwithseveralconvolutional, pooling,fullyconnected,andnormalisinglayersmakeupa CNN'sthreelayers.Asignificantlymoreefficientsystemis produced by removing restrictions and increasing image processingefficiency.

C.RecurrentNeuralNetworks

Recurrent neural networks (RNN) are the most advanced techniqueforsequentialdataandareusedbyGooglevoice searchandApple'sSiri.Itisthefirstalgorithmthat,because of its internal memory, remembers its input, making it perfect for sequential data machine learning applications. One of the algorithms responsible for the phenomenal advancements in deep learning over the past few years is this one. In this article, we'll discuss the principles of recurrentneuralnetworks'operationaswellastheirmain drawbacksandsolutions.

3. METHODOLOGY

This project's primary objective was to categorise the various ECG signal types using continuous wavelet transformation[CWT].Todothis,wefirstusedtogenerate the final waveform of all the different ECG signal types, which was primarily used to indicate the "efficiency" and "accuracy"ofthevariousECGsignals.

ECGSignalstoImageconversionusingCWT

WetransfertheECGsignaltothetimefrequencydomainto facilitate feature extraction because it consists of discrete frequency components. The most popular time-frequency analysis tool is CWT, which employs a set of wavelet functions to deconstruct a signal in the time-frequency domain. Therefore, we used the CWT to get the 2Dscalogram waveform made up of various ECG signals. Therefore,inthisinstance,theCWTisprimarilyutilisedto generatethefollowingcharacteristics,whicharethenused tocategorisethevariouskindsofECGsignals.TheWavelet "AnalyticMorlet(amor)"iswhatweprimarilyuse.Wavelets having one-sided spectra and complex time values are known as analytical wavelets. When creating a timefrequency-analysiswiththeCWT,thesewaveletsarea greatoption.12waveletband-passfiltersareusedbyCWT foreachoctave(12voicesperoctave).

©
| Page775
2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal

International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056

Volume: 09 Issue: 09 | Sep 2022 www.irjet.net p-ISSN: 2395-0072

Figure3:CWTofECGsignal

Then, utilising all of the CWT's properties, we created scologramimagesofeachECGsignalstoredinthedatabase. Asaresult,each1DsignalfromtheECGsignalsisconverted intoaCWTscalogramusingtheCWT,andeachscalogramis represented by a color-map of a jet of 128 colours. After conversion,wereceived900separate2d-scalogramimages ofvariousECGsignals,suchasARR,CHF,andNSR,whichwe used to identify them by creating various folders for each typeofECGsignal.

a. ECGsignalclassificationusingneuralnetwork

Aneuralnetworkhavingmorethantwolayersandacertain levelofcomplexityisreferredtoasadeepneuralnetwork. Deep neural networks use sophisticated mathematical modelstohandledataincomplexways.Asaresult,wewere able to evaluate the accuracy of all the various neural networktypesthatwerepresentintheECGdatabaseusing the"ALEX"neuralnetwork.AlexKrizhevskydevelopedthe deepneuralnetworkknownasAlexNet.Itwasdevelopedto classifyimagesfor the ImageNet LSVRC2010 competition, anditproducedground-breakingoutcomes.Additionally,it workedwithavarietyofGPUs.

ComparedtoearlierCNNsusedforcomputervisiontasks, AlexNetwassignificantlylarger.Ithas650,000neuronsand 60 million parameters, and training on two GTX 580 3GB GPUs requires five to six days. Today's faster GPUs can executeevenmorecomplexCNNsextremelywell,evenon very large datasets. Interesting visual properties are extracted using multiple convolutional kernels. A single convolutionallayeroftenhasmanykernelsofthesamesize.

Following the first two Convolutional layers, the next OverlappingMaxPoolinglayersareadded.Directcoupling exists between the third, fourth, and fifth convolutional layers.TheOverlappingMaxPoolinglayer,whoseoutputis routedthroughaseriesoftwofullyconnectedlayers,follows thefifthconvolutional layer. The1000classlabel Softmax classifier receives input from the second fully connected layer.

Asaresult,everyoperationthathasbeenexplainedhasbeen carriedoutusinganAlexneuralnetwork.Weusedthisform ofAlexnetforECGsignalstodeterminethecorrectnessof thevarioustypesofECGsignalsimagesthatareincludedin the database. In order to produce what is the certain accuracyofall ECGsignalspresent,thealex netisused to receive photographs as input. As a result, it requires 900 photographs of various ECG signals. This helps people determinewhetherornottheECGsignalsaregood.

4. RESULTS

FIGURE 4 .Accuracy and loss of the ECG signal

© 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page776

International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056

Volume: 09 Issue: 09 | Sep 2022 www.irjet.net p-ISSN: 2395-0072

However,therearesomeotherneuralnetworksthatprovide greaterefficiency,sowemayenhancewiththehelpofthe other neural networks to provide even higher accuracy. Despite the fact that our technique achieves high overall performance,inthiscase,wehavebeenusingdeepneural networks like Alexnet to provide the most accuracy. In general,thiscanbemadebetterwithmoreannotatedECG data.ButclassifyingECGheartbeatsisexpensiveandtimeconsuming. Nowadays, there are many freely accessible unlabeled ECG databases, and the use of unsupervised learningtechniqueslikeautoencodermayhelptofurther improvetheperformanceoftheFclassinapracticalway. We'llgiveitanothershotlater.

6. REFERENCES

FIGURE.5 Confusion Matrix

4.1 ACCURACY MEASUREMENT

Using an electrocardiogram (ECG), arrhythmias can be identified (ARR). It involves checking the pulse and the attitude. The clinical illness known as congestive heart failure(CHF)occurswhentheheartisunabletopumpblood attheraterequiredbythebody'susingtissuesorwhenthe heartcanonlydosowithaheightinfillingweight.Aspecific typeofsinusrhythmknownasNSRisoneinwhichallother ECGreadingsremainwithinpredeterminedtypicalbreaking limits.

4.2 TRAINING PROGRESS OF THE SIGNAL

Therefore,weusedtopredictthemusingthe900different types of ECG images that are used to provide this much accuracy. In this, 750 images are primarily taken into accountfortrainingand150imagesaretakenintoaccount fortesting.Wealsousedtohaveaconfusionmatrixinwhich weusedtohavea separateaccuracyvalueforthevarious ECGsignalsandweusedtocalculatetheerror.

5. CONCLUSION

WedevelopedaspecialECGclassificationtechniquebased on CWT and a deep neural network. The ECG heartbeat signalisfirstconvertedintothetimefrequencydomainusing CWTtopreventtheeffectsofaliasingofseparatefrequency components. Then, features are recovered from a decomposedtime-frequencyscalogramusingAlexnet.The strategycompletelytakesadvantageofCWT'sadvantagesin multidimensionalsignalprocessingandalexnet'sadvantages inimagerecognition.ItwasputtothetestontheMITBIH arrhythmiadatabaseusingtheinter-patientparadigm.Due toitsextremelyaccurateECGcategorization,ourmethodhas the potential to be used as a clinical additional diagnostic tool. In general, early detection of ARR, CHF, and NSR is essential because they are key contributors to cardiovascular disease. After a thorough early diagnosis, effectivetherapy,suchasvagalstimulationormedications, canreducearrhythmiaandavoidcardiovasculardisease.

1.Kora,P.,Annavarapu,A.,Yadlapalli,P.,Krishna,K.S.R.,& Somalaraju,V.(2017).ECGbasedatrialfibrillationdetection usingsequencyorderedcomplexHadamardtransformand hybrid firefly algorithm. Engineering Science and Technology,anInternationalJournal,20(3),1084-1091.

2.Padmavathi,K.,&Ramakrishna,K.S.(2015).Detectionof Atrial Fibrillation using Autoregressive modeling. InternationalJournalofElectricalandComputerEngineering (IJECE),5(1),64-70.

3. Padmavathi, K., & Krishna, K. S. R. (2014, November). Myocardial infarction detection using magnitude squared coherence and support vector machine. In 2014 InternationalConferenceonMedicalImaging,m-Healthand EmergingCommunicationSystems(MedCom)(pp.382-385). IEEE.

4.Padmavathi,K.,&Ramakrishna,K.S.(2015).Detectionof atrial fibrillation using continuous wavelet transform and waveletcoherence.InternationalJournalofSystems,Control andCommunications,6(4),292-304.

5. Kora, P., & Krishna, K. S. R. (2016). ECG based heart arrhythmia detection using wavelet coherence and bat algorithm.SensingandImaging,17(1),12.

6.MajnaricL,SabanovicS.“Cardiovasculardiseaseresearch by using data from electronic health records”. Atherosclerosis,252:e41-e41.2016.

7.D.Zhang,"WaveletapproachforECGbenchmarkmeander adjustment and clamor decrease", in Proc. IEEE Int. Eng. Prescription.Biol.Soc,pp.1212-1215.2005.

8.Kora,P.,Meenakshi,K.,&Swaraja,K.(2019).Detectionof CardiacArrhythmiaUsingConvolutionalNeuralNetwork.In Soft Computing and Signal Processing (pp. 519-526). Springer,Singapore

© 2022,
|
Certified Journal | Page777
IRJET
Impact Factor value: 7.529 | ISO 9001:2008

Turn static files into dynamic content formats.

Create a flipbook