Skip to main content

ECG Signal Classification for Arrhythmia Detection Using AI Approach

Page 1


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

Volume: 13 Issue: 05 | May 2026 www.irjet.net p-ISSN: 2395-0072

ECG Signal Classification for Arrhythmia Detection Using AI Approach

D.Sravanthi1 , M.Abhishek Reddy2 , P.Sainath Goud3 , S.Punith4

1234 Department of Information Technology, Vidya Jyothi Institute of Technology, Telangana, India

Abstract - This project aims to detect heart abnormalities from ECG signals using deep learning. An ECG records the electrical activityof the heart and helps in diagnosing arrhythmia. Traditional ECG analysis methods are slow and need manual interpretation .We use a 1D Convolutional Neural Network (CNN) to automatically classify ECG signals .The dataset used is the MIT-BIH ArrhythmiaDatabasefromPhysioNet.ECG signals are filtered to remove noise and normalized before training. The CNN model learns important heartbeat patterns directly from the data. We evaluate the model using accuracy precision, recall, and F1score.A simple GUI is built using Streamlit to visualize ECG and show predictions .This system can help doctors inearlyandfasterdetectionof heartdiseases.Themodel is trained and tested on real ECG samples to ensure reliable performance .It achieves high accuracy in distinguishing normal and abnormal heartbeats. This project demonstrates the power of AI in medical signal analysis.Future improvementscanincluderealtimeECG monitoring using IoT devices..

Key Words: ECG Signals, ECG Analysis,Physionet, Deep Learning , F1-score,Streamlit.

1. INTRODUCTION

The rapid advancement of Artificial Intelligence (AI) hassignificantlytransformedthehealthcareindustry by enabling intelligent systems for disease detection anddiagnosis.Inrecentyears,AI-basedmodelshave beenwidelyusedtoanalyzebiomedicalsignalssuchas Electrocardiogram(ECG) and Electroencephalogram (EEG),whichprovidevaluableinsightsintoheartand brainactivities.Thesetechnologieshaveimprovedthe accuracy and efficiency of medical diagnosis, supporting healthcare professionals in making informeddecisions..

ECGisawidelyuseddiagnostictoolthatrecordsthe electricalactivityoftheheartandhelpsinidentifying cardiovascularconditionssuchasarrhythmias,heart attacks, and other abnormalities. Similarly, EEG measurestheelectricalactivityofthebrainandisused to detect neurological disorders such as epilepsy, seizures,andsleep-relatedissues.BothECGandEEG

are non-invasive and play a crucial role in modern medicaldiagnostics.

MostexistingsystemsfocusonanalyzingeitherECGor EEGsignalsindependently,whichlimitstheirabilityto provideacomprehensiveunderstandingofapatient’s overallhealth.However,theheartandbrainareclosely interconnectedthroughphysiologicalandneurological pathways.Anyabnormalityinonesystemcaninfluence the other, making it important to study both signals togetherforbetterdiagnosisandmonitoring.

To address this limitation, this project introduces NeuroCardioAI,aunifiedplatformthatintegratesboth of the Electrocardiogram (ECG) and Electroencephalogram (EEG) signal analysis using advanced AI techniques. The system is designed to accept multiple types of input, including raw signal dataandimagesofmedicalreports,makingitflexible andpracticalforreal-worldapplications.Bycombining both domains, the system aims to provide a more holisticandaccuratediagnosticsolution.

Theproposedsystemincorporatesseveralstagessuch as data preprocessing, noise removal, normalization, feature extraction, and classification using deep learning models like Convolutional Neural Networks (CNN). The system processes ECG signals to detect heart-relatedabnormalitiesandEEGsignalstoidentify brain-related conditions. The results are displayed throughaninteractivedashboardthatprovidesclear andreal-timeinsightstousers.

Overall,thisprojectnotonlyfocusesonaccuracyand performance but also emphasizes usability and scalability.Itcanbeappliedinhospitals,telemedicine systems,andremotehealthmonitoringenvironments, wherequickandreliablediagnosisiscrucialandthisis alsoused to developanefficient,scalable,anduserfriendly healthcare system that enhances diagnostic capabilities by integrating cardiac and neurological analysis.NeuroCardioAIdemonstratesthepotentialof artificial intelligence in advancing the multi-domain healthcare solutions, improving early detection of diseases, andcontributing to better patientcare and clinicaloutcomes.

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

Volume: 13 Issue: 05 | May 2026 www.irjet.net p-ISSN: 2395-0072

2. LITERATURE REVIEW

Existing systems in biomedical signal analysis have made significant progress with the integration of Artificial Intelligence, particularly in analyzing physiologicalsignalssuchasElectrocardiogram(ECG) andElectroencephalogram(EEG).Thesesystemsare widelyused for detectingabnormalitiesinheartand brain activity, helping medical professionals in early diagnosisandmonitoring.Machinelearninganddeep learning models, especially Convolutional Neural Networks (CNN) and Long Short-Term Memory (LSTM), have shown high accuracy in classifying patternsinthesesignals.

InthedomainofElectroencephalogramanalysis,many existing systems focus on detecting heart-related disorderssuchasarrhythmias,myocardialinfarction, and other cardiovascular conditions. These systems use datasets like MIT-BIH Arrhythmia Database and applypreprocessingtechniquessuch asfilteringand normalizationbeforefeedingthedataintoAImodels. The results are usually presented as classification outputsindicatingnormalorabnormalheartactivity.

Similarly,EEG-basedsystemsaredesignedtoanalyze brainsignalsfordetectingneurologicalconditionssuch as epilepsy, seizures, sleep disorders, and cognitive states. These systems rely on feature extraction techniquesandAImodelstoidentifyabnormalbrain wavepatterns.EEGanalysisiswidelyusedinclinical applications and research for understanding brain functionalityanddiagnosingneurologicaldisorders.

Despite these advancements, most existing systems operateindependently,focusingeitheronECGorEEG signals. There is very limited integration between cardiacandneurologicaldataanalysis.Thisseparation restricts the ability to study the interaction between boththeheartandbrain,eventhoughbothsystemsare interconnectedthroughphysiologicalprocesses.

Some research efforts have attempted to combine multiple physiological signals to improve diagnostic accuracy,buttheseimplementationsareoftencomplex and not widely adopted in real-world applications. Additionally, many systems lack user-friendly interfaces and are not designed for real-time or scalable deployment, limiting their usability in practicalhealthcareenvironments.

Overall,existingsystemsprovidestrongperformance insingle-domainanalysisbutfallshortindeliveringa comprehensive,multi-domaindiagnosticsolution.This highlightstheneedforanintegratedsystemthatcan

analyze both ECG andEEGsignals together, whichis theprimarymotivationbehindthedevelopmentofthe NeuroCardioAIproject.

3. SYSTEM DESIGN

The system design of NeuroCardio AI follows a modular and layered approach to ensure flexibility, scalability, and efficient processing of both ECG and EEG signals. The system is divided into key components including data input, preprocessing, feature extraction, AI-based classification, and result visualization. Separate processing modules are designed for ECG and EEG signals to handle their unique characteristics, while a unified backend integratesbothpipelinesintoasingleworkflow.The design supports multiple input formats such as raw signal data and medical report images, ensuring adaptability in real-world scenarios. Overall, the system is structured to provide accurate, real-time predictions through a seamless and user-friendly interface.

ThesystemarchitectureofNeuroCardioAIisdesigned as a layered structure consisting of a frontend interface, backend server, preprocessing module, AI analysislayer,anddatabase.TheuseruploadsECGor EEG data through the frontend, which is then processedbythebackendusingtechniqueslikenoise removal and normalization. The processed data is passed to dedicated AI models for ECG and EEG

Figure 3.1- ModelArchitecture

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

Volume: 13 Issue: 05 | May 2026 www.irjet.net p-ISSN: 2395-0072

classification,andtheresultsarestoredinthedatabase and displayed on the dashboard. This unified architecture enables simultaneous analysis of heart and brain signals, making the system more efficient and comprehensive than traditional single-signal systems.

4. METHODOLOGY

1. Data Collection: The data used in this project is collectedfrompubliclyavailablebiomedicaldatasets thatcontainlabeledECGandEEGsignals.ECGdatais primarilyobtainedfromstandarddatasetssuchasthe MIT-BIH Arrhythmia Database, which includes annotatedrecordingsofdifferenttypesofheartbeats. Similarly,EEGdataiscollectedfromclinicaldatasets that contain brain signal recordings associated with conditions like seizures and other neurological abnormalities. These datasets are widely used in researchandprovidereliablegroundtruthlabelsfor trainingAImodels.

In addition to raw signal data, the system is also designedtoacceptimagesofECGandEEGreports.This enhances the flexibility of the application, allowing users to upload scanned reports or images captured frommedicaldevices.Thecollecteddataisorganized andstoredinastructuredformat,ensuringthatitcan be efficiently used for preprocessing, training, and evaluation. Proper data handling is essential to maintain consistency and improve the overall performanceofthesystem.

2. Image Preprocessing: Whentheinputisprovided intheformofimages,imagepreprocessingtechniques areappliedtoconvertthevisualdataintousablesignal information. The first step involves converting the imageintograyscaletosimplifyprocessingandreduce computational complexity. This is followed by noise reduction techniques such as filtering to remove unwanted distortions present in the image. Resizing andnormalizationarealsoappliedtostandardizethe imagedimensionsandintensityvalues.

Aftercleaningtheimage,thesystemextractswaveform patterns using techniques such as edge detection or contour extraction. These extracted signals are then converted into numerical arrays that resemble raw ECG or EEG signals. This step is crucial because it enablesthesystemtoprocessbothdigitalsignalsand scannedreportsinaunifiedmanner.Bydoingso,the project increases its applicability in real-world scenarioswheredatamaynotalwaysbeavailablein structuredformats.

3. Signal Preprocessing: Raw ECG and EEG signals often contain noise caused by external interference, muscle movements, or device limitations. Therefore, signal preprocessing is performed to enhance the quality of the data before feeding it into the model. Techniques such as bandpass filtering are used to remove unwanted frequency components, while normalizationensuresthatallsignalshaveaconsistent scale. This helps in improving the reliability of the extractedfeatures.

In addition, denoising techniques such as wavelet transformscanbeappliedtofurthercleanthesignals. Theprocessedsignalsarethensegmentedintosmaller windows or frames to capture meaningful patterns. Thisstepisimportantbecauseitpreparesthedataina format suitable for deep learning models. Proper preprocessing significantly improves the model’s abilitytolearnandgeneralizefromthedata.

4. Feature Extraction: Featureextractionisacritical step in transforming raw signals into meaningful representationsthatcanbeusedforclassification.In thisstage,importantcharacteristicssuchaswaveform peaks,frequencycomponents,andtemporalvariations are identified. For ECG signals, features like P,Q,R,S complex,andTwavesarecrucial,whileforEEGsignals, differentbrainwavefrequenciessuch asalpha, beta, theta,anddeltaareanalyzed..

Advanced techniques such as time-domain and frequency-domain analysis are used to extract these features. In deep learning approaches, feature extraction can also be performed automatically by convolutionallayers withintheneural network.This reducestheneedformanualfeatureengineeringand allows the model to learn complex patterns directly fromthedata.Effectivefeatureextractionplaysavital roleinimprovingclassificationaccuracy.

5.Model Building: Themodelbuildingphaseinvolves designingandtrainingdeeplearningarchitecturesto classify ECG and EEG signals. For ECG analysis, ConvolutionalNeuralNetworks(CNN)arecommonly used due to their ability to capture spatial and temporalpatternsinwaveformdata.TheECGmodel typically consists of multiple convolutional layers followed by pooling layers, which help in extracting hierarchical features from the signal. These features are then passed through fully connected layers to classifythesignalintodifferentarrhythmiacategories suchasNormal,Ventricular,orSupraventricularbeats.

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

Volume: 13 Issue: 05 | May 2026 www.irjet.net p-ISSN: 2395-0072

ForEEGanalysis,asimilardeeplearningapproachis used,butwithmodificationstohandlethecomplexity of brain signals. Models such as CNN or specialized architectures like EEGNet are employed to capture both temporal and frequency-based features of EEG data.Insomecases,hybridmodelslikeCNN-LSTMare used to capture both spatial and sequential dependenciesinthesignals.TheEEGmodelclassifies signals into categories such as normal, seizure, or abnormalbrainactivity.BothECGandEEGmodelsare trained using labeled datasets, optimized using techniques like learning rate scheduling and early stopping,andevaluatedusingmetricssuchasaccuracy, precision,recall,andF1-score.Theintegrationofthese twomodelsintoasinglesystemisthekeyinnovation ofthisproject,enablingsimultaneousanalysisofheart andbrainsignals.

6. Model Training & Testing: Themodeltrainingand testing process was performed using a two-stage approach,consistingofinitialtrainingwithfrozenbase layersfollowedbyfine-tuningtoimproveperformance. The Adam optimizer was utilized alongside the CategoricalCross-Entropylossfunctionforaduration of 50 epochs. Because the model training & testing requiredstability,thisspecificprocesswasfollowedby thedevelopers.

1. Accuracy: It describes the total rightness of the classification system when the calculation of the amount of right samples happens among the total group.Ithasbeenobservedthataccuracyprovidesa clear view of how well the system performs. The divisionofcorrectresultsbythetotalnumberofitems ishowaccuracyiscalculatedbecauseitrepresentsthe wholetruthofthedata.

