Source-linked AI summary
BeatFlow-ECG: Rectified Flow for ECG Reconstruction from Indirect Wearable Signals
Mohamed Kamel, Sahar Selim, Walaa Medhat, Tamer Nadeem
TL;DR
Wearable PPG is practical for continuous monitoring but indirect and motion-sensitive, and subject-independent reconstruction from multimodal wearable signals under substantial motion remains under-addressed. BeatFlow-ECG uses conditional rectified flow with synchronized PPG and IMU inputs, and achieves the strongest overall waveform and beat-timing results among the evaluated baselines on PPG-DaLiA and WESAD. Its results do not establish generalization to diverse devices, populations, sensor placements, clinical conditions, or pathological ECG patterns.
Problem
Most existing work does not address subject-independent ECG reconstruction from multimodal wearable signals under substantial motion, despite PPG's indirect measurement and sensitivity to motion.
Source: §1 · p. 1Method
BeatFlow-ECG reconstructs single-channel ECG from synchronized PPG and IMU signals as conditional rectified-flow transport from noise to ECG, incorporating motion features, motion-weighted training, and an easy-to-hard curriculum.
Source: §1 · pp. 1–2Results
BeatFlow-ECG achieves the best overall waveform and beat-timing results among evaluated baselines under LOSO on PPG-DaLiA and WESAD.
Source: §1 · p. 2, §6 · p. 9, §8 · p. 10Takeaways & Limitations
On PPG-DaLiA, BeatFlow-ECG also shows higher regional waveform correlations and lower reconstruction error across motion levels than the evaluated comparisons.
Source: §6 · p. 9, §8 · p. 10Evaluation is limited to PPG-DaLiA and WESAD and does not establish generalization to other devices, populations, sensor placements, clinical conditions, or pathological ECG patterns; diagnostic validity is not established.
Source: §7 · p. 9, ETHICS STATEMENT · p. 10
Abstract
from arXiv · showhide
Continuous cardiac monitoring outside clinical settings requires signals that are both informative and practical to collect during daily life. Electrocardiography (ECG) provides rich information about cardiac rhythm and waveform morphology, while wearable photoplethysmography (PPG) is easier to acquire continuously but is only an indirect cardiovascular measurement and is highly sensitive to motion. We present BeatFlow-ECG, a conditional rectified-flow model for reconstructing single-channel ECG from synchronized PPG and inertial measurements. BeatFlow-ECG models reconstruction as conditional transport from noise to ECG using a convolutional encoder-decoder with a transformer bottleneck and explicit flow-time conditioning. Motion information is incorporated through IMU-derived conditioning features, motion-dependent loss weighting, and an easy-to-hard training curriculum. We evaluate the model under leave-one-subject-out protocols on PPG-DaLiA and WESAD. BeatFlow-ECG achieves the best results among the evaluated deterministic, adversarial, and diffusion-based baselines across all reported waveform and beat-timing metrics, with Pearson correlations of 0.983 and 0.986 and R-peak F1 scores of 0.946 and 0.955, respectively. Compared with Conditional DDPM-1D, L1 error decreases from 0.085 to 0.062 on PPG-DaLiA and from 0.074 to 0.055 on WESAD. Additional analyses on PPG-DaLiA show higher correlation in fixed R-peak-relative waveform regions and lower reconstruction error across low-, medium-, and high-motion subsets.
1 INTRODUCTION
BeatFlow-ECG reconstructs single-channel ECG from synchronized PPG and IMU signals using conditional rectified flow. It targets subject-independent reconstruction under motion and achieves the best overall waveform and beat-timing results among the evaluated models.
1 INTRODUCTION
- Most prior work does not address subject-independent ECG reconstruction from multimodal wearable signals under substantial motion.PPG is easier to acquire continuously than ECG, but is indirect and sensitive to motion; reconstruction must preserve local morphology and longer-range beat timing.Source: §1 · p. 1
- The paper formulates reconstruction from synchronized wearable PPG and inertial measurements as conditional transport from noise to ECG.The target is a single-channel ECG waveform.Source: §1 · pp. 1–2
- Motion information enters through IMU-derived conditioning features, motion-weighted velocity matching, and a curriculum that gradually introduces higher-motion windows.The paper evaluates these components through ablations.Source: §1 · p. 2
- BeatFlow-ECG achieves the best overall waveform and beat-timing results among evaluated deterministic, capacity-matched, adversarial, and diffusion-based baselines under LOSO on PPG-DaLiA and WESAD.Additional analyses examine regional waveform agreement, motion robustness, and inference efficiency.Source: §1 · p. 2
2 RELATED WORK
Prior work reconstructs ECG from PPG and restores degraded or reduced-dimensional ECG, while diffusion methods also provide a foundation for physiological-signal generation. BeatFlow-ECG combines PPG and IMU conditioning and evaluates under subject-independent LOSO.
2.1 ECG RECONSTRUCTION FROM INDIRECT WEARABLE SIGNALS
- Most indirect ECG reconstruction methods use PPG alone, while reported results vary across datasets and protocols, limiting direct numerical comparison.BeatFlow-ECG instead uses wrist PPG with IMU-derived motion information and evaluates CardioGAN under the same LOSO protocol on both datasets.Source: §2.1 · p. 2
2.2 ECG RESTORATION, MORPHOLOGY RECONSTRUCTION, AND LEAD RECONSTRUCTION
- ECG restoration methods begin with ECG observations and restore missing or corrupted content, whereas BeatFlow-ECG reconstructs ECG from peripheral PPG and IMU measurements.Prior directions include denoising, imputation, lead reconstruction, and beat-morphology reconstruction from indirect ECG observations.Source: §2.2 · p. 2
2.3 GENERATIVE MODELING FOUNDATIONS FOR PHYSIOLOGICAL TIME SERIES
- Diffusion methods have been applied to physiological-signal generation but typically rely on iterative sampling, which can increase inference cost; rectified flow offers a continuous-time alternative.BeatFlow-ECG applies rectified flow to wearable ECG reconstruction with PPG/IMU conditioning and motion-aware training.Source: §2.3 · pp. 2–3
3 METHOD
BeatFlow-ECG treats wearable-to-ECG reconstruction as conditional transport from noise to a single-channel ECG target. Its method combines a time-conditioned convolutional-transformer velocity model, motion-aware training, and synchronized signal preprocessing.
3.1 PROBLEM FORMULATION
- The method maps synchronized wearable conditioning signals to a one-channel ECG target, modeling reconstruction as continuous-time conditional transport rather than one-shot deterministic regression.The learned velocity field transports noise toward the target ECG while conditioned on wearable observations.Source: §3.1 · p. 3
3.2 CONDITIONAL RECTIFIED-FLOW FORMULATION
- Rectified flow trains a conditional velocity field along a path from noise to ECG, then reconstructs the signal by integrating that field over an ODE trajectory.The model uses L1 velocity matching, with an Euler discretization for reconstruction.Source: §3.2 · pp. 3–4
3.3 BEATFLOW-ECG ARCHITECTURE
- The model concatenates the intermediate state and wearable conditioning, then uses a convolutional encoder, transformer bottleneck, and decoder to predict the conditional velocity.Skip connections preserve finer temporal features, the transformer models longer-range dependencies including beat relationships, and learned flow-time embeddings condition activations.Source: §3.3 · pp. 4–5, Figure 1 · p. 4
3.4 MOTION-AWARE CONDITIONING AND TRAINING
- Motion-aware training adds IMU-derived motion descriptors, upweights higher-motion windows in the flow-matching objective, and gradually introduces harder windows through an easy-to-hard curriculum.An auxiliary STFT magnitude loss encourages frequency-domain consistency in reconstructed ECG.Source: §3.4 · pp. 5–6
3.5 SIGNAL PREPROCESSING AND FEATURE CONSTRUCTION
- Preprocessing filters PPG at 0.4–8 Hz and ECG at 0.5–40 Hz, then resamples all modalities to 125 Hz and z-score normalizes each 10-second window.Aligned modalities are extracted as overlapping 10-second windows with a 5-second stride; conditioning includes PPG-cycle phase and IMU motion features.Source: §3.5 · p. 6
4 EXPERIMENTAL SETUP
The evaluation tests subject-independent ECG reconstruction on two wearable datasets using leave-one-subject-out splits. It compares BeatFlow-ECG with several model families using waveform-fidelity and beat-timing metrics.
4.1 DATASETS AND EVALUATION PROTOCOL
- PPG-DaLiA provides wrist PPG and inertial data with chest ECG from 15 subjects during motion-rich daily activities; WESAD supplies synchronized wearable, motion, and ECG signals under a different acquisition protocol.Each dataset is evaluated separately.Source: §4.1 · p. 6
- Each leave-one-subject-out fold tests on a subject excluded from model fitting and checkpoint selection, measuring generalization to an unseen subject.The protocol is run separately for each dataset.Source: §4.1 · pp. 6–7
4.2 BASELINES AND METRICS
- Comparisons include direct-regression, capacity-matched, diffusion, and adversarial baselines; reported metrics cover waveform fidelity and beat timing.Metrics include L1 error, RMSE, Pearson correlation, R-peak F1 with a 100-ms tolerance, and absolute heart-rate error.Source: §4.2 · p. 7
4.3 IMPLEMENTATION DETAILS
- Models use 125-Hz, 1250-sample windows; validation windows may share raw samples with training windows, but the held-out test subject remains isolated.BeatFlow-ECG uses 120 explicit Euler steps at inference.Source: §4.3 · p. 7
5 RESULTS
BeatFlow-ECG leads the reported overall comparisons, and additional analyses examine regional waveform agreement, subject variation, qualitative reconstructions, motion levels, and design-component ablations. The results are evaluated under leave-one-subject-out protocols on PPG-DaLiA and WESAD.
5 RESULTS
- 0.062 vs 0.085 L1 error and 0.983 vs 0.962 Pearson correlation on PPG-DaLiA; on WESAD, L1 error is 0.055 vs 0.074 and R-peak F1 is 0.955 vs 0.918, for BeatFlow-ECG versus Conditional DDPM-1D.BeatFlow-ECG achieves the best results across all reported metrics; Table 1 reports mean values with 95% confidence intervals across held-out subject folds.Source: Table 1 · p. 7, §5 · p. 7
- Across 15 held-out PPG-DaLiA subjects, BeatFlow-ECG has lower L1 and heart-rate error than Conditional DDPM-1D and UNet1D (p < 0.01 for each comparison).The comparisons use paired Wilcoxon signed-rank tests.Source: §5 · p. 7
5.1 MORPHOLOGY-SENSITIVE ANALYSIS
- BeatFlow-ECG has the highest correlation in the P-wave, QRS, and T-wave regions, including the lower-amplitude P- and T-wave regions.These morphology results are limited to the study’s healthy cohorts and do not establish generalization to pathological ECG morphology.Source: Table 2 · p. 8, §5.1 · p. 8
5.2 SUBJECT-WISE ANALYSIS
- S6 and S10 are among the more difficult PPG-DaLiA folds; S6 is retained despite a reported recording-hardware issue that reduced valid recording duration.The dataset authors report the hardware issue for S6.Source: §5.2 · p. 8
5.3 QUALITATIVE RECONSTRUCTION ANALYSIS
- Qualitative examples show BeatFlow-ECG preserving dominant beat structure, timing, and local waveform morphology across windows with varying reconstruction error.Figure 3 panels show wearable PPG, reconstructed ECG, reference ECG, and motion signals.Source: §5.3 · p. 8, Figure 3 · p. 8
5.4 MOTION ROBUSTNESS ANALYSIS
- Reconstruction error increases with motion for all models, while BeatFlow-ECG has the lowest error across low-, medium-, and high-motion groups.Groups use the 33rd and 67th percentiles of the motion-score distribution; the score measures motion exposure, not ECG SNR.Source: §5.4 · pp. 8–9, Table 3 · p. 9
5.5 ABLATION STUDY
- All evaluated ablations degrade performance; removing both motion weighting and STFT loss increases L1 from 0.062 to 0.084 and heart-rate error from 4.89 to 5.85 bpm.Motion conditioning, the curriculum, and the STFT objective each also improve performance.Source: Table 4 · p. 9, §5.5 · p. 9
6 DISCUSSION
BeatFlow-ECG outperforms deterministic baselines and Conditional DDPM-1D, while capacity-matched variants suggest model size alone does not explain the performance gap. On PPG-DaLiA, it also has higher regional correlations and lower error across motion levels.
6 DISCUSSION
- BeatFlow-ECG is slower than single-pass deterministic models but requires substantially fewer function evaluations than the evaluated DDPM configuration.Capacity-matched variants remain weaker, while regional correlations and motion-stratified errors also favor BeatFlow-ECG on PPG-DaLiA.Source: §6 · p. 9
7 LIMITATIONS
The evaluation is limited to PPG-DaLiA and WESAD and does not establish generalization across devices, populations, sensor placements, or clinical conditions.
7 LIMITATIONS
- Evaluation on PPG-DaLiA and WESAD does not establish generalization across devices, populations, sensor placements, or clinical conditions.Both datasets mainly contain healthy subjects, and the model reconstructs single-channel rather than diagnostic 12-lead ECG.Source: §7 · p. 9
8 CONCLUSION
BeatFlow-ECG reconstructs ECG from indirect wearable signals and achieves the strongest overall waveform and beat-timing results among evaluated baselines on two leave-one-subject-out datasets.
- BeatFlow-ECG achieves the best overall waveform and beat-timing results among evaluated baselines under leave-one-subject-out evaluation on PPG-DaLiA and WESAD.Source: §8 · p. 10
- On PPG-DaLiA, BeatFlow-ECG shows higher regional waveform correlations and lower reconstruction error across motion levels.Source: §8 · p. 10
- BeatFlow-ECG is a conditional rectified-flow framework for reconstructing ECG from indirect wearable signals.Source: §8 · p. 10
ETHICS STATEMENT
BeatFlow-ECG reconstructs ECG rather than measuring it directly, so its results do not establish diagnostic validity and clinical use requires prospective validation.
- BeatFlow-ECG reconstructs ECG rather than directly measuring it.Source: ETHICS STATEMENT · p. 10
- Reconstruction errors could lead to false reassurance or false alarms if the system is used clinically.Source: ETHICS STATEMENT · p. 10
- The study does not establish diagnostic validity; prospective clinical validation is required before clinical use.Source: ETHICS STATEMENT · p. 10
REPRODUCIBILITY STATEMENT
The main paper reports the model formulation, preprocessing, evaluation protocol, baselines, and metrics; the appendix supplies additional implementation and analysis details.
- The main paper describes the model formulation, preprocessing pipeline, leave-one-subject-out evaluation protocol, baselines, and evaluation metrics.Source: REPRODUCIBILITY STATEMENT · p. 10
- The appendix provides architecture and training details, preprocessing equations, baseline configurations, confidence intervals, subject-wise results, and efficiency analyses.Source: REPRODUCIBILITY STATEMENT · p. 10
- All experiments use the publicly available PPG-DaLiA and WESAD datasets.Source: REPRODUCIBILITY STATEMENT · p. 10
AI USE STATEMENT
This section documents BeatFlow-ECG’s implementation, training and evaluation procedures, baseline configurations, experiment settings, and supplementary qualitative and robustness analyses. It also reports a retuned UNet1D-Large result on PPG-DaLiA and states that LLMs were used only for manuscript polishing and grammar correction.
A.2 TRAINING OBJECTIVE AND OPTIMIZATION DETAILS
- The model combines motion-weighted L1 velocity matching with an STFT magnitude loss and reconstructs ECG from Gaussian noise using 120 explicit-Euler integration steps.The STFT loss uses λSTFT = 0.10 and nfft = 256; the ablation removes motion weighting and the STFT term.Source: §A.2 · pp. 14–15
A.3 MOTION-AWARE TRAINING DETAILS
- Motion-aware training weights windows by mini-batch-normalized motion scores, uses α = 1.0, and gradually expands training from lower-motion windows to all windows.Higher-motion windows receive larger weights; mini-batch normalization avoids dataset-level calibration.Source: §A.3 · p. 15
B.1 DATASET PREPROCESSING DETAILS
- Preprocessing filters PPG at 0.4–8 Hz and ECG at 0.5–40 Hz, resamples modalities to 125 Hz, and extracts overlapping 10-second windows with 5-second stride.Conditioning also includes a PPG-derived phase feature and acceleration magnitude as a motion descriptor.Source: §B.1 · pp. 16–17
B.2 EVALUATION METRICS
- Evaluation reports waveform errors, Pearson correlation, R-peak F1 with a 100 ms matching tolerance, and heart-rate error; the AI-use statement limits LLM use to editing.The authors state that all scientific content was developed and verified by them.Source: AI USE STATEMENT · p. 10, §B.2 · pp. 17–18
C.1–C.3 ADDITIONAL RECONSTRUCTION, PEAK-ALIGNMENT, AND TRAJECTORY EXAMPLES
- Additional examples show preserved dominant beat structure and local waveform shape, close predicted-to-reference R-peak alignment, and gradual ECG-structure emergence along the reconstruction trajectory.The trajectory visualizations illustrate iterative reconstruction from initial Gaussian noise to the final ECG.Source: §C.1 · p. 18, §C.2 · p. 19, Figure 6 · p. 19
D.1 INFERENCE EFFICIENCY
- 120 function evaluations and 425 ms inference time give BeatFlow-ECG an approximately 8.3× speedup over Conditional DDPM-1D on the evaluated H100 setup.The comparison concerns reconstructing a 10-second window and excludes signal acquisition, preprocessing, and data transfer.Source: Table 5 · p. 21, §D.1 · p. 21
D.2 MOTION ROBUSTNESS VISUALIZATIONS
- Reconstruction error generally rises with acceleration-derived motion, although windows at similar motion levels vary; most windows fall in lower-RMSE and higher-correlation regions.The continuous analysis complements the motion-stratified results in Table 3.Source: §D.2 · p. 21, Figure 10 · p. 21
D.3 PER-SUBJECT TABLES
- On PPG-DaLiA, BeatFlow-ECG has lower reconstruction error than Conditional DDPM-1D and UNet1D-Large on difficult folds S6 and S10, amid variability across subjects and metrics.The subject-wise tables cover 15 held-out subjects on PPG-DaLiA and WESAD.Source: §D.3 · p. 22, Table 6 · p. 22, Table 7 · p. 22
- Table 11 reports WESAD LOSO performance for UNet1D-Large across 15 subjects.Source: Table 11 · p. 24
D.4 BASELINE QUALITATIVE COMPARISONS
- Baseline examples show close ECG reconstructions in some windows but local morphology, amplitude, or temporal-alignment errors in others.These qualitative examples complement aggregate and subject-wise results.Source: §D.4 · p. 24, Figure 11 · p. 24
D.5 MORPHOLOGY-SENSITIVE REGION ANALYSIS
- Morphology-sensitive evaluation computes Pearson correlation separately in fixed R-peak-centered P-wave, QRS, and T-wave regions shared across models.The regions are −200 to −60 ms, −60 to +60 ms, and +60 to +400 ms, respectively, within a 600-ms interval around each reference R-peak.Source: §D.5 · p. 24
E.1 BASELINE MODEL DETAILS
- Baseline parameter counts were UNet1D 4.2M, UNet1D-Large 13.2M, AttnSeq 8.5M, AttnSeq-Large 12.3M, and Conditional DDPM-1D 12.6M.UNet and AttnSeq each include standard and capacity-matched variants; Conditional DDPM-1D shares BeatFlow-ECG’s hybrid backbone and conditioning inputs and uses 1000-step training and reverse-diffusion schedules.Source: §E.1 · p. 25
- CardioGAN was evaluated as a PPG-only baseline under the study’s dataset-specific LOSO protocol, not as a reproduction of its original experimental setting.Released weights were excluded because their pooled training data included PPG-DaLiA and WESAD, potentially exposing held-out subjects.Source: §E.1 · p. 25
E.2 LEARNING-RATE SELECTION FOR UNET1D-LARGE
- UNet1D-Large’s PPG-DaLiA learning rate was selected using non-test-subject validation L1 on development folds, then fixed at 3 × 10−4 for all 15 LOSO folds.The sweep trained for 80 epochs at 3 × 10−4, 1 × 10−4, and 3 × 10−5; held-out subjects in development folds were excluded from selection.Source: §E.2 · p. 26, Table 12 · p. 26
- UNet1D-Large achieved L1 0.138, RMSE 0.210, Pearson r 0.925, R-peak F1 0.875, and HR error 6.95 bpm on PPG-DaLiA; it did not improve over UNet1D.The model was retuned at 3 × 10−4 and evaluated across all 15 LOSO folds; it is retained as a capacity-matched control.Source: §E.2 · p. 26
E.3 BEATFLOW-ECG HYPERPARAMETERS
- Table 13 summarizes BeatFlow-ECG’s main hyperparameters and the shared experimental windowing settings.Baseline training settings are provided in Appendix E.1.Source: §E.3 · p. 26, Table 13 · p. 26
E.4 ABLATION DETAILS
Ablations show degraded performance when motion-aware components or the STFT term are removed. The experimental workflow evaluates each fold on a held-out subject.
E.4 ABLATION DETAILS
- Without motion conditioning, L1 error increased from 0.062 to 0.078 and R-peak F1 decreased from 0.946 to 0.920.The variant removes explicit IMU-derived motion descriptors while leaving the other architecture and training choices unchanged.Source: §E.4 · p. 27
- Without the easy-to-hard curriculum, L1 error increased to 0.071 and HR error to 5.35 bpm.This variant used all training windows throughout training.Source: §E.4 · p. 27
- Removing the STFT loss increased L1 error from 0.062 to 0.069 and decreased R-peak F1 from 0.946 to 0.926.The motion-weighted flow-matching objective was retained.Source: §E.4 · p. 27
- Removing motion weighting and STFT loss produced the largest degradation: L1 error rose to 0.084 and HR error to 5.85 bpm.Both components were removed in this variant.Source: §E.4 · p. 27
E.5 EXPERIMENTAL WORKFLOW
- Each fold trains and selects a checkpoint using 14 subjects, then evaluates it on the held-out subject.The workflow preprocesses paired wearable/ECG windows, creates subject-level manifests and splits, and saves aggregate metrics and per-window predictions.Source: §E.5 · p. 27