Source-linked AI summary

Inter- and intra- patient ECG heartbeat classification for arrhythmia detection: a sequence to sequence deep learning approach

Sajad Mousavi, Fatemeh Afghah, U. Rajendra Acharya

arXiv:1812.07421v2q-bio.QMeess.SPphysics.med-ph

TL;DR

The paper addresses poor heartbeat-classification performance on imbalanced data and the reliance on intra-patient evaluation. It combines deep convolutional features, a sequence-to-sequence model, and oversampling, then reports better performance than existing methods under both intra- and inter-patient evaluation.

  • Problem

    Heartbeat classification methods can perform poorly on imbalanced datasets, particularly for minority classes, and many prior evaluations use intra-patient splits rather than the more realistic inter-patient setting.

    Source: §I · p. 2
  • Method

    The method combines CNN heartbeat features, an encoder-decoder sequence model with bidirectional recurrent units, and SMOTE oversampling, and evaluates both patient-split paradigms.

    Source: §I · p. 2, B. The architecture · p. 4, B. Results and Discussion · p. 7
  • Results

    The authors report that the method outperforms existing algorithms in both intra- and inter-patient evaluations.

    Source: B. Results and Discussion · pp. 6–7, §V · p. 7
  • Takeaways & Limitations

    The authors conclude that the method can provide a robust solution to class imbalance and suggest possible application to biomedical tasks such as sleep staging.

    Source: B. Results and Discussion · p. 6, §V · p. 7

Abstract

from arXiv · show

Electrocardiogram (ECG) signal is a common and powerful tool to study heart function and diagnose several abnormal arrhythmias. While there have been remarkable improvements in cardiac arrhythmia classification methods, they still cannot offer acceptable performance in detecting different heart conditions, especially when dealing with imbalanced datasets. In this paper, we propose a solution to address this limitation of current classification approaches by developing an automatic heartbeat classification method using deep convolutional neural networks and sequence to sequence models. We evaluated the proposed method on the MIT-BIH arrhythmia database, considering the intra-patient and inter-patient paradigms, and the AAMI EC57 standard. The evaluation results for both paradigms show that our method achieves the best performance in the literature (a positive predictive value of 96.46% and sensitivity of 100% for the category S, and a positive predictive value of 98.68% and sensitivity of 97.40% for the category F for the intra-patient scheme; a positive predictive value of 92.57% and sensitivity of 88.94% for the category S, and a positive predictive value of 99.50% and sensitivity of 99.94% for the category V for the inter-patient scheme.). The source code is available at https://github.com/SajadMo/ECG-Heartbeat-Classification-seq2seq-model.

I. INTRODUCTION

ECG heartbeat classification is time-consuming and error-prone when performed manually, while existing methods struggle with imbalanced classes and often rely on intra-patient evaluation. The paper proposes sequence-to-sequence deep learning with oversampling and evaluates it under both intra- and inter-patient paradigms.

I. INTRODUCTION

  • Manual heartbeat classification can be challenging and time-consuming for physicians, and hand annotation is often prone to error.Prior shallow machine-learning pipelines typically use preprocessing, feature extraction, and classification,,,, [5],, [7],.Source: §I · p. 1
  • Imbalanced datasets particularly impair sensitivity and positive predictive value for minority heartbeat classes, while intra-patient evaluations can be less realistic because training and test data may share patients.The introduction identifies ventricular escape (S) and fusion (F) beats as examples of affected classes.Source: §I · p. 2
  • The proposed approach combines sequence-to-sequence deep learning with SMOTE oversampling and is evaluated using both intra- and inter-patient paradigms.The authors report that it achieves the best results compared with existing works.Source: §I · p. 2

II. DATASET

The study evaluates the proposed method on the MIT-BIH Arrhythmia database using ECG lead II. It compares intra-patient testing with an inter-patient split that keeps patients separate between training and test sets.

II. DATASET

  • The MIT-BIH Arrhythmia database contains ECG records from 48 subjects sampled at 360 Hz, and the study uses lead II.The database is recommended by AAMI and includes five essential arrhythmia groups.Source: §II · p. 2
  • In the intra-patient paradigm, training and test beats are selected randomly, so beats from the same patient may occur in both sets.In the inter-patient paradigm, the sets come from different patients.Source: §II · p. 2
  • For inter-patient evaluation, records are divided into DS1 for training and DS2 for testing under the protocol proposed by de Chazal et al..The stated split avoids including heartbeats from the same patient in both sets.Source: §II · p. 2

III. METHODOLOGY

The methodology section introduces the proposed model as an automatic classifier for each heartbeat in an ECG signal.

