  Electrocardiograms (ECGs), a medical monitoring technology recording cardiac
activity, are widely used for diagnosing cardiac arrhythmia. The diagnosis is
based on the analysis of the deformation of the signal shapes due to irregular
heart rates associated with heart diseases. Due to the infeasibility of manual
examination of large volumes of ECG data, this paper aims to propose an
automated AI based system for ECG-based arrhythmia classification. To this
front, a deep learning based solution has been proposed for ECG-based
arrhythmia classification. Twelve lead electrocardiograms (ECG) of length 10
sec from 45, 152 individuals from Shaoxing People's Hospital (SPH) dataset from
PhysioNet with four different types of arrhythmias were used. The sampling
frequency utilized was 500 Hz. Median filtering was used to preprocess the ECG
signals. For every 1 sec of ECG signal, the time-frequency (TF) scalogram was
estimated and stacked row wise to obtain a single image from 12 channels,
resulting in 10 stacked TF scalograms for each ECG signal. These stacked TF
scalograms are fed to the pretrained convolutional neural network (CNN), 1D
CNN, and 1D CNN-LSTM (Long short-term memory) models, for arrhythmia
classification. The fine-tuned CNN models obtained the best test accuracy of
about 98% followed by 95% test accuracy by basic CNN-LSTM in arrhythmia
classification.
