# HAN-ECG: An Interpretable Atrial Fibrillation Detection Model Using Hierarchical Attention Networks

arXiv: https://arxiv.org/abs/2002.05262 · HTML: https://mlsanity.com/paper/2002.05262/

## Key facts

- Cited by 14 papers in the map (data through 14 Oct 2026).
- First posted on arXiv 12 Feb 2020.

## Built on by (most cited first, 14 of 14)

- [Designing ECG Monitoring Healthcare System with Federated Transfer Learning and Explainable AI](https://mlsanity.com/paper/2105.12497/) (2021)
- [Explainable AI for clinical and remote health applications: a survey on tabular and time series data](https://mlsanity.com/paper/2209.06528/) (2022)
- [ECGBERT: Understanding Hidden Language of ECGs with Self-Supervised Representation Learning](https://mlsanity.com/paper/2306.06340/) (2023)
- [Intuitively Assessing ML Model Reliability through Example-Based Explanations and Editing Model Inputs](https://mlsanity.com/paper/2102.08540/) (2021)
- [RawECGNet: Deep Learning Generalization for Atrial Fibrillation Detection from the Raw ECG](https://mlsanity.com/paper/2401.05411/) (2023)
- [SQUWA: Signal Quality Aware DNN Architecture for Enhanced Accuracy in Atrial Fibrillation Detection from Noisy PPG Signals](https://mlsanity.com/paper/2404.15353/) (2024)
- [IMLE-Net: An Interpretable Multi-level Multi-channel Model for ECG Classification](https://mlsanity.com/paper/2204.05116/) (2022)
- [HeartBERT: A Self-Supervised ECG Embedding Model for Efficient and Effective Medical Signal Analysis](https://mlsanity.com/paper/2411.11896/) (2024)
- [Deciphering Heartbeat Signatures: A Vision Transformer Approach to Explainable Atrial Fibrillation Detection from ECG Signals](https://mlsanity.com/paper/2402.09474/) (2024)
- [SIM-ECG: A Signal Importance Mask-driven ECGClassification System](https://mlsanity.com/paper/2110.14835/) (2021)
- [Automated Atrial Fibrillation Classification Based on Denoising Stacked Autoencoder and Optimized Deep Network](https://mlsanity.com/paper/2202.05177/) (2022)
- [MMA-RNN: A Multi-level Multi-task Attention-based Recurrent Neural Network for Discrimination and Localization of Atrial Fibrillation](https://mlsanity.com/paper/2302.03731/) (2023)
- [Hierarchical Attention Network for Interpretable ECG-based Heart Disease Classification](https://mlsanity.com/paper/2504.03703/) (2025)
- [MSAIC-Net: A Multi-Scale Attention and Imbalance-Aware Contrastive Network for ECG-Based Myocardial Substrate Abnormality Detection](https://mlsanity.com/paper/2606.06718/) (2026)

## Abstract (arXiv)

Atrial fibrillation (AF) is one of the most prevalent cardiac arrhythmias that affects the lives of more than 3 million people in the U.S. and over 33 million people around the world and is associated with a five-fold increased risk of stroke and mortality. like other problems in healthcare domain, artificial intelligence (AI)-based algorithms have been used to reliably detect AF from patients' physiological signals. The cardiologist level performance in detecting this arrhythmia is often achieved by deep learning-based methods, however, they suffer from the lack of interpretability. In other words, these approaches are unable to explain the reasons behind their decisions. The lack of interpretability is a common challenge toward a wide application of machine learning-based approaches in the healthcare which limits the trust of clinicians in such methods. To address this challenge, we propose HAN-ECG, an interpretable bidirectional-recurrent-neural-network-based approach for the AF detection task. The HAN-ECG employs three attention mechanism levels to provide a multi-resolution analysis of the patterns in ECG leading to AF. The first level, wave level, computes the wave weights, the second level, heartbeat level, calculates the heartbeat weights, and third level, window (i.e., multiple heartbeats) level, produces the window weights in triggering a class of interest. The detected patterns by this hierarchical attention model facilitate the interpretation of the neural network decision process in identifying the patterns in the signal which contributed the most to the final prediction. Experimental results on two AF databases demonstrate that our proposed model performs significantly better than the existing algorithms. Visualization of these attention layers illustrates that our model decides upon the important waves and heartbeats which are clinically meaningful in the detection task.
