AC-MIL is an anatomy-aware dual-stream multiple instance learning framework for predicting estimated glomerular filtration rate (eGFR) from kidney whole-slide images. It represents each slide as two bags of patches: glomerular-enriched and non-glomerular. This separation preserves compartment-specific information that may be diluted when all tissue is pooled into a single representation.

A shared frozen CONCHv1.5 encoder embeds both bags. Each stream is pooled independently, and a bidirectional gating module integrates the resulting representations. Both pooled embeddings condition each gate, allowing the model to modulate features from either compartment using the context of the whole slide.

Anatomical partitioning

Extract 512 × 512 patches at 20× magnification. Frozen segmentation models separate them into glomerular-enriched and non-glomerular bags.

Compartment-specific pooling

A shared frozen encoder embeds both bags. Mean pooling, ABMIL, or TransMIL produces one pooled representation per compartment.

Bidirectional gating

Both pooled representations condition two feature-wise gates. The gated embeddings are concatenated and passed to a regression head to predict eGFR.

A PAS-stained kidney whole-slide image is split into glomerular and non-glomerular patch bags. A shared frozen encoder embeds both bags, separate pooling produces compartment representations, and bidirectional feature gates combine them for eGFR regression.
AC-MIL architecture. Glomerular-enriched and non-glomerular patches are embedded with a shared frozen encoder and pooled independently. Two feature-wise gates, each conditioned on both pooled representations, modulate the streams before concatenation and eGFR regression.

Overall performance

0.6236Pearson reGFR prediction
19.07RMSEeGFR prediction
12.9%RMSE reductionRelative to whole-slide ABMIL

ABMIL with bidirectional gating. Performance is evaluated by patient-level cross-validation; the complete comparisons and reported variation are presented below.

Main results

eGFR prediction performance

AC-MIL with ABMIL achieves the highest Pearson and Spearman correlations and the lowest RMSE among the 21 evaluated configurations. The comparison includes whole-slide pooling, compartment-specific models, late fusion, and unidirectional gating.

eGFR prediction · ABMIL comparison
Input / integrationPearson r ↑Spearman ρ ↑RMSE ↓
Whole slidesingle-stream0.5214 ± 0.04000.4850 ± 0.043421.90 ± 3.0088
Glomerular-enrichedsingle-stream0.4380 ± 0.07290.4001 ± 0.078023.30 ± 3.5793
Non-glomerularsingle-stream0.5478 ± 0.05790.5165 ± 0.050421.70 ± 3.1528
Late fusiondual-stream0.4938 ± 0.00880.4767 ± 0.011523.65 ± 2.8058
Glomerular gatedual-stream0.4978 ± 0.02800.4521 ± 0.045222.31 ± 2.6821
Non-glomerular gatedual-stream0.4716 ± 0.04210.4493 ± 0.052522.88 ± 2.6494
AC-MILBidirectional gate · dual stream0.6236 ± 0.05060.5497 ± 0.074819.07 ± 3.3059

Three-fold patient-level cross-validation across three seeds. Values reproduce the manuscript’s reported means and ± terms; bold marks the best value in each column. Slides from the same patient remain in the same fold.

AC-MIL reduces RMSE from 21.70 to 19.07 relative to non-glomerular ABMIL, a 12.1% reduction. Relative to whole-slide ABMIL, RMSE decreases by 12.9% (21.90 to 19.07), while Pearson r increases from 0.5214 to 0.6236.

