acceptodds
Under review as a conference paper at ICLR 2027

Every Beat Counts: Beat-Anchored Probing of Frozen ECG Encoders for Cross-Site Diagnosis

Abstract

Electrocardiogram (ECG) diagnosis models that match cardiologists within one hospital degrade markedly at another, which hinders their clinical adoption. While existing efforts scale up encoder pretraining, we revisit this challenge from the readout side by asking where frozen encoders keep the information that cross-site diagnosis requires. Through phase-resolved probing of frozen tokens around each heartbeat, we find that such information is present and locked to the beat, yet mean pooling dilutes it for diagnoses confined to part of the beat. A multi-query attentive probe recovers part of it, but under diagnostic supervision alone its queries remain unassigned, covering only part of the beats and keeping to no phase of their own. Motivated by this, we propose the Beat-Anchored Probe (BAP), which expands one R-peak per beat into attention targets for the P, QRS, ST and T phases. Its training-only alignment loss allocates each query over every beat and registers it to one phase, leaving what the query reads to the diagnostic loss. With the encoder frozen, BAP achieves the highest mean transfer among the compared probes and improves on the linear probe on all four encoders, with the largest gains on the diagnoses that mean pooling dilutes, and its phase roles stay fixed across training seeds and decodable on an external benchmark. We further release CPSC2018-R, cardiologist-annotated R-peaks for CPSC2018, which provides the manual reference for phase-resolved probing and for verifying such probes. Code and data are at https://anonymous.4open.science/r/BAP-1490/.

Primary area:
learning on time series and dynamical systems
Keywords:
electrocardiogram, ECG foundaton models, attentive probing, cross-site generalization, CPSC-2018R

Reviews

Among:
Shape:
1234this paper, Top 15%
Figure 1. Mean review rating of the reviewed papers at ICLR 2027. This paper averages 3.00 over 3 reviews, above 85% of the others.
Reviewer_Xa7rOpenReview ↗
Rating
3(+1)
Confidence
3
Informativeness
2
Presentation
1
Soundness
3
Read review
Paper summary

The core idea builds on multi-query probing to better read out a frozen encoder and alleviate cross-site failures of pretrained ECG encoders. To better address cross-site transfer at the readout stage, the authors build on multi-query probing and propose an attention-alignment loss that forces each query to attend to a specific window: the P, QRS, ST, or T wave, respectively. The alignment also ensures that each query assigns non-zero attention to every beat in a record through the decomposed placement and allocation terms. The alignment loss is added to the cross-entropy loss while the encoder remains frozen and the classification head and queries are trained for the target task. This assignment is shown to be more effective than unassigned multi-query probing across five cohorts. R-peaks are manually annotated in CPSC2018, which will be released with the manuscript. The expert annotations improve upon the off-the-shelf detector by approximately 5.5 F1 points.

Critical strengths

The work is well grounded in the ECG field. The attention alignment is carefully designed based on a substantial understanding of ECG characteristics. The core idea is intuitive, and it introduces only an additional loss at the readout stage, requiring no R-peak detection at inference.

The experiments and visualizations are well designed. Table 3 shows strong improvements over average-pooling baselines and unassigned probing when training on PTB-XL. The authors conduct a solid ablation of the two components of the alignment loss, registration and allocation. The attention maps show better beat coverage and more concentrated attention from each query on its designated waveform.

Critical weaknesses

Although the core idea is intuitive, the paper is difficult to follow without a substantial ECG background. The contribution appears to be limited to local ECG diagnosis tasks using source-only cross-site transfer with a frozen encoder.

The gains over UP are small on two of the four encoders (only 0.1 mean AUROC) and modest on the other two (1.1 and 1.2), relative to the reported variation. The benefit over unassigned probing is therefore not consistently compelling, especially given that the proposed method fixes the number of queries at four.

BAP uses fixed, R-peak-based phase windows during training, which may impose a rigid prior: waveform timing varies across patients and conditions, while unassigned intervals and R-peak errors can introduce noisy supervision.

In Table 2, most baselines use average pooling, and no strong contextual attentive readout is included. ABMIL assigns each token an independent score and is therefore relatively weak. The authors should consider stronger baselines, such as TransMIL.

