Source-linked AI summary
DR-net-Mamba: Selective State-Space Modeling for Long-Range ECG Time-Series Denoising
Basile Morel, Samuel Ruiperez-Campillo, Andreas P. Streich, Julia E. Vogt, Thomas Hofmann
TL;DR
Non-stationary ECG noise and long recordings challenge denoising methods with limited receptive fields or costly sequence scaling. DR-net-Mamba adds selective state-space blocks at a convolutional bottleneck, and the study reports improved reconstruction, noise robustness, and diagnostic discrimination, with calibration effects depending on the classifier.
Problem
ECG denoising must address non-stationary noise and long recordings, while existing approaches face limited temporal context or computational costs.
Source: §I · p. 1Method
DR-net-Mamba inserts selective state-space blocks at a convolutional UNet bottleneck to extend temporal context with linear computational overhead.
Source: §I · p. 1Results
The convolutional encoder–decoder gains reconstruction fidelity and noise robustness and improves downstream diagnostic AUROC, while calibration effects are smaller and classifier-dependent.
Source: §VI · p. 8Takeaways & Limitations
The results indicate that long-range temporal context matters for physiological signal processing, while reconstruction gains do not translate uniformly to calibration gains.
Source: §VI · p. 8, B. Clinical Translation: When… · p. 8Clinical references are not truly clean, so residual artifacts become part of the reconstruction target and complicate interpretation of clinical reconstruction metrics.
Source: E. Limitations · p. 10
Abstract
from arXiv · showhide
Electrocardiogram (ECG) recordings are corrupted by non-stationary noise sources that degrade diagnostic reliability, particularly in ambulatory and long-duration recordings. Deep learning denoisers exist, but convolutional architectures are limited by their receptive field, transformer-based models scale quadratically with sequence length, and diffusion-based approaches incur prohibitive inference cost. We propose a Mamba-augmented model that inserts selective state-space blocks at the convolutional bottleneck, combining local feature extraction with long-range temporal modeling at linear complexity. We comprehensively evaluate the proposed model with respect to reconstruction fidelity, noise robustness, recording-length scaling, and downstream diagnostic classification across over 40 pathology classes. On synthetic and real datasets, our model achieves the highest SNR and lowest RMSE, with the Mamba advantage increasing with sequence length and in low-SNR regimes. On classification with two independent classifiers, the proposed Mamba-based models achieve the best macro AUROC among all denoisers and improve over their convolutional base models. Calibration is more nuanced and classifier-dependent: denoising improves Binary Cross-Entropy and Brier score on Inception1D but often fails to beat the noisy input on ResNet1D-Wang, and the lead-specific Mamba variant is the only denoiser to improve both calibration metrics over the noisy baseline on both classifiers. Per-class analysis reveals a morphology-dependent benefit: Mamba substantially improves ST/T-change diagnoses, which depend on broad, context-sensitive waveforms.
I. INTRODUCTION
ECG denoising must handle non-stationary noise and long recordings, where existing approaches face limits in clean training targets, sequence scaling, or inference cost. DR-net-Mamba combines a convolutional encoder–decoder with selective state-space blocks and is evaluated across reconstruction, robustness, recording length, and diagnostic classification.
I. INTRODUCTION
- Non-stationary, overlapping noise can reduce ECG SNR until human readers and automated classifiers fail, while long ambulatory recordings intensify the need for scalable, low-latency denoising.Classical methods can require expert tuning and degrade under realistic multi-source noise; supervised methods also face scarce clean clinical ground truth, while transformers and diffusion models bring scaling or inference costs.Source: §I · p. 1
- DR-net-Mamba inserts selective state-space blocks at a convolutional UNet bottleneck to extend temporal context to the full sequence with linear computational overhead.The study evaluates reconstruction fidelity, noise robustness, recording-length scaling, and downstream classification of 44 PTB-XL pathology classes.Source: §I · pp. 1–2
II. RELATED WORK
- Mamba makes state-transition parameters input-dependent, allowing selective information propagation or forgetting with linear-time sequence modeling.The paper applies this approach to ECG denoising, a setting it describes as unexplored across diverse noise conditions and recording lengths.Source: §I · p. 1, §II · p. 2
- Prior ECG applications of Mamba target classification or short-segment enhancement; this work instead denoises directly in the time domain and evaluates several dimensions in one framework.The cited prior denoiser MECGE works in the STFT domain, and its per-frame frequency sequences make memory scale with recording length.Source: §II · p. 2
A. Architecture
The architecture adds selective state-space modeling to a convolutional denoiser while retaining local feature extraction and a compact two-stage design. Its bottleneck extends temporal context beyond the encoder’s roughly 1.5-second receptive field, and the detail-restoration stage refines full-resolution waveform features.
1) Baseline architectures.:
- Among the benchmarked convolutional, recurrent, and state-space families, the proposed architecture builds on a 1D UNet and can cascade a full-resolution detail-restoration network.The baselines include UNet, IMUNet, two DR-net variants, DRNN, DAE, and the STFT-based MECGE.Source: 1) Baseline architectures · p. 2
2) Convolutional Backbone and its Receptive-Field Limitation:
- The encoder downsamples signals 20×, but its convolutional receptive field is only 542 time steps, approximately 1.5 seconds at 360 Hz.Skip connections join corresponding encoder and decoder stages, and bilinear upsampling restores the original resolution.Source: 2) Convolutional Backbone and its… · pp. 2–3
3) Selective State-Space Bottleneck:
- Three Mamba blocks at the bottleneck model dependencies across the full sequence while operating on a 20× downsampled, 48-channel sequence.Each block uses layer normalization, an input-dependent selective state-space layer, gating, and residual addition; three blocks performed best in preliminary experiments.Source: 3) Selective State-Space Bottleneck · p. 3, Figure 2 · p. 4
4) Two-Stage Detail Restoration:
- The optional DR-net takes the noisy signal and first-stage estimate, then produces a refined single-channel output through four full-resolution branches.Branches use kernel sizes 3, 5, 13, and 15 with residual blocks and channel attention to preserve sharp features that may be attenuated at the bottleneck.Source: 4) Two-Stage Detail Restoration · p. 3
5) Learnable Signal Compression:
- A learnable log-compression layer factors out dynamic range so the model can devote capacity to morphology rather than amplitude variation.The inverse transform is applied to the network output to recover the original amplitude scale; compression may also stabilize gradient flow through the recurrent Mamba layers.Source: 5) Learnable Signal Compression · p. 3
6) Parameter Count and Memory Scaling:
- The three Mamba blocks add 533,088 parameters to the 227K-parameter UNet backbone, for 759,826 total parameters, below MECGE’s 819K.Mamba runs after 20× downsampling, keeping effective batch size constant with input length, unlike MECGE’s frequency-axis branch.Source: 6) Parameter Count and Memory Scaling · pp. 3–4
B. Training
Training and evaluation combine clinical, ambulatory, and synthetic ECG cohorts with shared preprocessing and multi-source noise corruption. PTB-XL supplies downstream diagnostic labels, while the synthetic cohort provides controlled clean references.
B. Training
- Models are trained with MSE loss, batch size 32, lead-wise median and interquartile-range normalization, and early stopping on validation loss.PTB-XL training uses a lead-agnostic model or 12 lead-specific instances, which can specialize to each lead’s morphology.Source: B. Training · p. 4
A. Clinical Cohorts
- PTB-XL contains 21,799 clinical 12-lead ECGs from 18,869 patients; after excluding flagged records, the described splits include 13,480 training and 1,639 test segments.Records are 10 seconds at 500 Hz and carry subsets of 44 diagnostic statements that can be aggregated into five superdiagnostic classes.Source: A. Clinical Cohorts · p. 4
B. Synthetic Cohort
- The synthetic cohort uses a dynamical ODE model to generate 40-second, 360-Hz signals, with 1,024 training, 256 test, and 256 validation segments.The first five seconds of each 45-second simulation are discarded to remove transient warm-up artifacts.Source: B. Synthetic Cohort · p. 4
C. Data Extraction and Preprocessing
- Clinical recordings are resampled to 360 Hz, bandpass-filtered from 1–45 Hz, and robustly normalized using training-set median and interquartile range.The filter retains clinically relevant ECG content while attenuating baseline wander and suppressing powerline and high-frequency noise.Source: C. Data Extraction and Preprocessing · p. 4
D. Noise Model
- Training applies baseline wander, muscle artifact, electrode motion, and white Gaussian noise simultaneously at prescribed SNRs.The respective levels are 2.5, 7.5, 12.5, and 22.5 dB, chosen following the ranges recommended by.Source: D. Noise Model · p. 5
V. RESULTS
DR-net-Mamba leads reconstruction fidelity across the synthetic and clinical datasets, with statistically significant gains over its baselines. The section also describes the evaluation pipeline, inference costs, and component ablations.
A. Experiments and Evaluation
- The downstream pipeline corrupts and denoises independently normalized PTB-XL leads, then evaluates reassembled signals with two classifiers across 44 diagnostic classes.Reconstruction fidelity is evaluated on one selected lead per record; classification metrics include macro AUROC, BCE, Brier score, sensitivity, specificity, and F1.Source: A. Experiments and Evaluation · p. 5
- On a 10 s ECG window, DR-net Mamba1-3B runs in 11.9 ms with 15.6 MB peak GPU memory; all evaluated models process 10 s in under 50 ms.The comparison reports 16.0 ms for DR-net-IMUNet at comparable memory.Source: A. Experiments and Evaluation · p. 5
B. ECG Reconstruction
- Every proposed-model comparison against its respective baseline is significant on all three datasets; the smallest PTB-XL gain is +0.83 dB SNR over DR-net-IMUNet.The reported smallest gains are +0.29 dB on synthetic data and +0.34 dB on European ST-T, also over DR-net-IMUNet.Source: B. ECG Reconstruction · p. 5
- At 0.96 dB empirical noisy SNR, DR-net-Mamba achieves the highest SNR and lowest RMSE on synthetic, PTB-XL, and European ST-T datasets.The figure reports SNR under medium noise; analogous RMSE results are reported in Figure S8.Source: B. ECG Reconstruction · p. 5, Figure 3 · p. 6
- Learnable compression adds +0.9 dB SNR with single-stage Mamba, but its effect vanishes with DR-net; Mamba and DR-net each contribute significant gains.The compression effect with DR-net is -0.0 dB (95% CI [-0.1, +0.1]).Source: B. ECG Reconstruction · p. 6
C. Noise Robustness
DR-net-Mamba has the highest output SNR across noise types and clinically relevant input levels, while its advantage across recording lengths varies by dataset. Mamba-based models also lead denoiser AUROC, with calibration and per-class findings depending on classifier and diagnosis.
D. Impact of Recording Length
- On synthetic data, UNet-Mamba’s SNR gain over UNet grows from approximately 1 dB at 10 s to roughly 2.5 dB at 40 s; on European ST-T, its gain peaks around 10 s.On European ST-T, UNet-Mamba is already ahead by approximately 1 dB at 5 s, and the gain diminishes at longer lengths.Source: D. Impact of Recording Length · p. 6
1) Aggregated Evaluation:
- Mamba-based models achieve the best overall AUROC across both classifiers and improve over their convolutional base models; lead-specific UNet-Mamba further improves ResNet1D-Wang AUROC.The evaluation uses PTB-XL under strong noise.Source: 1) Aggregated Evaluation · p. 6
- On Inception1D, lead-specific UNet-Mamba yields BCE 6.89 and Brier 1.82 vs. noisy 7.85/2.02; on ResNet1D-Wang, it alone improves both: 7.10/1.89 vs. 7.71/2.01.Other denoisers do not consistently improve calibration over the noisy input on ResNet1D-Wang.Source: 1) Aggregated Evaluation · pp. 6–7
C. Noise Robustness
- Across noise types and clinically relevant input SNR levels, DR-net-Mamba achieves the highest output SNR; with combined noise, it and MECGE degrade more gracefully than convolutional baselines.The figure plots reconstruction SNR against input SNR for EM, BW, MA, AWGN, and combined noise on European ST-T.Source: C. Noise Robustness · p. 6, Figure 4 · p. 7
1) Aggregated Evaluation:
- For Inception1D, noisy input sensitivity is 0.852 vs. 0.815 for clean input, while the three Mamba variants rank first through third on F1 with specificity of 0.839–0.841.The passage reports similar trends for ResNet1D-Wang.Source: 1) Aggregated Evaluation · p. 7
2) Evaluation by Superdiagnostic Class:
- Mamba-based models achieve the highest AUROC across all five superdiagnostic classes; lead-specific UNet-Mamba leads in HYP, MI, NORM, and STTC.DR-net-Mamba ranks second-best in CD, HYP, MI, and STTC.Source: 2) Evaluation by Superdiagnostic Class · p. 7
3) Evaluation by Diagnostic Class:
Mamba’s advantage depends on recording length and waveform structure: it grows with longer synthetic recordings, while clinical gains vary by diagnosis and classifier. Across clinical classes, the strongest gains occur for ST/T-change diagnoses, and calibration outcomes differ between classifiers.
A. Long-Range Context as an Inductive Bias for Physiological Denoising
- Figure 5 compares reconstruction SNR across recording lengths for UNet and UNet-Mamba without signal compression on synthetic and European ST-T data, with shaded bands marking 95% bootstrap confidence intervals.Source: Figure 5 · p. 8
- On synthetic data, the Mamba advantage grows with sequence length as distant beats remain predictive; on clinical ECGs, it peaks near 10 s as beat variability and pathology reduce distant-beat predictiveness.The UNet’s convolutional receptive field saturates at about 1.5 s, while Mamba propagates information across the full downsampled sequence.Source: A. Long-Range Context as an Inductive… · p. 8
- Under combined noise, DR-net-Mamba and MECGE degrade more gracefully than purely convolutional models, consistent with benefits from temporal or spectral global context.The Mamba advantage over convolutional models is most pronounced under heavy AWGN, which lacks local temporal cues.Source: A. Long-Range Context as an Inductive… · p. 8
B. Clinical Translation: When Long-Range Context Helps Most
- For all diagnoses with more than 18 segments, lead-specific Mamba either improves or preserves AUROC over noisy input, with substantial gains on ST/T-change diagnoses.The ST/T-change benefit is linked to broad waveforms whose interpretation depends on surrounding baseline; conduction-disturbance performance matches the convolutional baseline.Source: B. Clinical Translation: When… · p. 8
- Mamba-based denoising improves diagnostic performance across both classifiers and nearly all pathology classes, but calibration gains are classifier-dependent.Inception1D generally improves BCE and Brier relative to noisy input; on ResNet1D-Wang, several denoisers improve AUROC yet match or worsen noisy-baseline calibration.Source: B. Clinical Translation: When… · pp. 8–9
C. The Sensitivity–Specificity Shift Induced by Noise
Noise shifts classification toward higher sensitivity but lower specificity, while denoising partly restores specificity. Across the broader evaluation, benefits depend on waveform morphology, and several data and pipeline boundaries constrain interpretation.
C. The Sensitivity–Specificity Shift Induced by Noise
- Noisy signals raise sensitivity over clean baselines (0.852 vs. 0.815 for Inception1D) but lower specificity (0.697 vs. 0.863); denoising partly restores specificity.Mamba models have the highest F1 scores and specificity closest to the clean baseline.Source: C. The Sensitivity–Specificity Shift… · p. 9
D. DR-net-Mamba in the Broader Denoising Landscape
- Cross-study absolute metrics are unreliable because prior studies use different clean-signal sources, noise protocols, segment lengths, and metric definitions.The study instead compares within-study rankings using a shared four-noise protocol; a standardized ECG denoising benchmark remains absent.Source: D. DR-net-Mamba in the Broader… · pp. 9–10
- Context-sensitive ST/T changes benefit most from long-range modeling, whereas sharp QRS features can be harmed by bottleneck over-smoothing.Lead-specific denoising can preserve calibration where lead-agnostic models degrade it.Source: Further Machine Learning in Healthcare… · p. 10
E. Limitations
- Clinical reconstruction metrics partly measure reproduction of residual artifacts in the target, so Stage 2 improvements on clinical data require that caveat.Each lead is denoised independently, leaving 12-lead spatial correlations unused and incurring 12× training cost for the lead-specific variant.Source: E. Limitations · pp. 10–11
APPENDIX
The appendix details receptive-field computation, a signal-compression ablation, memory-scaling differences, and training configurations for the compared models.
A. Receptive Field Computation
- The receptive field is the number of input samples that can influence one output sample; pooling layers use their pool size and stride in the computation.Table S1 details each UNet encoder layer's contribution.Source: A. Receptive Field Computation · p. 13, Table S1 · p. 13
B. Signal Compression Ablation
- Without learnable log-compression, UNet-Mamba converges faster initially but plateaus at a higher error.The ablation attributes the poorer final optimum to capacity spent fitting amplitude scale rather than morphological structure.Source: B. Signal Compression Ablation · p. 13, Figure S1 · p. 13
C. Memory Scaling Comparison
- MECGE creates one frequency-domain sequence per time frame, scaling effective batch size as O(B ·T/h), while UNet-Mamba uses batch size B and sequence length T/20.Mamba is applied only along time after 20× down-sampling; the figure compares peak GPU memory for inference and training.Source: C. Memory Scaling Comparison · p. 13, Figure S2 · p. 14
D. Training Details for Baseline Models
- Baseline and proposed models use MSE loss with batch size 32, while UNet-Mamba uses Adam with cosine annealing and 400 decay cycles.Baseline optimizer and scheduler choices follow their original publications; full hyperparameters are listed in Supplementary Material E.Source: E. Training Hyperparameters · p. 13, D. Training Details for Baseline Models · p. 13, Table S2 · p. 14
F. Training Convergence
This appendix describes dataset and noise-generation details, classifier architectures, and training convergence. The reported models reach stable test-SNR plateaus before their maximum training epochs.
F. Training Convergence
- All models converge before the maximum epoch count, with test SNR reaching a stable plateau across the three datasets.Figure S3 presents training loss and test SNR across European ST-T, synthetic, and PTB-XL data.Source: F. Training Convergence · p. 14, Figure S3 · p. 14
G. PTB-XL
- PTB-XL signals were collected from 1989 to 1996, and the cohort spans ages 0–95 years with a median age of 62.Recommended folds are patient-stratified; folds 9 and 10 include at least one human evaluation.Source: G. PTB-XL · p. 14
H. Synthetic ECG Parameters
- Synthetic PQRST event amplitudes and widths are sampled uniformly around their respective central values using prescribed ranges.The morphology parameters follow the notation of.Source: H. Synthetic ECG Parameters · p. 14, Table S3 · p. 14
I. Noise Pipeline Validation
- Empirical median SNR and RMSE closely match theoretical predictions, and the ordering across light, medium, and strong noise configurations is preserved.The pipeline validation applies all noise sources to 1,000 preprocessed PTB-XL segments.Source: §I · pp. 14–15, Table S4 · p. 15
J. Downstream Classifier Architectures
- The downstream classifiers are Inception1D and ResNet1D-Wang, trained on clean PTB-XL data with independent binary predictions for each diagnostic class.Both accept 12-channel inputs and use binary cross-entropy loss.Source: J. Downstream Classifier Architectures · p. 15
K. Recording-Length Experiment: Training Details
Pairwise reconstruction-SNR differences favor the proposed models across all three datasets. The appendix also reports training details, data-volume effects, and supplementary RMSE and SNR comparisons.
K. Recording-Length Experiment: Training Details
- Tables S5 and S6 report training epochs and wall-clock time by curriculum stage and split length for the synthetic and European ST-T datasets.Figures S5 and S6 show the corresponding training-loss curves.Source: K. Recording-Length Experiment:… · p. 15, Table S5 · p. 15, Table S6 · p. 15
L. Effect of Training Data Volume
- Mamba-based models improve reconstruction SNR and RMSE monotonically through eight PTB-XL training folds, while UNet and IMUNet peak at six folds and slightly degrade afterward.The passage suggests the Mamba bottleneck continues benefiting from additional training data where convolutional models saturate earlier.Source: L. Effect of Training Data Volume · p. 15
M. Reconstruction RMSE
- Figure S8 reports reconstruction RMSE across all three datasets as a supplement to the SNR results in Figure 3.The passage gives no RMSE values or model ranking.Source: M. Reconstruction RMSE · p. 15
N. Pairwise Tests for Reconstruction SNR
- DR-net Mamba1-3B outperforms every baseline: +0.92 dB SNR over DR-net-IMUNet on synthetic data and +0.83 dB on PTB-XL; pairwise differences are significant across all three datasets.The reported 95% confidence intervals are [+0.79, +1.06] for synthetic data and [+0.78, +0.88] for PTB-XL.Source: Table S7 · p. 15, Table S8 · p. 15, N. Pairwise Tests for Reconstruction SNR · p. 15
O. Impact of Compression Layer in Reconstruction Accuracy
The supplementary results report downstream classification under lower and strong noise, including macro and superdiagnostic measures. Under lower noise, relative model rankings are consistent with the strong-noise setting.
P. Downstream Classification under Lower Noise
- Lower-noise PTB-XL model rankings are consistent with strong-noise results; accompanying Inception1D analyses report superdiagnostic AUROC and macro sensitivity, specificity, and F1.Source: P. Downstream Classification under… · p. 16, Table S12 · p. 18, Table S13 · p. 18
Q. Downstream Macro Results for ResNet1D-Wang
- Table S14 reports macro-averaged sensitivity, specificity, and F1 for ResNet1D-Wang under strong noise.Source: Q. Downstream Macro Results for… · p. 17, Table S14 · p. 18
R. Downstream Macro Results for Inception1D
- Figure S10 summarizes PTB-XL downstream classification with Inception1D under strong noise: BW 0 dB, MA 5 dB, EM 10 dB, and AWGN 20 dB.Source: R. Downstream Macro Results for… · p. 17
S. Superdiagnostic Sensitivity, Specificity, and F1
- The lower-noise Inception1D tables include macro-averaged sensitivity, specificity, and F1, alongside per-superdiagnostic-class AUROC.Source: P. Downstream Classification under… · p. 16, Table S13 · p. 18, Table S12 · p. 18
T. Per-Class Downstream Classification (ResNet1D-Wang)
The supplementary material breaks down ResNet1D-Wang per-diagnostic-class AUROC and identifies the plotted comparisons. It also provides diagnostic abbreviations and a comparison of STTC and CD morphologies with the Mamba bottleneck.
U. Diagnostic Abbreviations
- Table S17 lists the diagnostic-class abbreviations used in Figures 7 and S11.Source: U. Diagnostic Abbreviations · p. 18
V. STTC and CD diagnostic morphologies and The Mamba Bottleneck
- Table S18 compares STTC and CD diagnostic morphologies and their interaction with the Mamba bottleneck.Source: §V · p. 18, Table S18 · p. 21
- Figure S9 gives lower-noise PTB-XL macro and superdiagnostic AUROC for Inception1D and ResNet1D-Wang; Figure S10 compares Inception1D denoised signals with clean and noisy baselines under strong noise.Source: Figure S9 · p. 19, Figure S10 · p. 20
T. Per-Class Downstream Classification (ResNet1D-Wang)
- Figure S11 plots ResNet1D-Wang per-class AUROC: panel A shows the change from adding a Mamba bottleneck, and panel B shows lead-specific UNet-Mamba AUROC; classes with fewer than five segments are omitted.Source: T. Per-Class Downstream Classification… · p. 18, Figure S11 · p. 21