Full comparison: all 21 configurations
Input / integrationRepresentationPoolingPearson r ↑Spearman ρ ↑RMSE ↓
Bidirectional gateDual-StreamTransMIL0.5048 ± 0.02350.4684 ± 0.041322.53 ± 3.4903
AC-MILDual-StreamABMIL0.6236 ± 0.05060.5497 ± 0.074819.07 ± 3.3059
Bidirectional gateDual-StreamMean Pool0.5248 ± 0.04770.4893 ± 0.079322.14 ± 2.8999
Glomerular gateDual-StreamTransMIL0.4612 ± 0.04100.4165 ± 0.037823.24 ± 3.6077
Glomerular gateDual-StreamABMIL0.4978 ± 0.02800.4521 ± 0.045222.31 ± 2.6821
Glomerular gateDual-StreamMean Pool0.5083 ± 0.11490.4839 ± 0.097522.30 ± 4.3130
Non-glomerular gateDual-StreamTransMIL0.4964 ± 0.01870.4815 ± 0.032823.28 ± 2.2006
Non-glomerular gateDual-StreamABMIL0.4716 ± 0.04210.4493 ± 0.052522.88 ± 2.6494
Non-glomerular gateDual-StreamMean Pool0.4624 ± 0.02810.4174 ± 0.043022.97 ± 2.5062
Late fusionDual-StreamTransMIL0.4939 ± 0.02710.4498 ± 0.066322.99 ± 3.0887
Late fusionDual-StreamABMIL0.4938 ± 0.00880.4767 ± 0.011523.65 ± 2.8058
Late fusionDual-StreamMean Pool0.4669 ± 0.06820.4321 ± 0.084122.58 ± 3.3420
Whole slideSingle-StreamTransMIL0.4734 ± 0.00730.4311 ± 0.010823.81 ± 2.3466
Whole slideSingle-StreamABMIL0.5214 ± 0.04000.4850 ± 0.043421.90 ± 3.0088
Whole slideSingle-StreamMean Pool0.4993 ± 0.06250.4671 ± 0.078122.47 ± 3.4559
Glomerular-enrichedSingle-StreamTransMIL0.4805 ± 0.05850.4337 ± 0.056622.50 ± 4.1410
Glomerular-enrichedSingle-StreamABMIL0.4380 ± 0.07290.4001 ± 0.078023.30 ± 3.5793
Glomerular-enrichedSingle-StreamMean Pool0.4874 ± 0.01430.4528 ± 0.039522.45 ± 2.8337
Non-glomerularSingle-StreamTransMIL0.5031 ± 0.04560.4729 ± 0.051822.51 ± 3.0477
Non-glomerularSingle-StreamABMIL0.5478 ± 0.05790.5165 ± 0.050421.70 ± 3.1528
Non-glomerularSingle-StreamMean Pool0.4802 ± 0.09460.4579 ± 0.094422.63 ± 4.1248

The comparison includes TransMIL, ABMIL, and mean pooling. AC-MIL with ABMIL has the highest Pearson and Spearman correlations and the lowest RMSE.

Disease-specific experiments

Performance by disease group

The best-performing single-stream compartment differs between disease groups: glomerular-enriched tissue in diabetic kidney disease, and non-glomerular tissue in acute tubular injury and acute interstitial nephritis. AC-MIL achieves the highest Pearson correlation in both groups.

Glomerulus-involved

Diabetic kidney disease

Among single-stream models, glomerular-enriched tissue gives the highest Pearson correlation and lowest RMSE.

InputPearson r ↑RMSE ↓
Whole slide0.458522.74
Glomerular-enriched0.568920.84
Non-glomerular0.350122.99
AC-MIL0.594521.21

AC-MIL achieves Pearson r = 0.5945, compared with 0.4585 for whole-slide ABMIL. The glomerular-only model has the lowest RMSE.

Extra-glomerular

Tubular & interstitial disease

Among single-stream models for acute tubular injury and acute interstitial nephritis, non-glomerular tissue gives the highest Pearson correlation and lowest RMSE.

InputPearson r ↑RMSE ↓
Whole slide0.525020.88
Glomerular-enriched0.351823.07
Non-glomerular0.601919.35
AC-MIL0.636619.75

AC-MIL achieves Pearson r = 0.6366, compared with 0.5250 for whole-slide ABMIL. The non-glomerular-only model has the lowest RMSE.

All comparisons use ABMIL. Bold denotes the highest correlation or lowest RMSE within each group. Compartment-only models achieve the lowest subgroup RMSE; AC-MIL has the highest correlation and second-lowest RMSE in both.

Matched patch-budget analysis

All three anatomy-aware inputs reduce RMSE relative to whole-slide ABMIL at each tested fixed bag size. Non-glomerular input has the largest reduction at 16 and 32 patches; AC-MIL has the largest reduction at 64 patches.

InputK = 16K = 32K = 64Natural bags
AC-MIL−0.4509−0.5772−0.5299−2.83
Glomerular−0.7073−0.3259−0.4075+1.40
Non-glomerular−0.7916−0.6594−0.5041−0.20

Signed ΔRMSE relative to whole-slide ABMIL; more negative is better. Fixed-cardinality experiments use five seeds, with the same total patch budget and an even split across AC-MIL’s two streams. Non-glomerular input leads at K = 16 and K = 32; AC-MIL leads at K = 64.

Transferability

Transfer to proteinuria and albuminuria