Questions for authors
  1. When referring to average pooling, do you mean averaging the tokens, or using the [CLS] token? [CLS] may provide a stronger summary than mean pooling. Please clarify this choice and, if applicable, compare against it.
  2. Could you provide ablations with (K<4) and (K>4)? Does the improvement persist as the number of queries varies? This would clarify the upper bound of UP.
  3. Table 2 did not consider a stronger attentive readout baseline, e.g., TransMIL? ABMIL assigns each token an independent score and does not explicitly model token–to–token interactions in the readout.
  4. What are the training costs and additional assumptions of BAP—R-peak detection, fixed phase-window construction, and the alignment loss—relative to standard domain-adaptation methods? Most domain-adaptation methods use target-site data to update the encoder. Under a frozen-encoder setting, data augmentation and a contextual attentive readout are simple alternatives. What are the trade-offs between these strategies and transfer performance?
6 comments
AuthorsOpenReview ↗

Thank you for your constructive comments, and the revised version has been uploaded.

Thank you again for your constructive comments. We have uploaded the revised paper, with all changes marked in blue.

To make the paper easier to follow without an ECG background, the introduction now includes a short ECG primer, and Sec. 2 defines local diagnoses and the scope of BAP. TransMIL and a two-layer Transformer have been added to Tab. 14 (App. E.6) as contextual readouts, and BAP trained with noisy R-peaks is now reported in Tab. 9 (App. E.1).

As the discussion period is ending soon, we would greatly appreciate it if you could kindly take a look at our responses and let us know whether they address your concerns. We are happy to provide any further clarification.

Reviewer_Xa7rOpenReview ↗

Thank you for the response

The authors have responded well to the questions I have raised. The comparison with TransMIL is useful evidence for the method. The ablations in general are rigorous. My view of the paper is more positive now after the rebuttal.

Thank you very much for your kind feedback, and we are glad that you found the comparison with TransMIL useful and the ablations rigorous. With the discussion closing very soon, we would be sincerely thankful if you could find a moment to look at our latest results, which extend this comparison to clinical outcomes.

Beyond local diagnoses. Regarding your comment that the contribution appeared limited to local diagnoses, we evaluated BAP on all-cause mortality, trained on CODE-15% and tested on its held-out patients and on the external SaMi-Trop and MIMIC-IV cohorts, and on the 12 structural heart disease labels of EchoNext, including new patients of 2021 and 2022. BAP achieves the highest mean AUROC and AUPRC of the five readouts, TransMIL included, on all five test sets. On MIMIC-IV, an external cohort from another country and health system, it exceeds TransMIL by 1.7 AUROC points [1.3, 2.1] and UP by 0.5 [0.1, 0.8]. On the new EchoNext patients, it exceeds UP by 0.8 macro-AUROC points [0.2, 1.5]. Reviewer f1sW, who suggested these tasks, commented that this "application to truly consequential outcomes significantly improves the paper".

Detector-based supervision. The alignment targets of BAP in these experiments use NeuroKit2 R-peaks alone, the detector-based supervision discussed in your third comment.

These results are now in Table 5 and App. F of the revised paper, and the introduction includes the ECG primer promised in our first response.

If our responses resolve your concerns, we would be deeply grateful if you could kindly consider raising your score. Your assessment means a great deal to us, and we are ready to answer any remaining question right away. Thank you again sincerely for your time and effort.

Best regards,

The Authors

Reviewer_D3nHOpenReview ↗
Rating
3
Confidence
3
Informativeness
2
Presentation
3
Soundness
2
Read review
Paper summary

This paper proposes the Beat-Anchored Probe (BAP), a method for extracting information from pretrained ECG encoders without updating their parameters. During training, four learnable queries focus on fixed P-wave, QRS-complex, ST-segment, and T-wave windows around the R-peaks. R-peak locations are not required during inference. The method is evaluated using four ECG encoders and five external patient cohorts.

Critical strengths

S1: The method is well motivated, and empirical experiments show the importance of preserving localized ECG information.

S2: The evaluation is comprehensive, covering multiple baselines and datasets. It also assesses robustness across different random seeds.

S3: The probe is lightweight and does not require R-peak detection at inference, which makes it easier to use with existing frozen encoders.

Critical weaknesses

W1: The use of fixed phase windows assumes relatively stable waveform timing and structure, which may not hold for abnormal ECGs. For example, some rhythms lack consistent P waves, while conduction abnormalities can substantially shift or prolong waveform components. The LUDB analysis alone does not establish the method’s robustness in such cases.

W2: The physiological interpretation relies mainly on attention alignment. High attention within a phase does not necessarily show that the corresponding waveform segment caused the prediction.

W3: The evaluation is limited to shared diagnostic labels and discrimination metrics. It therefore remains unclear whether the predicted probabilities are well calibrated and whether performance is maintained at clinically relevant thresholds when disease prevalence or acquisition settings change.

Questions for authors

Q1: How sensitive is BAP to the phase-window design and alignment-loss weight?

Q2: Does phase-specific registration improve performance beyond a general beat-coverage constraint?

