Self-supervised 12-lead ECG encoder that predicts masked patches in latent space, using a cross-lead attention mask shaped by clinical reading.
No providers recorded yet. Browse all providers
A cardiologist reading a 12-lead ECG never looks at one trace in isolation: a tall R wave in V1 signals posterior infarction only when the anterior leads show the reciprocal change. Ordinary self-attention encodes none of that — every patch of signal attends to every other, so the network must rediscover which comparisons carry diagnostic weight. ECG-JEPA builds the reading habit in as an inductive bias. Its Cross-Pattern Attention (CroPA) lets a patch attend to another only when the two share a lead or occupy the same moment in time, narrowing the attention graph to the comparisons clinicians actually make.
The training objective supplies the other half of the design. Instead of reconstructing raw waveform samples, ECG-JEPA follows the joint-embedding predictive architecture: a student encoder sees only the unmasked patches, a teacher encoder — an exponential moving average of the student — encodes the full record, and a predictor maps the student's context to the teacher's latent representation of the masked patches under an L1 loss. Reconstruction in signal space would force the network to model baseline drift and powerline hum, which an ECG has in abundance and a diagnosis does not depend on.
Sehun Kim developed the model at Samsung Medical Center in Seoul, posting it in October 2024. It should not be confused with the identically named ECG-JEPA of Weimann and Conrad, an unrelated contemporaneous preprint with a different corpus and codebase.
Ten-second recordings are resampled to 250 Hz and cut into 50 non-overlapping patches per lead. Student and teacher are transformer encoders of 12 layers, 16 heads and hidden dimension 768 — roughly 85 million parameters — while the predictor is a smaller 6-layer, 12-head, 384-dimensional transformer used only during pretraining. Two masking schedules give two released variants: random masking at a 0.6–0.7 ratio (ECG-JEPArb) and multi-block masking at 0.175–0.225 repeated four times (ECG-JEPAmb). The corpus is 43,240 records from Chapman and Ningbo plus 130,900 from CODE-15, about 174,000 recordings in total. Under linear evaluation on frozen features, ECG-JEPAmb reaches 0.912 multi-label AUC on PTB-XL, 0.966 on CPSC2018 and 0.895 on G12EC, ahead of ST-MEM, SimCLR, ECG-FM and KED under the same protocol. With 1% of PTB-XL labels the random-masking variant holds 0.839 AUC; with a single lead it reaches 0.845 and with two leads 0.878. Folding 780,000 MIMIC-IV-ECG recordings into pretraining left fine-tuning unchanged and slightly reduced linear evaluation, which the author attributes to that cohort's acute-care bias.
The intended use is a frozen encoder that a group with limited labeled data puts a small head on: multi-label diagnostic classification, rhythm and morphology screening, or extracting interval measurements from unannotated recordings. Because accuracy survives the drop to one or two leads, the same representation suits patch and wearable monitors, not only cabinet ECG carts. The segmentation and feature-regression results show the embedding retains beat-level waveform structure, so it can feed measurement pipelines a purely diagnostic encoder could not.
ECG-JEPA is evidence that latent masked prediction, paired with a domain-specific attention mask, is a competitive recipe for physiological signals at a corpus size well below the largest ECG models. CroPA generalizes beyond this architecture: any multi-channel biosignal with a fixed spatial layout — EEG montages, multi-site EMG — has the same structure that unconstrained attention discards. Caveats remain. The work is a single-author preprint that has not completed peer review, and the segmentation ground truth is pseudo-labels from a separate published segmenter rather than clinician annotation. Code and pretrained encoder checkpoints are released under an MIT-licensed repository, so the results are reproducible without repeating pretraining.
Much of this page is generated or calculated automatically. Flag anything that looks off and we will re-run it.