Transformer-Based NSVT Detection with Onset and Offset Identification

Lucia Vavassori1, Raphael Schneider1, Javier Saiz-Vivo1, Valentina Corino2
1Medtronic Bakken Research Center, 2Politecnico di Milano


Abstract

Aim: Non-sustained ventricular tachycardia (NSVT) is a short-duration arrhythmia associated with an increased risk of sudden cardiac death in patients with hypertrophic cardiomyopathy (HCM). Conventional Holter monitoring, typically limited to 24–48 hours, often fails to capture transient NSVT episodes, leading to underestimation of arrhythmic risk. Although implantable cardiac monitors enable continuous rhythm monitoring, automated NSVT detection remains limited. This study evaluates the feasibility of a Transformer-based deep learning approach for automated NSVT detection in continuous monitored cohort.

Methods: A retrospective dataset comprising 3,503 single-lead ECG recordings from 1,165 HCM patients, including 7,123 expert-annotated NSVT episodes, was analyzed. ECG signals were segmented into fixed-length 4-s windows with 50% overlap and labeled using a four-class scheme modeling normal rhythm, arrhythmic onset, sustained activity, and offset. A Transformer encoder was trained using a weighted multiclass cross-entropy loss to address class imbalance. Model performance was evaluated at window, duration, and patient levels.

Results: On the test set, the proposed approach achieved a weighted F1-score of 0.72, a balanced accuracy of 0.71, and a ROC–AUC of 0.88 at window level. High sensitivity was observed at duration (0.96), and episode (0.97) levels, indicating reliable detection of clinically relevant NSVT events. Arrhythmic burden estimation showed a strong correlation between predicted and true burden values (Pearson r = 0.85).

Discussion: These findings demonstrate the feasibility of Transformer-based architectures combined with episode-aware labeling for continuous NSVT detection in patients with HCM. While the approach accurately localizes arrhythmic activity over time, limitations related to window-level labeling affect burden estimation accuracy. The proposed framework represents a first step toward real-time, automated NSVT monitoring and highlights directions for future improvements in labeling strategies and clinical applicability.