2. Precision: Precision measures the proportion of correctly predicted positive cases. Precision is important because precision stops the wrong identification of healthy cases as sick cases. High resultsforprecisionareachievedwhenthepredictions become more dependable. Reliable predictions are createdbyprecisionsothatfalsepositivesstayatalow level.

3.Recall:Thecapacityofthemodeltofindrealtumor casesismeasuredbyrecall.Medicalprofessionalsstate that this is necessary so that no tumors are missed duringthecheckup.Sensitivityisimprovedwhenrecall numbersincrease.Recallensuresthatactualsicknessis not ignored because recall focuses on finding every positivecase.

4.F1-Score:Abalancedassessmentisprovidedbythe F1 score which is the harmonic average of precision and recall. It has been observed that this becomes helpfulwhenthereductionofbothtypesoferrorsis required. Better performance of the whole system is shownbyahighF1score.F1-scoreremainsakeyvalue for researchers because F1-score combines two differentmeasuresintoone.

5. RESULTS AND DISCUSSION

TheresultsoftheNeuroCardioAIsystemdemonstrate itseffectivenessinaccuratelyclassifyingbothECGand EEG signals usingdeep learningmodels.The trained modelsareabletoidentifydifferentcategoriesofheart andbrainconditionswithhighaccuracy,basedonthe input data provided. For ECG signals, the system successfullydetectsarrhythmiapatterns,whileforEEG signals, it identifies abnormalities such as seizure activity. The performanceof the modelsis evaluated usingmetricssuchasaccuracy, precision,recall,and F1-score,whichindicatereliableandconsistentresults.

Thesystemalsoprovidesreal-timepredictionsthrough aninteractivedashboard,makingiteasyforusersto visualize and interpret the results. The inclusion of confidencescoreshelpsinunderstandingthereliability of each prediction. By integrating both ECG and EEG analysis into a single platform, the system offers a morecomprehensivediagnosticapproachcomparedto traditional models. This dual-analysis capability enhances the overall usefulness of the system in clinicalandremotehealthcareapplications.

Fromadiscussionperspective,theresultshighlightthe advantages of combining cardiac and neurological signalanalysis.Thesystemshowsimproveddiagnostic capability by considering multiple physiological signals, whichcanhelp inidentifyinginterconnected conditions. However, the performance of the model depends on the quality and diversity of the training data, and further improvements can be made by incorporating larger datasets and advanced architectures. Overall, the project demonstrates the potential of AI in developing efficient, scalable, and multi-domainhealthcaresolutions.

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

Volume: 13 Issue: 05 | May 2026 www.irjet.net p-ISSN: 2395-0072

6.

CONCLUSIONS

In conclusion, this project successfully delivers a complete, end-to-end deep learning system for ECG arrhythmiaclassificationthatbridgesthegapbetween researchandreal-worlddeployment.Througharobust data preprocessing pipeline, effective model architecture selection particularly the highperforming Enhanced CNN and advanced training strategies, the system achieves strong and reliable classification performance on standard benchmarks. Whilechallengesremainindetectingrareclassessuch asFusionbeats,theresultsareconsistentwithexisting researchandvalidatethesystem’sdesign.Moreover, the integration of a scalable Flask-based API and an interactive web interface demonstrates practical applicability in clinical settings. Overall, the project represents a meaningful advancement toward AIassisted cardiac care, combiningscientific rigorwith deployment readiness and providing a strong foundation for future improvements and clinical integration.

7. REFERENCES

1.Wang, R., Fan, J., & Li, Y. (2021). Deep multi-scale fusion neural network for multi-classdetection. IEEE Journal of Biomedical and Health Informatics, 24(9), 2461–2472.

2.Chen,C.,Hua,Z.,Zhang,R.,Liu,G.,&Wen,W.(2020). Automated arrhythmia classification based on a combinationnetworkofCNNandLSTM,57,101819..

3.Ribeiro,A.H.,etal.(2020).Automaticdiagnosisofthe 12-lead ECG using DNN. Nature Communications, 11(1),1760.

4.Tan, M., & Le, Q. (2019). EfficientNet: Rethinking model scaling for CNN. Proceedings of the 36th InternationalConferenceonML.6105–6114.

Fig 5.1:showingtheheartdisesasein ventricles(ECG)
Fig 5.2:showingtheoutputforEEG

Turn static files into dynamic content formats.

Create a flipbook
ECG Signal Classification for Arrhythmia Detection Using AI Approach by IRJET Journal - Issuu