Skip to main content
QUICK REVIEW

[Paper Review] Techniques for visualizing LSTMs applied to electrocardiograms

Jos van der Westhuizen, Joan Lasenby|arXiv (Cornell University)|May 23, 2017
Time Series Analysis and ForecastingComputer Science41 references14 citations
TL;DR

This paper evaluates four visualization techniques for interpreting Long Short-Term Memory (LSTM) networks on single-lead electrocardiograms (ECGs), finding that learning an input deletion mask most effectively identifies salient features. The method achieves the highest class score reduction and aligns with medical theory, offering the most interpretable and reliable explanation of LSTM decisions in ECG classification.

ABSTRACT

This paper explores four different visualization techniques for long short-term memory (LSTM) networks applied to continuous-valued time series. On the datasets analysed, we find that the best visualization technique is to learn an input deletion mask that optimally reduces the true class score. With a specific focus on single-lead electrocardiograms from the MIT-BIH arrhythmia dataset, we show that salient input features for the LSTM classifier align well with medical theory.

Motivation & Objective

  • To improve interpretability of LSTMs in medical time series, particularly for ECG classification.
  • To evaluate and compare four visualization techniques for identifying salient input features in continuous-valued time series.
  • To determine which technique best reveals meaningful patterns that align with clinical knowledge.
  • To assess the efficacy of perturbation-based methods in explaining LSTM decisions without architectural modifications.
  • To establish a reliable, quantitative metric for comparing salience techniques on ECG data.

Proposed method

  • The study evaluates four visualization techniques: temporal output scores, class mode visualization, input occlusion, and learned input deletion masks.
  • For input occlusion, a sliding window of size w is applied to mask input segments, and the resulting drop in class score s_c is measured.
  • The learned deletion mask is optimized via gradient-based optimization to identify minimal input regions whose removal most reduces the true class score.
  • A normalized score reduction metric is used, scaled by the ratio (T - M^(n))/T to penalize larger occlusion areas.
  • The method uses only model inputs and outputs, requiring no architectural changes, and is applied to the MIT-BIH arrhythmia dataset with single-lead ECGs.
  • Hyperparameters are tuned via visual analysis, with w=25 for MIT-BIH and w=5 for MNIST, and α ∈ [0,1] sets the occlusion threshold.

Experimental results

Research questions

  • RQ1Which visualization technique most effectively identifies salient input features in LSTMs applied to continuous-valued time series like ECGs?
  • RQ2How well do the salient features identified by each technique align with established medical knowledge of cardiac arrhythmias?
  • RQ3Can a perturbation-based method like input deletion mask learning outperform gradient-based or occlusion-based approaches in interpretability and score reduction?
  • RQ4Does the performance of visualization techniques vary meaningfully with different occlusion thresholds or input window sizes?
  • RQ5To what extent do the identified salient regions remain consistent across the entire test dataset for each class?

Key findings

  • The learned input deletion mask technique achieved the highest average reduction in the true class score s_c, outperforming occlusion, class mode visualization, and temporal output scores.
  • At α = 0.9, the learned mask still caused a substantial drop in s_c, indicating it identified the most critical features for classification.
  • The salient input regions identified by the learned mask aligned well with medically recognized ECG features such as QRS complexes and ST segments.
  • Input occlusion and mask techniques were effective in identifying clinically relevant features, while class mode visualization produced completely uninterpretable results.
  • The performance of the learned mask was robust across different deletion thresholds, suggesting consistent identification of key features regardless of α.
  • The study found that multivariate physiological signals complicate visualization, reducing interpretability and leaving multivariate LSTM interpretation as an open problem.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.