Artificial Intelligence & Data Analysis

Deep Learning for Heartbeat Annotation

Deep Learning for robut Heartbeat Annotation

Task

Heartbeat intervals form the basis for key metrics such as heart rate and heart rate variability and are therefore an important indicator of a patient’s health status.

While established, rule-based methods for heartbeat annotation (e.g. Pan–Tompkins variants) have proven effective for healthy signals, they reach their limits when applied to pathological and complex heartbeat  MechanoCardioGrams (MCG), which are derived from acceleration and angular velocity signals of inertial sensors.

The customer therefore required a robust and reliable solution for automated heartbeat annotation that performs consistently even for elderly or medically impaired individuals.

The goal of the project was to develop an algorithm capable of reliably detecting heartbeats in both healthy and pathological MechanoCardioGrams.

Solution approach

To develop a robust heartbeat annotation solution, a data-driven approach was pursued that deliberately combines classical machine learning techniques with modern deep learning methods.

Initially, heartbeat candidates were characterized using a wide range of signal features, including amplitudes, temporal rise and fall parameters, and additional morphological properties of the MechanoCardioGrams. These feature-based models provided valuable insights into which signal structures are particularly relevant for pathological heartbeat patterns and helped to specifically reduce false positive detections.

Building on these insights, a deep learning model was developed that no longer relies on explicitly predefined features but instead learns relevant representations directly from the multi-channel sensor signals. A 1D CNN encoder–decoder architecture with attention mechanisms was employed, enabling the model to capture temporal relationships across multiple cardiac cycles.

The attention layers allow the model to adaptively focus on the most relevant time points within the signal, while the encoder–decoder structure simultaneously creates a robust, noise-resistant signal representation.

By combining both approaches, a model was developed that achieves high reliability for heartbeat annotation in both healthy and pathological MechanoCardioGrams.

Result

The developed solution enables reliable heartbeat annotation in complex and pathological MechanoCardioGrams. By combining feature-based knowledge with a 1D CNN encoder–decoder architecture including attention mechanisms, relevant temporal patterns are robustly identified.

This project was presented at the MathWorks AI Day in Dresden by Dr. Yvonne Rippers.

Overview 1D CNN Encoder-Decoder Architecture with Self Attention; examples of SeismoCardioGrams and GyroCardioGrams; Evaluation Results of pathological MechanoCardioGrams
Overview 1D CNN Encoder-Decoder Architecture with Self Attention; examples of SeismoCardioGrams and GyroCardioGrams; Evaluation Results of pathological MechanoCardioGrams

Projektteam

Dr. Momme Winkelnkemper – Algorithms, data analysis and modelling

Dr. Momme Winkelnkemper

Algorithms, data analysis and modelling

Dr. Yvonne Rippers

Machine learning and marketing

Dr. Yvonne Rippers –  Machine learning and marketing