Ordinal Label-Distribution Learning with Constrained Asymmetric Priors for Imbalanced Retinal Grading

Nagur Shareef Shaik, Teja Krishna Cherukuri, Adnan Masood, Ehsan Adeli, Dong Hye Ye

TL;DR

Diabetic retinopathy (DR) grading is plagued by severe class imbalance, ordinal disease progression, and asymmetric clinical stakes where under-grading carries far graver consequences than over-grading. To tackle this, the authors introduce CAP-WAE (Constrained Asymmetric Prior Wasserstein Autoencoder), a framework that aligns latent representations to a data-derived asymmetric generalized Gaussian prior, regularizes latent geometry for grade separability, and incorporates direction-aware ordinal supervision. The model achieves state-of-the-art Quadratic Weighted Kappa (QWK) and macro-F1 across four public DR benchmarks.

What Problem Does This Paper Address?

Automated grading of diabetic retinopathy from retinal fundus images faces three major hurdles:

  1. Severe class imbalance: Extreme stages (both very mild and proliferative DR) are heavily underrepresented, leading models to bias predictions toward majority categories.
  2. Ordinal relationships: DR progresses along an ordinal scale (e.g., normal $\rightarrow$ mild $\rightarrow$ moderate $\rightarrow$ severe $\rightarrow$ proliferative). Standard classification treats misclassifying grade 0 as grade 4 with the same penalty as confusing adjacent grades 1 and 2.
  3. Asymmetric clinical risk: Under-grading high-severity DR risks irreversible vision loss due to delayed treatment, whereas over-grading primarily costs unnecessary follow-up exams. Standard loss functions and symmetric Gaussian latent priors overlook this directional clinical penalty and compress rare minority modes into oblivion.

Methods

CAP-WAE unifies generative latent modeling, geometric constraints, and order-sensitive supervision:

  • Encoder–Decoder Backbone: A pre-trained VGG-16 maps fundus images to a 512-dimensional latent vector $z$, paired with a transposed-convolutional decoder for image reconstruction.
  • Constrained Asymmetric Prior via WAE: Instead of forcing representations into an isotropic Gaussian via strict Kullback–Leibler (KL) divergence (which suppresses rare minority structures), CAP-WAE matches the aggregate posterior distribution to an Asymmetric Generalized Gaussian Distribution (AGGD) using Maximum Mean Discrepancy (MMD). The shape and scale parameters of the AGGD prior are empirically estimated directly from the data.
  • Margin-Aware Orthogonality and Compactness (MAOC) Loss: To keep grade representations structured and distinct, MAOC enforces angular separation (near-orthogonality) between class prototypes while pulling intra-class representations tight to their class centers.
  • Direction-Aware Ordinal Supervision: Three specialized prediction heads branch from the latent vector:
  • A standard classification head (cross-entropy).
  • An Asymmetric-Gaussian (AG) head that predicts instance-level left/right dispersion parameters $(\sigma_\ell, \sigma_r)$ to generate asymmetric soft labels, penalizing under-grading more severely than over-grading.
  • An Ordinal Regression (ORM) head predicting a scalar severity score penalized via Huber loss.
  • Uncertainty-Weighted Multi-Task Loss: Rather than manually tuning loss balances, the model dynamically learns homoscedastic task weights (log-variances) end-to-end.
                  ┌─► Classification Head (L_CE)
                  │
Fundus ──► Encoder──► Latent z ──► AG-Soft Head (L_AG: directional penalty)
Image      f_ϕ    │     ▲        │
                  │     │        └─► Ordinal Head (L_ORM: scalar Huber loss)
                  │     ├── MMD Alignment ──► Empirical Asymmetric Prior (AGGD)
                  │     └── MAOC Loss ──────► Prototype Orthogonality & Compactness
                  │
                  └─► Decoder g_θ ──────────► Reconstruction Loss (MSE)

Datasets

The authors evaluate CAP-WAE across four public fundus benchmarks spanning two grading scales and multiple camera systems:

  • Zenodo-DR-7: 757 images (605 train / 152 test) captured with a Zeiss Visucam 500, labeled on a fine-grained 7-class scale (No DR to Advanced PDR). This serves as the primary benchmark due to its fine granularity and heavy tail.
  • IDRiD: 516 images (413 train / 103 test) using a Kowa VX-10a camera, based on an Indian patient cohort and standard 5-grade taxonomy.
  • APTOS-2019: 3,662 images (2,929 train / 733 test) captured under diverse clinical conditions with heterogeneous cameras (5 grades).
  • Messidor-2: 1,748 images (1,398 train / 350 test) acquired via Topcon TRC-NW6 (5 grades), critical for cross-device evaluation.

No new datasets were introduced.

Key Insights and Ideas

  • Aggregate matching beats instance-wise KL matching: Variational autoencoders (VAEs) penalize every individual sample posterior against a standard normal distribution, squashing minority classes. Matching only the aggregate posterior via MMD allows individual clusters to maintain their natural, skewed shapes.
  • Prior shape matters for long-tailed tasks: Injecting an asymmetric, heavy-tailed prior (AGGD) directly counteracts the shrinkage of rare classes in the latent space.
  • Separation requires both geometry and ordinality: Combining prototype orthogonality (MAOC) with ordinal soft distributions and regression prevents adjacent classes from overlapping, transforming an entangled latent space into organized bands ordered by disease progression.

Key Results

CAP-WAE consistently outperformed conventional balance-aware methods (Focal Loss, LDAM-DRW), ordinal baselines (CORN, OLDL), and generative models (VAE, WAE):

  • Zenodo-DR-7: Achieved 0.94 QWK, 91.80% Accuracy, and 89.90% Macro-F1 (a +0.04 QWK jump and +2.7% F1 boost over the competitive AGDGN+OLDL baseline).
  • IDRiD: Reached 0.87 QWK, 86.10% Accuracy, and 81.20% Macro-F1 (outperforming all baselines, including a +2.6% lift in macro-F1 over AGDGN+OLDL).
  • APTOS-2019 & Messidor-2: Achieved 0.90 and 0.89 QWK, respectively, demonstrating robust generalization across camera types.
  • Ablation Studies: Showed that each module provided progressive gains—introducing the asymmetric prior yielded +0.8–1.1 QWK, while adding MAOC and the ORM head provided the final push toward clean separation.
  • Latent Space (t-SNE): While standard VAEs produced overlapping latent distributions, CAP-WAE yielded compact, sequentially ordered, nearly disjoint bands that followed clinical severity from No DR to Advanced PDR.

Limitations and Future Work

  • Distribution Stationarity Assumption: The parameters of the asymmetric prior are fixed empirically from the training split, which may reduce performance if test-time data experiences extreme domain shifts.
  • Local vs. Global Separability: The MAOC loss optimizes local geometric relationships between class prototypes but lacks formal theoretical guarantees of global separability.
  • Reliance on Ordinal Quality: The formulation assumes ground-truth annotations accurately reflect an ordinal scale; high inter-grader annotation noise in real-world clinical data could degrade soft-label quality.
  • Future Directions: Incorporating self-supervised or multi-modal foundation features, making priors dynamically adaptive under domain shifts, and extending the formulation to longitudinal monitoring of disease progression and other ordinal tasks (e.g., cancer staging).

Summary updated

BibTeX
@inproceedings{shaik2025ordinal,
  author = {Nagur Shareef Shaik and Teja Krishna Cherukuri and Adnan Masood and Ehsan Adeli and Dong Hye Ye},
  title = {{Ordinal Label-Distribution Learning with Constrained Asymmetric Priors for Imbalanced Retinal Grading}},
  booktitle = {GenAI4Health @ NeurIPS},
  year = {2025},
  url = {https://openreview.net/forum?id=hatzHLfYtF},
}
Figure