Adaptive lead weighted ResNet trained with different duration signals for classifying 12-lead ECGs

Zhibin Zhao1, Hui Fang2, Samuel Relton3, Jing Qin4, Yuhong Liu5, Zhijing Li1, David Wong6
1Xi'an Jiaotong University, 2Loughborough University, 3University of Leeds, 4Dalian University, 5Chengdu Medical College, 6University of Manchester


Abstract

Aim: The electrocardiogram (ECG) is a primary tool for diagnosing a variety of cardiac abnormalities and prognosing cardiovascular morbidity and mortality. However, manual analysis of ECG recordings (ECGs) is time-consuming and expert-dependent. This study aims to design a deep learning model to automatically identify cardiac abnormalities from 12-lead ECGs with high efficiency and precision. Dataset: A total of 6877 12-lead ECGs sampled at 500 Hz were provided by PhysioNet as the initial training set for the Computing in Cardiology Challenge 2020. ECGs ranged between 6 seconds to 60 seconds in duration. Methods: We first downsampled the ECGs to 250 Hz. To tackle different duration ECGs, we used a window with length 16384 to randomly clip each ECGs or pad zeros as online data augmentation. To learn effective features, a modified ResNet with larger kernel sizes was designed to model long-term dependencies. To model the relationship among 12 leads, a Squeeze-And-Excitation (SE) layer was embedded into the modified ResNet to learn the importance of each lead adaptively, and the overall model is called adaptive lead weighted ResNet. Weighted binary cross entropy loss was applied to deal with class imbalance. During the test, ECGs were processed multiple times using overlapping windows of length 16384 and the average result recorded. The training data was split by multi-label stratified 5-fold cross-validation. Results: We achieved the 5-fold cross-validation challenge scores F2 and G2 of 0.862 and 0.646, respectively (geometric mean=0.754). On the hidden test set, our model obtained F2 and G2 of 0.842 and 0.636, respectively (geometric mean=0.732) during the unofficial phase. Conclusion: Current results are promising, but further improvements might be achieved via: (i) the inclusion of hand-crafted features (ii) aggregating multiple classifier models (iii) effective data cleaning.