GRIT-Echo
Granular Uncertainty Modelling for Reliable Left-Ventricle Segmentation and LVEF Estimation in 2D Echocardiography

GRIT-Echo is a research project I carried out on automated left-ventricle (LV) segmentation in 2D echocardiography, using the public CAMUS dataset[3]. The project has two integrated stages. The first trains a supervised segmentation baseline, validates a clinical endpoint (LVEF by Simpson's biplane method) against expert reference values, and converts per-pixel predictive entropy into information granules of boundary confidence. The second formulates sequential LV contour tracking from end-diastole (ED) to end-systole (ES) as a granule-gated Markov decision process (MDP), providing a state-space foundation for future tracking agents.
Problem Statement
Automated LV segmentation now achieves high mean accuracy on public benchmarks, but per-case reliability remains unquantified. A standard network emits a point prediction even in frames where acoustic shadowing and speckle noise leave the boundary effectively undefined, and nothing in the output tells the clinician which cases to trust. Because downstream indices such as LVEF are computed directly from the predicted masks, silent segmentation errors propagate into silent clinical errors. This project treats reliability as a first-class output: alongside each segmentation, the system produces a calibrated signal that predicts whether that case is likely to be wrong.
Research Questions
Does predictive entropy concentrate predictably at anatomical boundaries and artifact regions, particularly within expert-rated poor-quality sequences?
Do granule-level statistics reliably predict per-case segmentation and LVEF error, enough to flag unreliable cases automatically before clinical use?
A third, exploratory objective was to define a well-posed MDP for contour tracking, including states, a granule-gated reward, and policy-free baselines, so that subsequent agents can be trained and compared on a common footing.
Methodology
Data and Cohort Audit
All experiments use CAMUS [3]: 500 patients and 2000 frames across two-chamber and four-chamber views at ED and ES. I audited the cohort before modeling: image and mask pairs are complete, the official train, validation, and test splits share no patients, and pixel spacing (0.308 mm) is read from each header rather than assumed. Expert-rated quality is uneven across views (for example, 69 poor-quality two-chamber sequences), which is exactly the subgroup the reliability signal must detect.

GRIT-Echo Project Architecture*
Supervised Baseline and Clinical Endpoint
The segmenter is a U-Net [1] with a ResNet-34 encoder [2] initialized with ImageNet weights, trained for 20 epochs with a combined soft-Dice and cross-entropy loss under AdamW and cosine annealing. Model selection uses macro foreground Dice on the validation split, and the best checkpoint reaches 0.9175 at epoch 19.
For the clinical endpoint I implemented Simpson's biplane method of disks following ASE recommendations [4]: largest connected component, principal-axis cavity profile by SVD, and 20-disk summation with per-header spacing. I validated the estimator itself on the validation split before trusting it on predictions: biplane EF computed from expert masks reproduces the clinical reference with MAE 8.49 EF points, bias +8.46, and r 0.97. This step matters because it separates estimator bias from segmentation error in every downstream number.
Granular Uncertainty Layer
From the frozen posterior I compute per-pixel Shannon entropy normalized to a 2-bit maximum, averaged over predicted tissue. Following granular computing [5,6], entropy is discretized into three information granules: crisp, vague, and artifact-prone. The two cutpoints are frozen at validation terciles and never refit on test, so the granule layer cannot leak test information. Sequence-level statistics (artifact fraction, crisp fraction, mean tissue entropy) are then compared against per-case Dice, HD95, and LVEF error on the isolated test split.
Granule-Gated Tracking MDP
ContourTrackerEnv tracks a 32-landmark radial contour from ED to ES over one half-sequence. The observation carries a 64x64 frame, the normalized radial contour, the granule of the contour band under the frozen cutpoints, and temporal progress. Actions are per-landmark radial offsets in the range of -4 to 4 pixels. The reward is a granule-weighted soft Dice against the frozen U-Net cavity posterior (weights 1.0, 0.6, 0.2 for crisp, vague, artifact-prone), minus action-magnitude and smoothness penalties, plus a terminal bonus of 2.0 times hard Dice against the expert ES mask. A PPO agent (MultiInputPolicy, 100k steps, 4 environments) is compared against two policy-free baselines: a passive ED contour and a random policy.
Results
Segmentation (test, native resolution): Dice 0.935, 0.877, 0.915 and HD95 3.99, 4.20, 4.18 mm for cavity, myocardium, and left atrium.
Clinical endpoint (test): predicted EF versus expert-mask EF gives MAE 4.29 EF points, bias -1.15, r 0.868; versus the clinical reference, MAE 8.24, bias +6.66, r 0.836.
RQ1 is supported. Per-sequence tissue entropy rises monotonically with expert-rated quality (Good 0.085, Medium 0.093, Poor 0.101), and the shift is significant (Kruskal-Wallis H = 23.93, p = 6.4e-06, epsilon-squared = 0.242). Poor-quality sequences contain no crisp granules and 73.3% artifact-prone granules.
RQ2 is supported. Artifact fraction correlates with per-case error (Spearman rho = -0.535 against Dice, +0.428 against HD95). A single threshold rule (artifact fraction above 0.5) separates retained sequences (Dice 0.918, n = 64) from flagged ones (0.892, n = 36; p = 2.7e-06), and refusing the worst 30% of sequences improves retained HD95 from 4.12 to 3.82 mm.
Tracking is a reported negative result. PPO trains stably (approximate KL near 0.015 to 0.02, clip fraction near 0.2, no entropy collapse) but does not exceed the passive ED-contour policy on paired validation episodes: 0.609 versus 0.610, delta -0.001, win rate 0.35, paired t-test p = 6.2e-02. The diagnosis is that flattened 64x64 observations starve the policy of spatial features, the terminal bonus is too sparse over roughly 18 to 21 steps, and the passive contour is a strong local optimum under action penalties. The contribution is the formulation itself, and solving it is explicit future work.
Limitations

Grit-Echo Project Limitations*
future Aspects
Solving the Active Contour Tracking MDP: Upgrading the RL policy by using a CNN feature extractor (instead of flattened 64x64 observations), applying behavior cloning from the U-Net posterior, and implementing denser potential-based reward shaping.
Scaling RL Training & Evaluation: Increasing the reinforcement learning training budget beyond the current 100k steps cap and evaluating the trained tracking agent on the held-out test set.
Multi-Center Validation: Expanding the dataset beyond the single-center CAMUS cohort to test generalizability on multi-center data.
Advanced Uncertainty Measures: Exploring reliability signals and uncertainty metrics beyond just predictive entropy.
Complex Cavity Geometries: Adapting the contour tracking formulation to handle non-convex cavities, moving beyond the current radial contour assumption.
A supervised baseline with a validated Simpson-LVEF endpoint, combined with a granular uncertainty layer whose cutpoints are frozen on validation data, yields a calibrated and actionable reliability signal: a single interpretable statistic, the artifact-granule fraction of a sequence, predicts per-case error and isolates a significantly worse subgroup without retraining the segmenter. The granule-gated MDP trains stably but does not yet beat a passive contour, which I report as a negative result together with its diagnosis. Active contour tracking remains open, and this framework is now equipped to attack it.
References
[1] O. Ronneberger, P. Fischer, and T. Brox, "U-Net: Convolutional networks for biomedical image segmentation," in Proc. MICCAI, 2015.
[2] K. He, X. Zhang, S. Ren, and J. Sun, "Deep residual learning for image recognition," in Proc. IEEE CVPR, 2016.
[3] S. Leclerc, E. Smistad, J. Pedrosa, A. Ostvik, et al., "Deep learning for segmentation using an open large-scale dataset in 2D echocardiography," IEEE Transactions on Medical Imaging, vol. 38, no. 9, pp. 2198-2210, 2019.
[4] R. M. Lang et al., "Recommendations for cardiac chamber quantification by echocardiography in adults," Journal of the American Society of Echocardiography, vol. 28, no. 1, pp. 1-39, 2015.
[5] W. Pedrycz, Granular Computing, CRC Press, 2005.
[6] L. A. Zadeh, "Fuzzy sets," Information and Control, vol. 8, no. 4, pp. 338-353, 1965.
*All the images were generated with Qwen-Image-2.0.
Subscribe to Transmissions
Join the archive to receive notifications when new projects, articles, or videos are catalogued. Transmissions are sent weekly or biweekly - never more.