Learning Prostate Anatomy at Test Time for Cancer Detection in Micro-Ultrasound
Authors: Obed Korshie Dzikunu, Mohammad Mahdi Abootorabi, Mohamed Harmanani, Paul F. R. Wilson, Emma Willis, Ferdinand Luger, Adam Kinnaird, Brian Wodlinger, +2 more
Organizations: Department of Electrical and Computer Engineering, University of British Columbia, Vancouver, Canada · Vector Institute, Toronto, Canada · School of Computing, Queen’s University, Kingston, Canada · Ordensklinikum Linz, Linz, Austria · Department of Surgery, University of Alberta, Edmonton, Canada · Exact Imaging, Markham, Canada
Domain shift across clinical centers using different imaging hardware or acquisition protocols remains a fundamental barrier to deploying deep learning models for prostate cancer (PCa) detection. Existing test-time adaptation (TTA) methods address distribution shift through entropy minimization or augmentation-based self-supervision, correcting for statistical differences in image appearance but ignoring the anatomical structure of the target domain. We propose ANT, a segmentation-guided TTA framework that adapts a pretrained cancer detection encoder to the target domain by solving an auxiliary prostate segmentation task at test time, supervised by pseudo-masks from a frozen pretrained segmentation network. By aligning encoder representations to prostate anatomy in the target domain, ANT corrects domain-specific feature drift while preserving cancer-discriminative structure. The model was trained on 693 patients imaged with an earlier-generation micro-ultrasound scanner in a multi-center clinical trial, and evaluated on 118 patients acquired with a newer-generation system across two centers in another clinical trial. Under a leave-one-center-out protocol with identical evaluation conditions across all methods, ANT improves mean AUC by 2.9% and 3.6% at the biopsy-core and patient levels, respectively, over no adaptation, outperforming TTA baselines. Code is available at: https://github.com/ObedDzik/ant.git.
Figures & tables
Figure 1: Overview of ANT framework. At inference, the first n layers of the trained cancer detection encoder is domain-adapted via an auxiliary segmentation task guided by pseudo-masks from a frozen segmentation network. The adapted encoder is then used for cancer detection.
Center
Patients
Cores
Cancer %
A (source)
693
5479
16%
B
76
1118
34.6%
C
42
569
27.0%
Table 1: Cohort statistics per clinical center. Centers differ in scanner generation and acquisition protocol, representing realistic deployment-time domain shift.
Patient-Level csPCa AUC
Core-Level csPCa AUC
Core-Level PCa AUC
Method
B
C
B
C
B
C
No adaptation
77.6(72.9−82.0)
79.4(66.8−89.9)
78.5(73.6−83.3)
84.5(74.0−93.1)
71.5(68.2−74.6)
73.8 (68.5 – 79.3)
MEMO ( Zhang et al., 2022 )
78.3(73.8−82.5)
83.5(73.0−91.7)
77.7(73.1−82.5)
83.4(71.8−92.9)
73.3(70.2−76.3)
70.6(65.3−76.3)
TENT ( Wang et al., 2020 )
76.0(71.6−80.2)
75.0(60.8−87.0)
80.1(76.0−84.3)
81.9(70.3−92.6)
74.5(71.5−77.3)
68.6(62.7−74.4)
EATA ( Niu et al., 2022 )
73.5(68.7−77.2)
69.4(65.1−72.8)
79.8(75.3−82.4)
80.5(77.3−84.2)
74.9 (71.0 – 77.2)
71.9(69.8−74.5)
CoTTA ( Wang et al., 2022 )
77.9(73.2−82.2)
77.9(64.6−89.7)
78.5(73.7−83.3)
84.1(73.8−92.7)
71.4(68.2−74.5)
72.9(67.4−78.4)
Table 2: AUC (95% bootstrap CI) for all methods across both evaluation centres (B and C). Bold indicates the best performance per column.
Sensitivity @ 60% Specificity (%)
Sensitivity @ 80% Specificity (%)
Method
B
C
B
C
No adaptation
81.0(73.5−88.2)
85.3(43.7−100.0)
67.1(56.1−76.5)
70.1(43.7−94.1)
MEMO ( Zhang et al., 2022 )
82.5(75.3−89.4)
85.2(64.7−100.0)
61.7(51.3−72.1)
74.5(50.0−95.6)
TENT ( Wang et al., 2020 )
80.4(72.7−87.5)
83.1(47.1−100.0)
66.4(57.8−75.4)
71.1(47.1−91.7)
EATA ( Niu et al., 2022 )
80.2(71.3−86.4)
89.5(49.2−100.0)
65.5(57.3−73.2)
63.2(44.6−88.5)
CoTTA ( Wang et al., 2022 )
80.0(72.0−87.3)
83.4(53.3−100.0)
65.8(55.8−75.5)
75.2(53.3−94.4)
Table 3: Sensitivity at fixed specificity (95% bootstrap CI) for all methods across both evaluation centres (B and C) at the core level for clinically significant prostate cancer (csPCa). Bold indicates the best performance per column.
PCa AUC (%)
csPCa AUC (%)
Dice Tertile
n
Dice Median (Range)
ANT
Baseline
ANT > Base
ANT
Baseline
ANT > Base
Low (≤0.72)
11
0.60(0.36−0.71)
80.0(29.6−100.0)
78.6(23.3−100.0)
4/11
100.0(78.1−100.0)
80.0(65.6−82.7)
3/3
Mid (0.72−0.90)
10
0.83(0.72−0.90)
68.3(6.2−100.0)
76.2(18.2−100.0)
3/10
63.6(50.0−95.8)
54.5(36.7−70.8)
5/5
High (>0.90)
11
0.95(0.91−0.99)
57.1(21.4−94.4)
44.0(21.4−96.3)
6/11
71.7(40.0−100.0)
65.7(23.1−100.0)
4/6
Overall
32
0.83(0.36−0.99)
-
-
13/32
-
-
12/14
Table 4: Per-patient AUC for ANT and the unadapted baseline stratified by MicroSegNet pseudo-mask Dice score tertile. Values reported as median (range). csPCa AUC is available only for patients with at least one positive and one negative core for clinically significant cancer.
Patient-Level csPCa AUC
Core-Level csPCa AUC
Core-Level PCa AUC
Method
Center B
Center C
Center B
Center C
Center B
Center C
PNF+ ( Wilson et al., 2026 )
71.2(66.8−75.6)
75.6(64.4−85.3)
72.4(68.2−76.5)
75.4(62.8−87.2)
69.8(66.6−73.1)
63.8(58.1−69.4)
PNF+ + ANT (ours)
72.8 (68.3 – 77.4)
80.5 (69.7 – 88.8)
73.9 (69.8 – 78.0)
78.2 (66.5 – 87.1)
∗ 73.1 (70.4 – 76.3)
65.2 (59.3 – 70.5)
Table 5: ANT applied to ProstNFound+ (PNF+), the current state-of-the-art model for micro-ultrasound prostate cancer detection. Results (AUC, % ) demonstrate model-independent generalization of the proposed TTA approach. Best results in bold.
Sensitivity @ 60% Specificity (%)
Sensitivity @ 80% Specificity (%)
Method
B
C
B
C
PNF+ ( Wilson et al., 2026 )
76.4(68.6−84.3)
72.3(50.0−92.9)
44.5(33.3−56.0)
58.4 (30.4 – 87.5)
PNF+ + ANT (ours)
78.9 (70.6 – 86.4)
85.5 (65.0 – 100.0)
46.0 (36.2 – 56.7)
56.0(30.8−77.8)
Table 6: Sensitivity at fixed specificity (95% bootstrap CI) for the unadapted ProstNFound baseline (PNF) and ANT across both evaluation centres (B and C) at the core level for clinically significant prostate cancer (csPCa).
Figure 2: Left: AUROC for clinically significant cancer prediction evaluated across increasing involvement thresholds (cores with true involvement ≥t or benign). Right: Distribution of activation leakage, defined as the ratio between average prostate heatmap activation and average needle-region activation, stratified by cancer status (benign vs PCa) and method, PNF+ (no TTA) vs. PNF+ + ANT. Lower values indicate better spatial specificity, i.e., reduced off-target activation outside the biopsy needle region.
Figure 3: Representative heatmaps of model activations without TTA (PNF+) and with TTA (PNF+ + ANT) on the same biopsy cores. Activations represent predicted involvement, with higher values indicating greater likelihood of clinically significant cancer. Each example is annotated with grade group (GG) and corresponding involvement percentage.
Update target
Position
Patient-Level (csPCa)
Core-Level (csPCa)
Core-Level (PCa)
Layer position and parameter type
Full blocks
First n
82.1
84.4
72.7
Full blocks
Middle n
79.8
81.9
73.6
Full blocks
Last n
77.2
80.8
72.7
Full blocks
All blocks
74.9
79.6
70.2
Norm only
First n
76.4
80.9
72.8
Table 7: Ablation on encoder update strategy and auxiliary task. Mean AUC ( % ) across held-out test centers. Best in bold.
Inner steps τ
Patient-Level (csPCa)
Core-Level (csPCa)
Core-Level (PCa)
0(w/o ANT)
78.5
81.5
72.7
2
76.0
81.1
72.6
5
78.9
83.4
72.5
10
82.1
84.4
72.7
20
78.2
78.0
72.0
Table 8: Ablation on number of TTA inner steps. Mean AUC ( % ) across held-out test centers. Best in bold.
Appendix figures & tables4 assets
Supplementary material from the paper’s appendix.
Appendix
Hyperparameter
Value
TTA learning rate ( ηTTT )
10−4
Encoder learning rate ( ηenc )
10−5
Inner steps ( τ )
10
Blocks to adapt ( n , DINOv3)
6
Blocks to adapt ( n , MedSAM)
3
Segmentation head hidden dim
256
Appendix
Table 9: Selected TTA hyperparameters.
Method
Time (s)
No adaptation
0.07±0.01
TENT
0.11±0.03
EATA
0.13±0.01
ROID
0.19±0.03
SAR
0.22±0.02
CoTTA
0.26±0.02
Appendix
Table 10: Mean wall-clock inference time per image (seconds ± std) on a single NVIDIA L40S GPU (48 GB). ANT includes τ=10 inner optimisation steps per image.
Patient-Level csPCa AUC (%)
Core-Level csPCa AUC (%)
Core-Level PCa AUC (%)
Ordering
B
C
B
C
B
C
Fixed order
79.9±0.03
84.1±0.08
81.1±0.02
88.0±0.06
73.1±0.03
72.3±0.03
Random order
80.0±0.04
82.3±0.03
80.6±0.04
85.8±0.08
72.9±0.01
72.0±0.05
Appendix
Table 11: Ordering sensitivity analysis. Mean AUC (%) ± std across five random seeds for fixed and randomly permuted test set orderings.
Subgroup (Involvement)
n
Baseline ECE (%)
ANT ECE (%)
Δ ECE (%)
Overall
1,118
7.6
2.7
−4.9
Low
161
29.7
32.0
+2.2
Mid
93
19.6
16.5
−3.0
High
131
14.3
13.8
−0.5
Appendix
Table 12: Calibration analysis on Center B ( n=1,118 cores). Expected Calibration Error (ECE) is reported for the unadapted baseline (PNF+) and ANT. Δ ECE = ANT ECE − Baseline ECE; negative values indicate improved calibration.