Skip to content

Paired prototype-similarity consistency extension for ProtoECGNet morphology #1618

Backlog

Description

@simpsonTsai

I am Chia Yang Tsai (UIUC NetID ct68). I am proposing an extension to the existing ProtoECGNet morphology branch for paired clean/noisy prototype-similarity consistency training.

The proposed ProtoECGNetH1 subclass reuses the existing backbone, training stages, standard prototype projection, and PyHealth Trainer. The training loss averages the full original objectives from the clean and noisy views, then adds a consistency penalty on their pooled prototype similarities, with gradients flowing through both views. Setting lambda_cons=0 retains the same paired training procedure without that penalty, providing a matched control.

The contribution also includes focused helpers for fixed label order, all-zero targets, deterministic paired noise, and provenance tied to projected prototypes. It requires a small branch-factory change in the existing model; the current ProtoECGNet defaults are preserved.

The implementation is prepared on a branch based on master at 454b3943. A Colab CPU snapshot hash-matched to the exported code for commit 078982d4 passed a selected 251-test suite and a two-arm synthetic Trainer example. The real-ECG research results came from a separate custom pipeline, not from retraining with PyHealth Trainer. No real ECGs or trained weights are included; numerical compatibility limits will be documented in the PR.

Would this subclass and the small default-preserving change to the existing model be an appropriate scope for a PyHealth model contribution? I plan to link this issue in a PR targeting master for detailed review.

Activity

  1. solarsys commented on Nov 26, 2026

    @solarsys
    Collaborator

    Thanks for the write-up. The implementation is now open as #1620. Because it changes the existing protoecgnet.py and is about 4.7k lines, it is labeled status: manual, so a maintainer will answer the scope question there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions