Local Fractal Maps as Free Supervision for Fine-Grained Retinal Grading

Automated eye-disease systems score well when asked "diseased or not" and poorly when asked "how severe." For diabetic retinopathy, the clinically useful grades are the intermediate ones, mild versus moderate versus severe, because they determine follow-up intervals and treatment. These grades are rare, they overlap visually, and expert labels for them are expensive. Separately, a well-documented measurement exists for how intricately blood vessels branch: the fractal dimension. It is a number between 1 and 2 for a 2D vessel tree, computed by counting how many grid boxes the vessels occupy as the boxes shrink. It falls measurably as microvasculature thins out with disease. It needs no expert to compute, only a vessel tracing of a clean image.

This note proposes computing that measurement locally, patch by patch, on clean fundus photographs. A network is then trained to predict the resulting "fractal map" from degraded images of any quality, and the predicted map serves as a free, dense auxiliary target and input for multi-grade retinopathy classifiers. The bet is specific. A geometry signal that costs no expert time, that is spatially resolved rather than a single global number, and that is trained to survive image degradation should help most where granular grading fails today: intermediate and advanced grades, small label budgets, and unseen hospitals. The proposal also includes the control that would show the bet is wrong, namely an identical map of plain vessel density.

Core Claim

Prior work has shown both halves but never joined them. Chua et al. showed that box-counting fractal dimension of the superficial retinal capillaries separates cognitively impaired patients from controls (AUC 0.77, versus 0.56 for an MRI atrophy score) and drops at the intermediate MCI stage. Their pipeline used manual segmentation and offline computation, and it reduced each eye to one number per region. Engelmann et al. showed that a ResNet18 can regress global fractal dimension directly from raw fundus pixels. They trained it on synthetically degraded copies of clean images whose labels came from a classical pipeline, reaching r = 0.9572 on clean images and r = 0.8817 under maximal degradation, and recovering the 26–43% of images the classical pipeline discards. Their model predicts a single scalar and is never used for disease grading.

Fine-grained grading work points the other way. Samba argues that grading depends on small, localized lesions that global pooling washes out. Zhou et al. show that pixel-level lesion masks improve DR grading kappa by up to 8.04%, but those masks took specialist tracing on FGADR.

Our claim: a degradation-robust, patch-level fractal map, obtained without any expert annotation, recovers a meaningful part of the benefit of expensive lesion masks for multi-grade DR. It adds information beyond what an equally cheap vessel-density map provides, and the gain is concentrated in rare intermediate and advanced grades and in leave-one-hospital-out transfer.

Research Program

The first component is the target. On the subset of fundus images that pass a quality filter, we segment vessels with an off-the-shelf segmenter. Within each window of side $W$ centered on a grid of locations, we count the occupied boxes $N_p(\epsilon)$ at box sizes $\epsilon$ from 2 pixels up to $W/4$. The local dimension is the least-squares slope

$$D_p = -\frac{d \log N_p(\epsilon)}{d \log \epsilon},$$

where $p$ indexes the window. We also keep the residual curvature of the fit as a second channel, a cheap stand-in for the multifractal spread that Liu et al. found necessary when one dimension cannot separate clustered from dispersed structure. We borrow the sparsity safeguard of FRACAL, which caps grid resolution by sample count. Windows with too few vessel pixels to form a stable log-log line are marked invalid and excluded from the loss rather than assigned a noisy value.

The second component is a dense version of Engelmann's counterfactual trick. A fully convolutional network predicts the two-channel map of a clean image from synthetically blurred, noised, relit, and occluded copies of it. This model is trained on unlabeled images pooled across datasets. No grade labels are involved, and the expensive segmentation runs only on clean images.

The third component is grading. Two uses are tested. In the first, the predicted map is concatenated as extra input channels, analogous to the morphology channels of Lin et al.. In the second, a shared encoder is trained with an auxiliary head regressing the map:

$$\mathcal{L} = \mathcal{L}_{\text{grade}} + \lambda \sum_{p \in V} \| \hat{M}_p - M_p \|^2 .$$

Here $\mathcal{L}_{\text{grade}}$ is the ordinal grading loss, $V$ is the set of valid windows, $\hat{M}_p$ is the encoder's predicted map value at window $p$, $M_p$ is the robust regressor's output, and $\lambda$ is a weight tuned on validation.

The proposal is honest about the biology. Microaneurysms and hemorrhages are not vessel-branching phenomena, so the map should not help detect mild disease from lesion spots alone. It should matter where vessel geometry itself changes: capillary dropout, intraretinal microvascular abnormalities, and new vessel growth. Those changes define the severe and proliferative grades. We therefore predict gains per grade, not uniformly.

Baselines

The naive reference point is a plain ResNet or ConvNeXt grader trained on the same images and grade labels, with matched augmentation including the same synthetic degradations. Including those degradations rules out the possibility that any gain comes from the augmentation alone.

The strongest existing method on this exact benchmark family is Samba, which combines bidirectional state-space patch modeling with Gaussian-mixture severity recalibration across six fundus datasets (APTOS, DeepDR, Messidor, IDRID, FGADR, RLDR). The file reports only its relative gain, +4.1% average accuracy over VMamba on DR grading, and no absolute accuracy or kappa was found on Lacuna. We will therefore rerun Samba from its protocol under the same leave-one-domain-out splits. We will also add our map to Samba's input, since the claim is complementary signal rather than a replacement architecture. Beating Samba means a statistically significant improvement in mean quadratic weighted kappa across held-out domains and in macro recall over grades 2–4, with paired bootstrap over images.

The expert-cost ceiling is the lesion-mask approach of Zhou et al., which reported up to an 8.04% kappa increase on the FGADR Grade-set from predicted lesion masks. We use FGADR's lesion segmentations to train their mask predictor and evaluate on the same grade split. Success here is closing at least half of their gap over the naive grader at zero annotation cost, or adding to it when both are combined.

The key ablation replaces the fractal map with a local vessel-density map, meaning the fraction of vessel pixels per window, produced by the identical segment-then-robustly-regress pipeline. This isolates whether the non-integer scaling exponent carries anything beyond "how much vessel is here." A second ablation uses a single global fractal dimension from a DART-style regressor as a scalar side input, which tests whether locality matters. All variants share one backbone, one tuning budget of equal hyperparameter trials, and identical training epochs.

Why not just…?

Why not just train the grader end-to-end and let it learn vessel geometry itself? With abundant labels it may, and that is a real threat. The evidence that it does not at realistic scale is indirect: Lin et al. found that deeper networks overfit and lost to shallower ones with explicit morphology channels on a roughly 900-image fine-grained task. A linear probe settles it. If frozen features of a fully trained grader already predict the fractal map with $R^2$ near the regressor's own, the auxiliary target is redundant. We then expect, and will report, gains only in the low-label regime.

Why not just use vessel density, which clinicians already report? Chua et al. found fractal dimension significant at the MCI stage where density effects were weaker, and Williams et al. found fractal and branching measures of corneal nerves more sensitive than length. Neither tested DR grading inside a learned model. The density-map ablation above answers this directly. If it matches the fractal map, the honest conclusion is that cheap dense vessel supervision helps and the fractal exponent does not, and we will say so.

Why not just self-supervised pretraining on the same unlabeled fundus images? This is the fairest "free supervision" competitor, because our map also uses only unlabeled images. We will pretrain a masked autoencoder on the identical image pool with matched GPU hours, then fine-tune under the same label budgets. Our proposal wins only if the geometric target beats generic reconstruction on intermediate-grade recall or held-out-domain kappa. Otherwise the fractal target is just a weaker pretext task.

Why not just reweight rare grades by frequency? Class-balanced losses address imbalance, not missing signal. FRACAL showed in detection that a geometric statistic correlated only weakly (0.35) with frequency and added rare-class gains beyond frequency-only calibration. We apply logit adjustment to every arm, so any remaining gain cannot be attributed to rebalancing.

Proposed Experiments

The main experiment is leave-one-domain-out DR grading on Samba's six datasets. It reports quadratic weighted kappa, balanced accuracy, and per-grade recall, under label fractions of 5%, 10%, 25%, and 100% of the training grades, with the map regressor always trained on unlabeled images only.

Four decisive checks follow. The first is the density-versus-fractal ablation at every label fraction. The second is the per-grade breakdown: we predict gains at severe and proliferative grades and little at mild. A uniform gain would suggest the map is acting as a generic regularizer, and a mild-only gain would contradict the stated mechanism. The third is the linear-probe redundancy test. The fourth is a degradation stress test, which reapplies Engelmann's five severity levels at test time and checks whether the map-augmented grader degrades more gracefully than the naive one.

A preliminary sanity analysis precedes all of this. It checks whether mean local $D$ over valid windows is monotone in FGADR consensus grade. If it is not even weakly ordered, the program stops before any grader is trained.