CardioPINN — Physics-Informed Cardiac Inverse-Problem Lab
A two-case lab in physics-informed cardiac reconstruction, on 100% real measured data, scoped as a complement to classical methods, not a replacement. Case 1 (ECGi) recovers heart-surface potentials from body-surface potentials with regularized least squares plus a graph prior and a deep ensemble; case 2 (4D-flow) recovers the aortic relative-pressure FIELD from MRI velocity with a genuine divergence-free PINN. What the physics adds is what the classical method cannot give: calibrated per-node uncertainty (2-sigma coverage ~0.90) and a resolved pressure field from a well-posed solve, a different output class than a one-number Bernoulli estimate. Point accuracy sits at parity with a well-tuned Tikhonov baseline, stated in-app, because replacing classical accuracy was never the goal. Two confirmed, CI-tested autograd advances (spatial and temporal) and three published null results.
Business Context
The value of an inverse-problem tool in medicine is not a pretty reconstruction, it is a defensible one: a number a clinician can weigh, with an honest uncertainty, and a clear statement of where the method was and was not validated. CardioPINN is scoped as a complement to classical methods where information is partial and confidence-per-node is part of the answer: the ensemble gives a calibrated per-node uncertainty a deterministic estimate cannot, and the PINN lane turns MRI velocity into a resolved relative-pressure field, a different output class than the one-number Bernoulli estimate used clinically. Point accuracy sits at parity with the classical Tikhonov baseline and the app states that, along with its own leakage disclosure, because replacing classical accuracy was never the scorecard.
Strategic Value
CardioPINN is a correctly-scoped methodological study of physics-informed inverse problems: complement, not replacement. Its narrow-but-real wins are the ones the classical method cannot produce: calibrated per-node uncertainty (2-sigma coverage ~0.90) and a resolved relative-pressure field from a well-posed solve. It confirms two implementation advances on known-answer analytic flows, both CI-tested: spatial analytic-autograd source and flux (0.066 vs 4.19 mmHg drop error, 6 of 6, roughly 63x) and temporal analytic-autograd dv/dt, which holds scale ~1.0 and correlation above 0.99 down to ~6 frames per cycle while 3-frame finite differences lose amplitude by the sinc aliasing law (0.76 at 6 frames, collapsing at 4). And it publishes three real nulls (hard div-free curl refuted 0/6; differentiable coupling no gain; structural UQ calibrated at 0.93 but uninformative), plus a caught-and-re-run round-one confound. The pattern, ground everything in real measured data, test advances on analytic flows, calibrate the uncertainty, report the nulls, transfers to any ill-posed reconstruction problem.
The Challenge
Two clinically valuable cardiac quantities cannot be measured directly: the electrical potential on the surface of the heart, and the pressure field inside the aorta. Both have to be reconstructed from something that can be measured (body-surface electrodes for the first, 4D-flow MRI velocity for the second), and both are ill-posed inverse problems where a plausible-looking answer can be quietly wrong. There is no invasive gold standard to check against on the real data, which is exactly why the problem is interesting and exactly why it is easy to overclaim. The honest question is not "does it produce a reconstruction" but "when should you trust it, and what does the physics add that the classical method cannot give".
Our Approach
CardioPINN runs two real-data cases and reports what actually happened. Case 1, ECGi, recovers heart-surface potentials from body-surface potentials on EDGAR data (a Utah human torso tank, 192 electrodes to a 256-node cage, and a Maastricht in-situ dog, 140 to 1321 nodes) using zeroth-order Tikhonov regularized least squares as the classical baseline, a graph-Laplacian prior built from the real heart-cage triangulation, and a K=6 deep ensemble over measurement-noise draws that is temperature-recalibrated so its two-sigma band matches the real error. This case contains NO PINN and no torch; it is a regularized linear inverse plus ensemble uncertainty. Case 2, 4D-flow, is the genuine PINN: a divergence-free velocity network (torch) that denoises the measured velocity, a pressure-Poisson solve driven by the network analytic autograd derivatives, and a space-time PINN for the unsteady acceleration, on one real thoracic-aorta 4D-flow MRI scan (47,902 lumen voxels, 16 frames). Everything is computed offline into committed JSON traces that the web reads; no model runs in the browser. Candidate advances are tested on known-answer analytic flows, since the real data has no gold standard, and the results, positive and null, are published.
Key Performance Indicators
| KPI | Baseline | Result | Impact |
|---|---|---|---|
| The right scorecard | Judging a physics-informed method by whether it beats classical point accuracy | Complement, not replacement: calibrated per-node uncertainty (2-sigma ~0.90) and a resolved pressure field, outputs the classical method cannot give; point accuracy at parity with Tikhonov, stated in-app | A different output class (field + confidence), not an inflated accuracy claim |
| Two confirmed, tested advances | Finite differences: inflated pressure drop at the lumen edge (spatial) and amplitude loss by sinc aliasing at low frame rates (temporal, 0.76 at 6 frames per cycle, collapsing at 4) | Analytic autograd, spatial: 0.066 vs 4.19 mmHg drop error, 6 of 6, roughly 63x. Analytic autograd, temporal (dv/dt): scale ~1.0 and correlation above 0.99 down to ~6 frames per cycle | Both confirmed on known-answer analytic flows and CI-tested, as method properties, with no clinical claim |
| Published null results | Hide the experiments that did not work | 3 nulls published (hard div-free curl refuted 0/6; differentiable coupling no gain; structural UQ calibrated at 0.93 but uninformative) + a round-1 confound caught and re-run | The honest record is the deliverable |
| Data | Synthetic ground truth | 100% real measured data: EDGAR ECGi (4 beats, 2 datasets) + one thoracic-aorta 4D-flow MRI (47,902 voxels); zero synthetic ground truth | A real problem at small n, with no fabricated gold standard; datasets that failed inspection were dropped |
Architecture
cardiopinn pipeline
Complement, not replacement
CardioPINN is a two-case lab in physics-informed cardiac reconstruction, run entirely on real measured data, and scoped as a complement to classical methods, not a replacement: it targets what the classical estimate cannot give, a calibrated confidence per node and a resolved field, where information is partial and confidence is part of the answer. It recovers cardiac quantities that cannot be measured (heart-surface potentials; the aortic relative-pressure field) from quantities that can (body-surface potentials; 4D-flow MRI velocity), bakes the physics offline into committed JSON traces, and the web replays them. Live at cardiopinn.fasl-work.com.
Two cases, and only one of them is a PINN
- Case 1, ECGi, is not a PINN. It recovers heart-surface potentials with zeroth-order Tikhonov regularized least squares (the classical baseline, closed form per frame), a graph-Laplacian prior from the real heart-cage triangulation, and a K=6 deep ensemble over measurement-noise draws, temperature-recalibrated. It is NumPy/SciPy, no torch: a regularized linear inverse plus ensemble uncertainty. Real EDGAR data (Utah human torso tank, 192 to 256 electrodes; Maastricht in-situ dog, 140 to 1321 nodes), four beats.
- Case 2, 4D-flow, is the genuine PINN. A divergence-free velocity network (torch) denoises the measured velocity, a pressure-Poisson solve is driven by the network’s analytic autograd derivatives, and a space-time PINN recovers the unsteady acceleration, on one real thoracic-aorta 4D-flow MRI scan (47,902 lumen voxels, 16 frames).
The product name implies a PINN across both cases; half of it (the ECGi case) has none, and the app is written to make that clear rather than to paper over it.
What the physics adds (and what it does not)
Replacing classical point accuracy was never the goal, and the app says so: on all four beats, point accuracy sits at parity with a well-tuned Tikhonov baseline (the headline relative-error and correlation numbers are the baseline’s, disclosed in-app, including the oracle-best-lambda selection). What the physics-informed lane adds is what the deterministic estimate structurally cannot: a calibrated per-node uncertainty (two-sigma reliability 0.89-0.90 across all four beats), so a clinician sees not just a reconstruction but where to trust it, and on the 4D-flow side a resolved relative-pressure field from a well-posed solve, a different output class than the one-number Bernoulli estimate used clinically. Narrow wins, but real ones, on the right scorecard.
Two confirmed advances, and the nulls, published
Candidate advances are tested on known-answer analytic flows, because the real data has no invasive gold standard, and the nulls are published, not hidden:
- Confirmed, spatial (shipped, CI-tested): analytic-autograd source and flux versus finite differences on a converging duct: median pressure-drop error 0.066 mmHg (analytic) versus 4.19 mmHg (FD), winning 6 of 6 configurations, roughly 63x.
- Confirmed, temporal (CI-tested): analytic-autograd dv/dt holds scale ~1.0 and correlation above 0.99 down to ~6 frames per cycle, while 3-frame finite differences lose amplitude by the sinc aliasing law (0.76 at 6 frames, collapsing at 4). The temporal analog of the spatial win, confirmed on analytic flows, as a method property, with no clinical claim.
- Null: a hard divergence-free construction (velocity as the curl of a potential) was hypothesized to help pressure and was refuted, pressure got worse and it won pressure 0 of 6.
- Null: a differentiable denoiser-solver coupling reproduced the direct solve exactly but gave no gain.
- Null: a structural-perturbation uncertainty field was calibrated (0.93 coverage) but uninformative on a clean lumen.
A round-one methodological confound (an FD pressure solve masking all differences) was caught and re-run on the analytic path, and recorded rather than hidden.
Honest scope
The recovered aortic relative-pressure range (0.79 mmHg, alongside a 2.3x divergence reduction on the real scan) is physiological and plausible, not validated: there is no invasive gold standard, which is the entire reason the method exists. The cohort is tiny (four beats, one MRI scan), the EDGAR raw data is not redistributed under its use agreement, and datasets that failed inspection (a rank-deficient partial sock, a simulation mislabelled as measurement, an unreadable BEM) were excluded and the reasons recorded. It is not clinically deployed.
Technology Stack
Reel
A short, composed reel of the product.

In action
A short tour of the live app — the real interface, recorded from the deployed site.

Application Screenshots