2 comments
AuthorsOpenReview ↗

Thank you for your positive and constructive comments, and the revised version has been uploaded.

Thank you again for your positive and constructive comments!

We have uploaded the revised paper, with all changes marked in blue. The fixed phase windows on abnormal ECGs are now examined in App. E.2, and query removal in App. E.3 tests whether each attended phase drives the prediction. Calibration and source-chosen thresholds have been added to App. E.4, and the comparison with a beat-coverage constraint to App. E.5 and Sec. 4.3.

All revisions are consistent with our responses above. We sincerely thank you for your time and support.

Thank you again for your positive and constructive comments and for your support of our work. We have uploaded a further revised paper, with all changes marked in blue. Sec. 4.2 now also reports all-cause mortality and structural heart disease in a new Table 5, with the details in App. F, and BAP achieves the highest mean AUROC and AUPRC of the five readouts on all five test sets. Reviewer f1sW, who suggested these tasks, commented that this "application to truly consequential outcomes significantly improves the paper". As Table 5 is new, the numbers of the later tables increase by one, and our general comment summarizes all revisions to the main text. The analyses added for your comments remain in Sec. 4.3 and App. E.

We sincerely appreciate your careful review and your time.

Best Regards,

The Authors

Reviewer_f1sWOpenReview ↗
Rating
3(+2)
Confidence
4
Informativeness
1
Presentation
1
Soundness
1
Read review
Paper summary

This work introduces what the authors call a “beat-anchored supervision” approach to ECG encoding, intended to improve cross-site performance across ECG tasks. However, the manuscript is difficult to evaluate in the context of the current state of the art. More fundamentally, the authors’ thesis depends on the assumption that ECGs can be reliably segmented into individual beats. Although this may hold for normal signals, it often does not hold for abnormal recordings—the very cases in which robust cross-site algorithms are most needed. In this regard, the manuscript assumes that an ECG can be readily divided into components such as the P wave, QRS segment, ST segment, and T wave using existing methods. That assumption is problematic in many real-world settings, where segmentation itself is challenging. Consequently, the anchor-expansion method used to identify beat components (Figure 2b) is likely to fail on datasets containing ECGs from patients with cardiac disease.

More precisely, in the present study, the authors trained their models on a relatively small dataset of approximately 6,877 ECG recordings for which R-peaks were manually annotated by experts. It is unclear how this approach would scale to datasets containing millions of ECG records; i.e., the typical dataset size for many real-world applications. The authors suggest that an automated tool such as NeuroKit2 could provide labels at scale, noting that, “In a 200-record audit… [the] NeuroKit2 detector (Makowski et al., 2021) used for the other corpora reaches a one-to-one F1 of 94.5 within 50 ms.” However, reporting only the F1 score obscures the underlying precision–recall tradeoff and depends on a prespecified matching tolerance. The manuscript should therefore report the corresponding precision and recall values—particularly the recall achieved by NeuroKit2 on these corpora—and justify the 50-ms tolerance.

In addition, the authors’ results suggest that the largest improvements occur for what they term “local diagnoses,” including first-degree atrioventricular block (1AVB), premature atrial contractions (PACs), and premature ventricular contractions (PVCs). Yet standard ECG models—including models based on several of the encodings evaluated here—already tend to perform well on these diagnoses. These benchmarks therefore do not establish that the proposed method addresses the clinically consequential tasks for which improved ECG representation learning is most needed. The manuscript would be substantially stronger if the authors evaluated the method on more challenging and clinically meaningful tasks, as emphasized in recent work (https://icml.cc/virtual/2026/poster/67157).

Critical strengths

The beat anchored probing approach is a novel concept.

Critical weaknesses

The physiologically-guided anchor expansion method will fail in many real-world datasets containing signals from patients with cardiovascular disease.

The manuscript lacks a thoughtful discussion of the challenges involved in beat segmentation.

The performance is evaluated on simple tasks, which are associated with high AUROCs. Comparing the performance of their method only against a LP, does not provide a true assessment of how this approach will work in real-world applications, where more complex non-linear methods are used.

Questions for authors

Can the authors must discuss how this could be implemented in settings where ECG parsing/segmentation fails using standard segmentation methods?

Does BAP yield tangible improves when encoders are used as input to more sophisticated, non-linear, models?

Why is PVC a local diagnosis and complete LBBB not a local diagnosis, especially since a PVC can have a morphology similar to a complete LBBB?

The range of tasks that go in the macro-AUC is very limited and insufficient to provide insight into the benefit of BAP in real-world applications. We do not need new methods to better identify PVCs, for example, as there are ample high performing (non-linear) methods for this task.

1 comment
AuthorsOpenReview ↗

Thank you for your constructive comments. Below please find our responses to the specific comments (3/3)

Comment_7 (Weakness 3 and Q4, on the tasks):

(Weakness 3) The performance is evaluated on simple tasks, which are associated with high AUROCs.

(Q4) The range of tasks that go in the macro-AUC is very limited and insufficient to provide insight into the benefit of BAP in real-world applications. We do not need new methods to better identify PVCs, for example, as there are ample high performing (non-linear) methods for this task.

Response_7: Thank you for this important comment. Our work starts from a cross-site gap: read through mean pooling, a frozen ECG encoder detects a local diagnosis well at one hospital and loses much of this accuracy at another. We answer the comment in three parts.

(1) Easy within a dataset, hard across sites. Within a single dataset, current models achieve high AUROC on these diagnoses. Berger et al. [5] (ICML 2026, which the revised version cites), who train and test within PTB-XL, CPSC2018 and CSN, find that many differences between methods fall within statistical noise and that a randomly initialized encoder matches pretrained ones on many tasks. Across hospitals, performance on the same diagnoses degrades substantially. In the PhysioNet/CinC 2021 Challenge, performance differed more across test databases than across lead combinations [6]. In our setting, the linear probe retains only 78 to 89% of its in-domain AUROC on 1AVB, PAC and PVC (Sec. 2, Fig. 1(a)), and its cross-site AUROC on PAC is 56.6, close to chance. At the paper's weight, these three diagnoses are also where BAP gains the most over LP (Fig. 3(a)).

Per-class AUROC, averaged over the cohorts that label each class (seeds 0 to 7).

Readout1AVBPACPVCNORMAFIBCLBBBCRBBB
LP82.256.675.794.493.092.895.9
BAP (λa=0.05\lambda_a = 0.05)86.762.279.995.395.195.697.6

(2) Why the readout loses them. Sec. 2 traces this loss to the readout. The clinical ECG program GE Marquette 12SL aligns the beats of the same QRS shape in time, takes the median voltage at each sample to form a median complex, and derives its interval measurements, such as PR, QRS and QT, from these median complexes [7, 8]. The median complex thus combines the beats sample by sample after QRS alignment. Mean pooling averages the tokens without such alignment and therefore mixes the phases of all beats, and BAP targets precisely this weakness of frozen-encoder readouts. PVC is further affected by its co-occurrence with other diagnoses, which differs across sites: 11% of the PVC training records at the source carry another of the seven diagnoses, compared with 15 to 71% in the four target cohorts that label PVC. On PTB-XL, the linear probe's PVC AUROC is 88.7 for PVC records without another of the seven diagnoses and 69.8 for those with one, and on SPH 88.0 versus 66.8 (seeds 0 to 2). PVC is therefore harder to transfer than its within-dataset AUROC suggests.

(3) Scope of tasks. Our study addresses cross-site transfer, which requires the same labels at several sites. The seven diagnoses are those shared by the source and the two development cohorts, and each cohort is scored on the diagnoses it annotates (App. A.1), so every readout is compared on identical data, labels and sites. The structural, hemodynamic and outcome labels used by Berger et al. each come from a single hospital, two of them private, and therefore cannot test transfer across sites. Furthermore, BAP is plug-and-play. It adds a single training loss to an attentive probe and leaves both the encoder and inference unchanged. Since its R-peaks can be obtained with a detector on any ECG corpus, it can be added to any encoder whose time-indexed tokens resolve the phase windows (App. B.1) and trained for any label set. BAP improves on LP and UP on all four encoders of Tab. 1, which span three transformers and a CNN with different pretraining objectives and token rates, and on both source corpora (Tab. 1 and Tab. 3). On unseen LUDB records, its queries further label the tokens inside the expert P, QRS, ST and T segments by phase (Table R2).

The cross-site motivation, the comparison with median complexes, the PVC co-labels and the choice of labels will be added to Sec. 2 of the revised version, and the per-class and PVC subgroup results to App. E, with all changes marked in blue.

We hope these responses address the reviewer's concerns, and we would be glad to discuss any remaining points.

[5] Position: Evaluation of ECG representations must be fixed.

[6] Issues in the automated classification of multilead ECGs using heterogeneous labels and populations.

[7] GE Healthcare. Marquette 12SL ECG Analysis Program: Statement of Validation and Accuracy (416791-003).

[8] GE HealthCare. Marquette 12SL ECG analysis program, product page.

From OpenReview, CC BY 4.0. Authors as signed there; shown unedited.

Related papers

Loading the map…

Discussion (0)

Sign in to comment.