III. METHODOLOGY

  • The section introduces a proposed model intended to automatically classify each heartbeat in a given ECG signal.It signals that the following sections provide the model description.Source: §III · p. 2

A. Pre-processing

Preprocessing converts an ECG signal into a labeled sequence of fixed-length heartbeats. The section also points to the AAMI-based heartbeat categories in the MIT-BIH database.

A. Pre-processing

  • The signal is normalized to the range from zero to one, and T waves are located with respect to annotated R-peaks.The R-peak annotations come from the MIT-BIH Arrhythmia database.Source: A. Pre-processing · p. 2
  • Table I presents the MIT-BIH heartbeat categories based on AAMI.The passage identifies the table's scope but does not provide its category values.Source: Table I · p. 3
  • The continuous signal is split into labeled heartbeats using extracted T waves, and each beat is resized to 280 samples without filtering or noise removal.Labels are assigned from the annotation file.Source: A. Pre-processing · p. 3

B. The architecture

The classifier combines a CNN with an encoder–decoder sequence model to label ECG beats. Its bidirectional recurrent units use both past and future sequence information, while the decoder produces beat labels.

B. The architecture

  • Three 1-D convolutional layers extract a feature vector for each beat in an input sequence before the encoder–decoder assigns beat categories.The layers use 32, 64, and 128 filters, with max pooling after the first two.Source: B. The architecture · p. 3
  • The encoder’s final hidden state initializes the decoder, which generates beat categories from the sequence representation.During training, the decoder also receives the target sequence shifted by one position and a special < GO > vector; testing does not use the shifted target.Source: B. The architecture · pp. 3–5
  • Bidirectional recurrent units process the input sequence in forward and reverse order, giving each state access to past and future inputs.The two networks’ outputs are combined as the BiRNN output.Source: B. The architecture · p. 4

A. Experimental setup

Experiments use the MIT-BIH arrhythmia database and assess four heartbeat groups under intra- and inter-patient splits. SMOTE is applied to training data to address the imbalance, and performance is measured with standard classification metrics.

A. Experimental setup

  • SMOTE oversamples minority heartbeat categories because normal beats greatly outnumber other groups in the MIT-BIH data.Oversampling is performed after splitting, using only the training data, to keep test information out of synthetic samples.Source: A. Experimental setup · p. 5
  • The intra-patient split randomly assigns beats to training and test sets, while the inter-patient split uses different patients for training and testing.For intra-patient evaluation, 80% of the 101,290 beats are used for training and 20% for testing; the inter-patient setup uses DS1 for training and DS2 for testing.Source: A. Experimental setup · p. 5
  • The evaluation covers N, S, V, and F heartbeat groups and reports sensitivity, positive predictive value, specificity, and accuracy.For inter-patient evaluation, DS1 contains N, S, and V beats for training, while DS2 contains those groups for testing.Source: A. Experimental setup · pp. 5–6
  • Table II compares the proposed classifier with state-of-the-art methods under the intra-patient split, and Table III makes the comparison under the inter-patient split.Table III uses DS1 for training and DS2 for testing.Source: Table II · p. 6, Table III · p. 6

B. Results and Discussion

The authors report that the proposed method outperforms the compared algorithms in both intra- and inter-patient evaluations. They also report strong results for minority heartbeat categories, including categories with few available beats.

B. Results and Discussion

  • The proposed sequence-to-sequence model outperforms the compared state-of-the-art algorithms across all reported metrics and groups in intra-patient evaluation.The evaluation uses real test beats without augmentation; Table II reports the comparison.Source: B. Results and Discussion · p. 6
  • The authors report strong results for minority categories S and F, which have 2,777 and 802 beats, respectively, in the intra-patient dataset.They present the method as a robust solution to class imbalance.Source: B. Results and Discussion · pp. 6–7
  • In inter-patient evaluation, the proposed method performs better overall than the listed methods across heartbeat categories, despite few S beats in training.Table III compares DS1 training with DS2 testing.Source: B. Results and Discussion · p. 7

V. CONCLUSION

The proposed heartbeat classifier combines a deep convolutional network with an encoder-decoder built from bidirectional recurrent neural networks and outperforms existing algorithms in both patient-evaluation paradigms.

  • The method combines a deep convolutional neural network with an encoder-decoder network using bidirectional recurrent neural networks as building blocks.Source: §V · p. 7
  • The proposed method significantly outperforms existing algorithms in both intra-patient and inter-patient paradigms.Source: §V · p. 7
  • The authors suggest applications in sleep staging and wearable devices, noting a maximum network size of 5.5MB.Sleep staging is described as having strong dependencies between stages and insufficient data.Source: §V · p. 7
Loading 1812.07421v2…