Slide embeddings learned for eGFR prediction are frozen and used to train an MLP for proteinuria or albuminuria classification. These experiments assess whether the learned representations support related renal endpoints.

0.8260AUROC

Proteinuria

AC-MIL has the highest accuracy, AUROC, and F1 among the evaluated representations. AUROC is 0.0795 higher than with whole-slide embeddings.

0.7242AUROC

Albuminuria

AC-MIL has the highest AUROC and accuracy among the evaluated representations. AUROC is 0.0879 higher than with whole-slide embeddings.

Proteinuria Positive at ≥ 150 mg/g creatinine
Slide representationAccuracy ↑AUROC ↑F1 ↑
Whole slide0.6980 ± 0.04090.7465 ± 0.07710.7874 ± 0.0345
Glomerular0.6984 ± 0.04890.7217 ± 0.08810.7822 ± 0.0425
Non-glomerular0.7390 ± 0.04770.8087 ± 0.12320.8102 ± 0.0354
AC-MIL0.7438 ± 0.00930.8260 ± 0.10740.8160 ± 0.0025
Albuminuria Positive at ≥ 30 mg/g creatinine
Slide representationAccuracy ↑AUROC ↑F1 ↑
Whole slide0.6650 ± 0.01090.6363 ± 0.15620.7668 ± 0.0176
Glomerular0.6656 ± 0.04870.7124 ± 0.09490.7601 ± 0.0169
Non-glomerular0.6499 ± 0.03780.6465 ± 0.18460.7470 ± 0.0111
AC-MIL0.6687 ± 0.03870.7242 ± 0.07480.7648 ± 0.0345

All single-stream representations use ABMIL; AC-MIL uses bidirectional gating. The eGFR-trained slide embeddings are frozen, and downstream MLP classifiers are trained for each target. Bold marks the best value per target and metric. This evaluates transfer between tasks; external-cohort generalization is not evaluated here.

Among single-stream representations, non-glomerular embeddings have the highest proteinuria AUROC, while glomerular embeddings have the highest albuminuria AUROC. AC-MIL has the highest AUROC and accuracy for both targets. Whole-slide embeddings have a slightly higher albuminuria F1 (0.7668 versus 0.7648).

Pathology analysis

Exploratory analysis of tissue morphology

High-attention patches from each stream are examined using a vision-language model, comparing patients with high and low predicted eGFR.

Glomerular morphologic features

The low-predicted-eGFR group has higher frequencies of VLM-identified inflammation, fibrosis or matrix expansion, injury, and structural distortion. VLM-identified inflammation is reported in 14.0% of patches in this group, compared with 4.2% in the high-predicted-eGFR group.

Non-glomerular morphologic features

VLM-identified injury or degeneration is more frequent in the high-predicted-eGFR group than in the low-predicted-eGFR group (9.9% versus 2.3%). The observed association differs from that in glomerular patches.

VLM-identified morphologic features (%)
FeatureGlomerular patchesNon-glomerular patches
High predicted eGFRLow predicted eGFRHigh predicted eGFRLow predicted eGFR
Inflammation4.2 ± 0.914.0 ± 1.95.1 ± 3.03.4 ± 5.2
Fibrosis or matrix expansion1.3 ± 2.46.9 ± 0.73.4 ± 5.92.8 ± 0.7
Injury or degenerative change1.8 ± 3.16.0 ± 1.09.9 ± 1.12.3 ± 1.6
Structural distortion2.5 ± 0.35.6 ± 1.70.9 ± 2.20.1 ± 1.0

High and low refer to model-predicted eGFR. Quilt-LLaVA characterizes high-attention patches, and a separate language model aggregates the outputs. The reported uncertainty uses patch-level bootstrapping. Colored values mark the differences highlighted in the manuscript.

The VLM-based summaries identify different morphologic patterns across the two streams. These exploratory findings require validation by expert renal pathologists.

Citation

AC-MIL is presented in Context Matters: Anatomy-Aware Dual-Stream Multiple Instance Learning Framework for eGFR Prediction.

@inproceedings{arab2026context,
  title     = {Context Matters: Anatomy-Aware Dual-Stream Multiple Instance Learning Framework for e{GFR} Prediction},
  author    = {Abteen Arab and Maziar Riazy and Ali Bashashati},
  booktitle = {Medical Imaging with Deep Learning - Short Papers},
  year      = {2026},
  url       = {https://openreview.net/forum?id=KTfPFMntqQ}
}