Manuscript Offprint
arXiv:2610.13012Learning Features, Not Layouts: Feature-Axis Attention as a Transfer Prior for Medical Imaging
Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.
Aon Safdar and Mohamed Saadeldin
University College Dublin, Ireland
aon.safdar@ucdconnect.ie, mohamed.saadeldin@ucd.ie
Abstract. Natural-image-pretrained foundation models are increasingly adapted to medical imaging, yet transfer remains unreliable under domain shift, modality heterogeneity, and label scarcity. We trace part of this fragility to an overlooked design choice. Standard vision transformers place all global modeling on self-attention over spatial tokens, an object-layout prior well suited to natural scenes but not to medical images, where the discriminative signal lies in feature correlations and texture that recur across scanners while layout does not. We ask whether the axis of global attention, spatial versus feature, is itself a lever for transferable medical representations. Existing channel-aware hybrids confound this question, adding channel attention to a spatially-mixed backbone and leaving the axes coupled and the feature axis unmeasurable in isolation. We design FAD-ViT, a backbone that strictly decouples the two axes, making feature-axis attention the primary global operator and the attention axis a controlled variable. Evaluating comprehensively across 23 classification, segmentation, and low-data tasks under matched tokenization, capacity, and protocol, we find that shifting global attention from the spatial to the feature axis leaves from-scratch performance essentially unchanged, yet markedly strengthens transfer. Identical ImageNet pretraining yields up to roughly three times the transfer gain, with consistent improvements on every held-out segmentation task at up to a quarter the parameter count and far lower compute than standard and channel-attention baselines. The advantage is largest where texture rather than geometry is discriminative, tracking greater reuse of pretrained features. The axis of global attention is thus a design lever for medical transfer, and making it channel-primary is a simple, cheap, and principled choice.
Keywords: Vision Transformers · Feature-Axis Attention · Medical Image Analysis · Transfer Learning
1 Introduction
Foundation-model pipelines increasingly dominate medical image analysis: a strong encoder pretrained on large-scale natural images is adapted to downstream clinical tasks . Despite advances in parameter-efficient adaptation
Code and configurations are available at https://github.com/aonsafdar/FAD-ViT.
A. Safdar and M. Saadeldin

Fig. 1: Overview of the studied block. Spatial Feature Extraction (SFE) preserves the 2D grid with depthwise convolution; Feature Self-Attention (FSA) transposes tokens and attends over feature tokens. Global interaction thus scales with width C rather than token count N.
and decoder design [9, 19], transfer remains inconsistent under domain shift, acquisition heterogeneity, limited supervision, and dense prediction [2]. Most transferred encoders inherit the standard vision transformer (ViT) [8], in which global modeling is dominated by self-attention over spatial tokens while feature/channel interaction is left to a mostly static feed-forward network. This bias suits natural-image pretraining, where object shape and layout are discriminative, but is less appropriate for medical transfer, where pathology often manifests as subtle feature correlations rather than dominant shape cues and exact spatial layout varies across devices, protocols, and anatomy.
The root of this mismatch is that spatial self-attention is asked to do two distinct jobs with one operator: extract local spatial structure and mix information globally. It is well matched to neither, carrying only a weak locality prior and costing in the token count. Hybrid and hierarchical backbones [16,22,23] add locality and efficiency but keep spatial attention as the primary global operator, and even channel-aware models that make the feature axis dynamic [7,10] graft it onto a pipeline still built for spatial mixing, changing only the mixing axis while inheriting spatial tokenization, projections, and locality modules. A different design separates the two jobs outright: extract with cheap depthwise convolution and mix globally with attention over channel tokens, so that each token summarizes the whole image and global interaction becomes an input-dependent reweighting of features at linear spatial cost. The consequences of this channel-primary design for medical transfer are unstudied, and are the subject of this paper: whether making global interaction channel-primary changes how well a backbone carries pretrained structure into heterogeneous medical domains, and if so, why.
What FAD-ViT is. FAD-ViT is not a spatial backbone with channel attention added as a branch; it is a strictly axis-decoupled, channel-primary backbone that separates the two conflated jobs onto purpose-matched operators. Depthwise convolution extracts local structure and keeps the 2D grid intact through depth, while single-head self-attention over channel tokens, each a feature-map descriptor summarizing the whole image, performs global mixing at cost, linear in the token count N, rather than the of spatial attention. Because even a pointwise projection mixes channels, Q/K/V are formed by depthwise-only projections, leaving channels unmixed before the attention that correlates them; this strict separation, which prior channel-aware models forgo (Sec. 2), is what lets us treat the global axis as an isolable variable. Channel-primary mixing is already global at linear spatial cost, so the design needs no windowing, local-interaction, dual-axis, or gating module, and defers a short spatial-attention tail to the lowest resolution where it is cheap.
Contribution and scope. Our contribution is a controlled account of why a strictly decoupled, channel-primary design is the right prior for medical transfer, and a characterization of how it behaves across modalities, tasks, and label budgets. Concretely:
– We show that strict axis decoupling with channel-primary mixing acts as a transfer prior for medical imaging: it converts natural-image pretraining into substantially larger downstream gains than a spatial-axis backbone of identical capacity, because pretraining on the channel axis deposits inter-feature correlations (texture, intensity, co-activation) that survive medical domain shift, whereas spatial-layout priors do not (Sec. 6).
– We characterize FAD-ViT across 23 medical tasks, classification, segmentation, and low-data probing, under one matched protocol, and against the coupled channel designs XCiT and DaViT, showing that the decoupled design transfers competitively or better at a fraction of their parameters (Secs. 5 and 5.3).
– We isolate the axis with matched from-scratch versus pretrained comparisons and representation-reuse analyses, well-posed only because the axes are cleanly separated here and not entangled as in prior channel-aware backbones (Secs. 6.2 and 6.3).
Channel-axis and dual-axis attention. Because attention is a content-adaptive mixing operator, it can mix channels rather than spatial tokens. Four design dimensions of a transformer stage are useful to separate: (i) tokenization, (ii) non-attention projections (locality modules and the MLP), (iii) attention projections (Q/K/V formation), and (iv) the mixing axis. XCiT [10] introduces cross-covariance attention over channels, so its primary mixer is already the
A. Safdar and M. Saadeldin
feature axis, yet it changes only dimension (iv), retaining single-scale tokenization (i), a depthwise local-patch-interaction module with pointwise MLP (ii), pointwise Q/K/V (iii), and a terminal spatial class-attention stage. DaViT [7] keeps spatial attention co-equal, alternating windowed spatial and grouped channel attention with pointwise Q/K/V. Later channel-aware backbones follow the same template, interleaving, fusing, or gating the two axes rather than separating them: SCAT [30], DCT-ViT [11], SCHEME [20], and asymmetric factorized bilinear operators [24] all enrich channel mixing inside an otherwise spatial pipeline. Since dimensions (i)–(iii) are inherited from spatial-attention baselines, spatial and feature interaction stay entangled: pointwise Q/K/V pre-mix channels before the feature attention, and spatial mixing recurs throughout. FAD-ViT instead co-designs all four dimensions around channel mixing: staged convolutional tokenization (i), depthwise spatial extraction with no channel mixing plus a pointwise MLP (ii), depthwise-only Q/K/V (iii), unlike the pointwise projections above and the depthwise-separable projections of CvT [23] that add redundant pre-attention channel mixing, and channel-primary global mixing with spatial attention confined to a short low-resolution tail (iv). It therefore needs none of the windowing [16], local-interaction [10], dual-axis [7], or gating machinery these models rely on, and is the only design in which no operator both extracts space and mixes channels. To our knowledge no prior hybrid or channel-aware backbone strictly decouples the two axes in this way: the channel-mixing projections or residual spatial attention they retain keep the axes entangled. Strict decoupling enables making the feature axis attributable; it lets us isolate feature-axis (channel) attention as the sole global operator under matched tokenization, capacity, and protocol, and characterize it as a transfer prior for medical imaging, an attribution the entangled designs above cannot support.
Transformers for medical imaging. Medical transformers commonly retain spatial attention as the primary global operator and add channel or dual-branch modules [5,21,29], sparsify attention [15], or fuse convolutional and transformer features [4,14] as secondary refinements; others swap spatial attention for cheaper global mixers [6,25]. We invert this hierarchy, making feature-axis attention the primary global operator, and evaluate it as a transfer prior rather than a task-specific module. A large self-supervised encoder (DINOv2 [17]) serves as a high-capacity baseline under the same protocol. We take XCiT and DaViT as the transfer comparators because they are the canonical representatives of the two channel-aware families, a pure channel-axis backbone and an interleaved dual-axis one, and provide public ImageNet weights; more recent channel-aware models refine these same two templates rather than decoupling the axes, so the comparison generalizes to them.
3 Method
3.1 Axis-Decoupled Block
FAD-ViT uses a three-stage convolutional-tokenization hierarchy but, unlike spatial and dual-axis backbones, assigns spatial extraction and global mixing to two purpose-matched, disjoint operators rather than folding both into spatial attention. At stage , let the feature map be , reshaped to tokens with . Each block applies the two decoupled operations below; for the controlled study we also form a spatial-axis counterpart by swapping only the global operator while holding tokenization, capacity, and schedule fixed.
Spatial Feature Extraction (SFE). A depthwise convolution refines local structure while preserving the spatial grid,
with stage-dependent kernel and stride. The convolution is depthwise by design, not for efficiency: because it applies an independent kernel per channel, all spatial mixing is confined to this branch and no channels are combined here, so spatial modeling is cleanly separated from feature modeling. Local spatial structure is thus routed by SFE and only by SFE, which keeps spatial contiguity for dense prediction and avoids premature spatial-feature entanglement.
Feature Self-Attention (FSA). Global interaction runs along the feature axis. Queries, keys, and values are produced by a depthwise projection that acts on each channel independently, so channels are never linearly combined before attention; the resulting affinity is therefore computed between unmixed channel identities, in contrast to the pointwise (channel-mixing) query/key/value projections of cross-covariance attention [10]. The tensor is then flattened and transposed from token layout to feature layout,
so that the channels become the tokens and the spatial positions become the feature dimension. Each channel token is thus the flattened response map of a single channel, i.e. a complete view of the image, so the full 2D layout is carried inside every token and is restored exactly when the output is transposed back; attention reweights whole-image channel responses and never collapses spatial structure. Single-head attention over this layout,
produces a feature-affinity map, in contrast to the token-affinity map of spatial attention. The map recombines the per-channel value maps, so each output token is a data-dependent reweighting of whole-image channel responses rather than of spatial locations. The result is transposed back to and updated with residual connection and feed-forward mixing. Because a feature token already aggregates the full spatial field, partitioning it across attention subspaces buys little and a single head suffices, as in the channel-token single-head attention of DaViT [7] and the single-head macro design of SHViT [28]; unlike DaViT's grouped variant we keep one global head over the full channel set.
A. Safdar and M. Saadeldin
Together SFE and FSA partition the two forms of interaction into disjoint operators: SFE mixes space but not channels, FSA mixes channels but does not collapse space, and no operator in the block does both. This clean separation is what makes the global axis a variable we can set and study in isolation.
3.2 Staged Backbone, Spatial Tail, and Complexity
The backbone stacks three stages with progressive downsampling and channel expansion , . The final stage appends an optional, lightweight spatial-attention tail (a few multi-head spatial-token blocks) on top of the feature-axis backbone. This tail is a minor refinement rather than a co-equal mixer; Sec. 6 shows that removing it costs only Dice, so feature-axis attention performs the overwhelming majority of global mixing and the backbone remains channel-primary by design.
The two axes have complementary cost. Spatial attention scales as , quadratic in the token count and therefore in input resolution; feature attention scales as , quadratic in width but only linear in . The feature-axis cost per position is thus fixed by architecture and independent of resolution, whereas the spatial-axis cost grows quadratically once tokens outnumber channels ( ). At the moderate token counts of this backbone ( at deep stages) the two are comparable in FLOPs; the feature axis's decisive advantage here is parametric: FAD-ViT reaches its transfer accuracy with 23.1M parameters against 90.5–90.6M for the ViT/DINOv2 decoders (Sec. 5), while its resolution-independent global cost avoids the spatial axis's blow-up at the high native resolutions common in medical acquisition. For segmentation we attach an identical U-Net decoder to the staged features across all encoders, so that any downstream difference is attributable to the encoder rather than the decoder.
4 Experimental Setup
Protocol. To isolate encoder representation quality we fix everything downstream: identical ImageNet-1K pretraining (except DINOv2, LVD-142M [17]), identical optimizer, schedule, augmentation, input resolution, and, for segmentation, an identical U-Net decoder across encoders (Fig. 2). This controls for pipeline effects so that differences reflect the backbone.
Datasets. We evaluate on 23 medical datasets/tasks: (i) classification on 10 MedMNIST-2D datasets [26] plus BUSI [1] and dataset B [27] breast ultrasound; (ii) segmentation on BUSI lesion and 10 MSD-derived 2D tasks [3]; (iii) low-data linear probing on 8 MedMNIST datasets at 1%, 10%, and 100% labels. For the MSD-derived 2D tasks the 70/15/15 split is made at the volume (patient) level before slicing, so all slices of a volume stay in one partition and no patient spans splits; BUSI is split at the image-mask-pair level.
Baselines. We compare against spatial-attention ViTs (ViT-S/16, ViT-B), convolutional ViT (CvT-13 [23]), a convolutional U-Net encoder (ResNet50), other

Fig. 2: Study design. Under a fixed protocol (convolutional tokenization, matched ~23M-parameter capacity, shared U-Net / linear-head decoders, identical schedule, and ImageNet-1K pretraining with a from-scratch control) we vary only the global-mixing operator across four backbone families: a spatial-axis baseline (ViT/DINOv2), two channel-hybrids (XCiT, DaViT), and the strictly decoupled feature axis. Transfer is evaluated on classification, segmentation, and low-data probing and attributed with transfer-gap, CKA, modality, and multi-seed analyses.
CNNs (VGG16), a state-space model (Vim-S), and a large self-supervised encoder (DINOv2-B/14 [17]). For the axis study specifically we compare feature-axis (ours) against a matched-capacity spatial ViT (ViT-S/16-UNet, 22.9M) and against the canonical channel-axis and dual-axis designs XCiT [10] and DaViT [7] within the same protocol.
Implementation. Classification models are fine-tuned end-to-end; segmentation encoders share a U-Net decoder and are fine-tuned; linear probing freezes the backbone and trains a linear head. Training uses AdamW with cosine scheduling and mixed precision; input is for classification and for segmentation. We report Accuracy/AUC (classification), Dice/mIoU/HD95 (segmentation), and linear-probe accuracy at each label fraction. Full preprocessing per modality (intensity windowing, resampling, normalization) and all hyperparameters are given in the supplementary material. All runs use fixed seeds and an H100/A100 GPU pool.
5 Results
5.1 Classification Transfer
Table 1 reports MedMNIST-2D transfer. On these small, mostly saturated classification benchmarks the three ImageNet-pretrained encoders are close: FAD-ViT is best or second-best on all ten datasets, but ViT-S/16 leads on several; we do
A. Safdar and M. Saadeldin
Table 1: MedMNIST-2D classification transfer (ImageNet-1K pretraining). Test Accuracy/AUC (%). Bold: best; underline: second.
| Dataset | CvT-13 | ViT-S/16 | FAD-ViT (feat-axis) | |||
|---|---|---|---|---|---|---|
| Acc | AUC | Acc | AUC | Acc | AUC | |
| PathMNIST | 98.50 | 99.90 | 99.00 | 99.90 | 99.40 | 99.90 |
| DermaMNIST | 73.77 | 91.32 | 76.50 | 93.00 | 77.20 | 90.70 |
| OCTMNIST | 91.36 | 97.27 | 94.39 | 98.42 | 93.44 | 98.30 |
| RetinaMNIST | 54.17 | 74.46 | 56.67 | 78.89 | 57.50 | 79.54 |
| BreastMNIST | 67.52 | 77.95 | 87.18 | 93.60 | 89.74 | 92.54 |
| BloodMNIST | 93.68 | 99.46 | 96.57 | 99.83 | 96.45 | 99.68 |
| TissueMNIST | 67.04 | 92.66 | 72.19 | 94.21 | 73.47 | 94.60 |
| OrganAMNIST | 98.55 | 99.97 | 99.81 | 99.99 | 99.31 | 100.00 |
| OrganCMNIST | 95.11 | 99.76 | 98.64 | 99.96 | 98.33 | 99.85 |
| OrganSMNIST | 83.87 | 98.83 | 91.46 | 99.34 | 93.31 | 99.46 |
Table 2: Breast-ultrasound transfer on BUSI and B (shared fine-tuning). Params in millions; Accuracy/AUC (%). Bold: best; underline: second.
| Encoder | Params (M) | BUSI | B | ||
|---|---|---|---|---|---|
| Acc | AUC | Acc | AUC | ||
| ResNet50 | 23.5 | 85.64 | 93.23 | 78.33 | 90.05 |
| VGG16 | 134.3 | 85.47 | 93.69 | 80.00 | 88.24 |
| ViT-S/16 | 21.7 | 86.50 | 93.60 | 82.50 | 90.68 |
| ViT-S/32 | 22.5 | 84.10 | 93.59 | 79.17 | 87.55 |
| CvT-13 | 20.1 | 75.50 | 88.90 | 75.22 | 89.17 |
| Vim-S/16 | 25.4 | 87.86 | 95.63 | 84.17 | 87.42 |
| DINOv2-B/14 | 85.7 | 86.84 | 94.23 | 84.01 | 89.42 |
| FAD-ViT (feat-axis) | 21.7 | 88.21 | 93.75 | 87.50 | 92.57 |
not read these narrow margins as the primary evidence, since the axis effect is clearest under dense prediction and the transfer-gap analysis (Sec. 6.2), where capacity is stressed and layout priors are put under domain shift. Table 2 reports breast-ultrasound transfer, a harder, texture-dominated target: FAD-ViT obtains the best accuracy on BUSI and B and best AUC on B. Notably it does so at or below the parameter count of the matched-capacity ViT-S/16 baseline, and matches or surpasses substantially larger encoders, including DINOv2-B/14 (evaluated at the same 224px as every model), rather than the comparison resting on any single large baseline.
5.2 Segmentation Transfer
Table 3 reports segmentation on the held-out test split (15% of each dataset, disjoint from the training and validation partitions used for epoch selection), with the matched U-Net decoder. Feature-axis FAD-ViT-UNet attains the best Dice on ten of the eleven tasks and the best mean (84.3 versus 79.8 for ViT-UNet and 77.4 for DINOv2-UNet); only the near-saturated colon CT task marginally favors DINOv2. The advantage is systematic rather than driven by a few tasks: a
(a) Segmentation transfer: per-task Dice (11 tasks)
(b) Breast-ultrasound classification

Fig. 3: Accuracy–efficiency trade-off under the matched transfer protocol. (a) Segmentation transfer: faint points are the 11 per-task Dice scores per encoder, large markers the mean; (b) BUSI classification accuracy versus parameters (log scale) across eight encoders spanning 20–134M. Feature-axis FAD-ViT (★) is Pareto-dominant in both, matching or exceeding encoders up to 6× larger (DINOv2-B, VGG16; all evaluated at the same 224px input) at a fraction of the parameters.
one-sided Wilcoxon signed-rank test over the eleven paired tasks rejects equality against ViT-UNet (11/11 wins, mean +4.4 Dice, 95% bootstrap CI [1.8, 8.8], ) and against DINOv2-UNet (10/11, +6.9, [3.3, 11.3], ). Boundary quality improves in tandem (lower HD95 on most tasks), indicating fewer outlier errors rather than only better overlap. The largest gains fall on texture-dominant, low-contrast targets, headed by breast ultrasound (+24.6 Dice over ViT-UNet, +20.7 with non-overlapping seed ranges over three seeds; Sec. 6.2), all at 23.1M parameters versus 90.5–90.6M for the ViT/DINOv2 decoders. Figure 3 shows the feature axis is Pareto-dominant on both segmentation and classification, while DINOv2 sits far to the right without a commensurate accuracy advantage under matched transfer.
Grouping the segmentation tasks by acquisition modality (Tab. 4) shows that the advantage is not uniform but tracks image content. The feature axis gains most on ultrasound (+24.6 Dice on this split, +20.7 over three seeds), a low-contrast, speckle- and texture-dominated modality, less on MRI (+2.8, four tasks), and least on high-contrast structural CT (+2.1, six tasks). The margin therefore grows precisely where discrimination depends on feature correlations rather than sharp geometry, consistent with the feature-axis hypothesis.
5.3 Channel-Primary Decoupling versus Coupled Channel Attention
Channel attention alone does not explain the transfer benefit; making it primary and strictly decoupled does. We transfer the two closest channel-aware designs, XCiT [10] and DaViT [7], under the identical U-Net protocol. In both the axes stay entangled (pointwise Q/K/V pre-mix channels; spatial mixing persists), so pretraining cannot be attributed to one axis; FAD-ViT, with depthwise-only Q/K/V and no auxiliary spatial modules, is the minimal design that removes this confound. All three channel-aware backbones beat the pure spatial-axis ViT-UNet on the held-out ultrasound test by +22 to +25 Dice (Tab. 5; extended to
A. Safdar and M. Saadeldin
Table 3: Segmentation transfer (256×256, matched U-Net decoder) on the held-out test split. Dice/mIoU (%) ↑; HD95 (px) ↓. Bold: best per task. †Near-saturated binary CT tasks (Lung, Colon) yield degenerate HD95 near zero for several models; see text. ‡Prostate has a small test set (n=77 slices) with high seed variance (std 15–18 Dice); we draw no task-level conclusion from it.
| Dataset | Model | Dice | mIoU | HD95 | Dataset | Model | Dice | mIoU | HD95 |
|---|---|---|---|---|---|---|---|---|---|
| BUSI | ViT-UNet | 53.1 | 43.9 | 47.7 | Lung | ViT-UNet | 95.9 | ||
| DINov2-UNet | 53.7 | 43.2 | 50.2 | DINov2-UNet | 96.0 | ||||
| FAD-ViT | 77.7 | 70.5 | 21.4 | FAD-ViT | 96.3 | 96.2 | 0.0 | ||
| Brain | ViT-UNet | 80.2 | 76.7 | 3.3 | Pancreas | ViT-UNet | 82.9 | 81.2 | 2.3 |
| DINov2-UNet | 77.4 | 74.0 | 3.9 | DINov2-UNet | 81.5 | 80.0 | 2.4 | ||
| FAD-ViT | 83.0 | 79.6 | 2.5 | FAD-ViT | 86.1 | 83.9 | 1.8 | ||
| Heart | ViT-UNet | 82.9 | 76.6 | 4.0 | Hepatic | ViT-UNet | 68.8 | 65.9 | 6.8 |
| DINov2-UNet | 77.8 | 71.1 | 4.3 | DINov2-UNet | 65.1 | 62.7 | 8.0 | ||
| FAD-ViT | 85.6 | 80.0 | 3.3 | FAD-ViT | 73.2 | 69.4 | 6.1 | ||
| Liver | ViT-UNet | 91.5 | 90.3 | 1.5 | Spleen | ViT-UNet | 94.3 | 92.8 | 1.1 |
| DINov2-UNet | 90.3 | 89.0 | 2.0 | DINov2-UNet | 89.5 | 87.6 | 1.5 | ||
| FAD-ViT | 92.9 | 91.8 | 1.4 | FAD-ViT | 96.9 | 95.8 | 0.5 | ||
| Hippo. | ViT-UNet | 86.5 | 81.5 | 5.4 | Colon | ViT-UNet | 88.6 | 88.5 | |
| DINov2-UNet | 86.4 | 81.4 | 5.7 | DINov2-UNet | 90.0 | ||||
| FAD-ViT | 87.1 | 82.2 | 5.5 | FAD-ViT | 89.5 | 89.3 | 0.4 | ||
| Prostate | ViT-UNet | 53.5 | 47.8 | 10.3 | Mean (11 tasks) | ViT-UNet | 79.8 | 76.5 | - |
| DINov2-UNet | 44.0 | 40.5 | 11.5 | DINov2-UNet | 77.4 | 74.1 | - | ||
| FAD-ViT | 58.8 | 53.5 | 9.3 | FAD-ViT | 84.3 | 81.1 | - |
Table 4: Segmentation transfer by modality (mean Dice %, matched U-Net decoder). The feature-axis gain over spatial-axis ViT is largest on texture-dominant, low-contrast ultrasound and smallest on high-contrast structural CT.
| Modality (#tasks) | ViT-UNet | DINov2-UNet | FAD-ViT | Δ vs ViT |
|---|---|---|---|---|
| Ultrasound (1) | 53.1 | 53.7 | 77.7 | +24.6 |
| MRI (4) | 75.8 | 71.4 | 78.6 | +2.8 |
| CT (6) | 87.0 | 85.4 | 89.1 | +2.1 |
all eleven tasks in the supplement), so feature-axis interaction drives the gain. The three are close (within 2.6 Dice) yet invert the natural-image ordering: XCiT and DaViT match or beat FAD-ViT on ADE20K but only tie it under medical transfer, where FAD-ViT reaches the strongest coupled design's accuracy (77.7 vs. 77.8 Dice) at the fewest parameters (23.1 vs. 27.1 and 34.4M). That FAD-ViT matches rather than beats these coupled designs supports our thesis: the benefit comes from the shared feature axis, not from any one architecture. FAD-ViT is simply its efficient, attributable endpoint, transferring at least as well as heavier coupled designs without their machinery.
5.4 Low-Data Linear Probing
Freezing the backbone and training only a linear head isolates the linear separability of the pretrained features at 1%, 10%, and 100% labels (Tab. 6). The result is dataset-dependent: the feature axis leads on PathMNIST, OCTMNIST,

Fig. 4: Qualitative segmentation transfer. Feature-axis FAD-ViT-UNet produces cleaner boundaries and fewer spurious regions than spatial-attention baselines; error maps (TP green, FP red, FN blue) concentrate residual error at ambiguous boundaries.
Table 5: Channel-primary decoupling versus coupled channel attention, matched U-Net decoder. Natural-image competence (ADE20K mIoU) versus medical transfer (held-out BUSI test Dice %). Coupled backbones (XCiT, DaViT) match or beat FAD-ViT on natural images but only tie it on medical transfer, which the decoupled design reaches at the lowest parameter count. Bold: best.
| Backbone | Global operator | Params (M) | Natural mIoU | Medical BUSI Dice |
|---|---|---|---|---|
| ViT-UNet | spatial-token only | 90.6 | 41.9 | 53.1 |
| XCiT-UNet | channel + spatial (columnar) | 27.1 | 43.9 | 75.1 |
| DaViT-UNet | channel/spatial interleaved | 34.4 | 42.8 | 77.8 |
| FAD-ViT-UNet | feature-axis only (decoupled) | 23.1 | 42.6 | 77.7 |
PneumoniaMNIST, and BloodMNIST, with the margin largest in the 1% regime where separability matters most, while DINOv2 and ViT-S/16 lead on a few others. Feature-axis pretraining thus yields more linearly separable medical features under scarce supervision on texture- and intensity-dominated targets, though not uniformly.
6 Analysis: Isolating the Attention Axis
6.1 Ablations
Table 7 ablates the two block-defining choices from scratch, removing pretraining and capacity as confounds (the feature- and spatial-axis backbones have iden-
A. Safdar and M. Saadeldin
Table 6: Low-data linear probing (frozen backbone). Test Accuracy (%) at 1/10/100% labels (single-seed; 3-seed means in Table S9). Bold: best per row and fraction.
| Dataset | FAD-ViT (feat-axis) | ViT-S/16 | DINOv2-B | ||||||
|---|---|---|---|---|---|---|---|---|---|
| 1% | 10% | 100% | 1% | 10% | 100% | 1% | 10% | 100% | |
| PathMNIST | 79.8 | 85.3 | 86.2 | 74.6 | 82.3 | 84.5 | 80.0 | 70.5 | 80.3 |
| DermaMNIST | 66.7 | 69.2 | 68.8 | 66.7 | 69.2 | 70.1 | 66.9 | 68.8 | 70.1 |
| OCTMNIST | 73.0 | 76.3 | 76.5 | 71.2 | 75.3 | 75.8 | 68.3 | 74.7 | 75.7 |
| PneumoniaMNIST | 87.1 | 88.7 | 89.1 | 71.2 | 81.0 | 80.5 | 74.4 | 89.4 | 89.6 |
| RetinaMNIST | 44.2 | 46.7 | 44.6 | 48.8 | 50.8 | 52.5 | 42.1 | 43.3 | 46.7 |
| BreastMNIST | 71.8 | 70.9 | 73.5 | 73.5 | 72.6 | 70.1 | 67.5 | 71.8 | 71.8 |
| BloodMNIST | 51.1 | 75.7 | 79.3 | 48.2 | 71.1 | 73.4 | 51.4 | 70.7 | 74.8 |
| OrganAMNIST | 72.0 | 84.0 | 85.6 | 62.9 | 80.7 | 82.4 | 72.9 | 86.7 | 88.2 |
Table 7: Medical ablation on BUSI and Heart, from-scratch Dice (%), matched decoder and schedule. is relative to the full model on the same task. From scratch the axis swap and the spatial tail each cost only 1–2 Dice at identical or lower capacity; the decisive axis effect appears under transfer (Tab. 8), not here. Bold: full model.
| Variant | BUSI Dice | Δ | Heart Dice | Δ |
|---|---|---|---|---|
| Full FAD-ViT (feat-axis, dw-Q/K/V, +tail) | 64.2 | - | 82.6 | - |
| → swap to spatial-axis attn. (23.1M) | 63.1 | -1.1 | 80.8 | -1.8 |
| → remove spatial tail (16.4M) | 63.1 | -1.1 | 81.3 | -1.3 |
tical 23.1M parameters; disabling the spatial tail gives 16.4M). From random initialization the axis swap costs only 1.1–1.8 Dice and removing the spatial tail 1.1–1.3 Dice, within from-scratch seed variance: absent pretraining, the feature axis is at most a marginal architectural advantage. This near-parity is the control that gives the transfer result its force, since the same axis that is neutral from scratch becomes decisive once pretrained (Sec. 6.2). The axis does not make the network intrinsically stronger; it makes the pretrained representation more transferable. We hold the operator parameterization fixed (single-head channel-token attention as in DaViT [7]/SHViT [28]; depthwise Q/K/V per the decoupling requirement, Sec. 3) so the axis is the only variable; BUSI and Heart bracket the two modality extremes (Tab. 4).
6.2 Transfer Specificity
A higher downstream score alone cannot separate a better architecture from a better transfer, nor either from raw capacity. We disentangle these by training backbones from both random initialization and ImageNet-1K pretraining and reading off the transfer gap, pretrained minus from-scratch Dice, on breast ultrasound (Tab. 8). To control the natural confound we match a spatial-axis ViT to FAD-ViT in parameters (ViT-S/16-UNet, 22.9 vs. 23.1M): over three seeds it converts pretraining into only +4.3 Dice against +15.1 for the feature axis, roughly a threefold difference. Scaling the spatial baseline to ViT-B (90.6M) or using a pretrained convolutional encoder (ResNet50-UNet, 71.7M) still yields far
Table 8: Transfer-specificity on breast ultrasound (held-out test Dice %): from scratch vs. ImageNet-1K pretraining, matched U-Net decoder and schedule. Gap = pretrained – scratch. Feature-axis, ViT-S, and ViT-B values are averaged over seeds (ViT-S over three); ResNet50 is single-seed.
| Backbone | Params (M) | Scratch | Pretrained | Gap |
|---|---|---|---|---|
| Feature-axis FAD-ViT | 23.1 | 61.3 | 76.4 | +15.1 |
| Spatial ViT-S (matched) | 22.9 | 48.9 | 53.2 | +4.3 |
| Spatial ViT-B | 90.6 | 49.9 | 55.7 | +5.7 |
| Convolutional ResNet50 | 71.7 | 61.7 | 67.7 | +6.0 |
Table 9: Cross-modality transfer gap under the strict in-place axis swap (identical 23.1M skeleton, only the global-mixing axis flipped). Held-out test Dice (%); Gap = pretrained – scratch. CT/MRI are multi-seed means (std ≤2.8); ultrasound reproduces the primary run (Tab. 8). The feature axis wins the gap on every modality, most on texture-dominated ultrasound.
| Modality (task) | Feature axis (ours) | Spatial axis | ||||
|---|---|---|---|---|---|---|
| Scratch | Pretr. | Gap | Scratch | Pretr. | Gap | |
| Ultrasound (BUSI) | 61.3 | 76.4 | +15.1 | 63.1 | 65.3 | +2.2 |
| CT (Spleen) | 90.6 | 95.3 | +4.7 | 91.1 | 94.3 | +3.2 |
| MRI (Heart) | 80.9 | 84.5 | +3.6 | 80.5 | 82.2 | +1.7 |
smaller gaps (+5.7, +6.0). At or below the capacity of every baseline the feature axis recovers two-to-threefold more of the pretrained representation on this target: the operator, not the parameter budget, governs what survives. Source-task quality does not account for this either: the backbones' ImageNet-1K top-1 accuracies are comparable (FAD-ViT 81.6, ViT-S/16 78.8, ViT-B 79.2), the small edge favouring the feature axis by only 2.5 points, far too little to produce 10–13 Dice transfer differences.
A single dataset cannot establish that the gap is a property of the operator rather than of BUSI. With the strict in-place axis swap (identical 23.1M skeleton, only the global-mixing axis flipped) we measure the same gap on one representative task per modality (Tab. 9): the feature axis converts ImageNet pretraining into a far larger gain than the spatial axis on texture-dominated ultrasound and retains a smaller but consistent edge on abdominal CT and cardiac MRI, also attaining higher absolute test Dice at matched capacity. The advantage thus tracks the modality trend of Tab. 4: largest where appearance and texture discriminate, shrinking without reversing where sharp geometry already fixes the boundary (matched-capacity results for all eleven tasks, and the completed axis-tail ablation, are in the supplement).
6.3 Why Feature-Axis Attention Transfers
The mechanism follows from what each axis pretrains. Feature-axis attention mixes channels globally, so pretraining shapes channel-correlation statistics, texture, intensity, and co-activation, that recur across scanners and anatomy; spatial-
A. Safdar and M. Saadeldin
(a) Layerwise feature reuse (BUSI)

(b) At matched capacity, feature axis transfers more

Fig. 5: Feature reuse tracks the transfer gap. (a) Linear CKA between the ImageNet-pretrained and from-scratch encoders on BUSI (higher = more reuse): the feature axis reuses more early/mid structure and specializes hardest late, whereas the spatial axis decays monotonically. (b) Their transfer gap (pretrained – scratch Dice): higher mid-level reuse coincides with a larger gain from identical pretraining.
token attention instead shapes object-layout priors specific to natural scenes and largely invalidated by medical domain shift. Centered kernel alignment (CKA) [13] between the pretrained and from-scratch encoders on BUSI is consistent with this (Fig. 5): feature-axis alignment stays higher at early and mid depth and collapses at the last stage, carrying over general channel structure while relearning only the task-specific top, whereas spatial-axis alignment decays monotonically, the profile of a weaker transfer prior. We read CKA as a corroborative correlate of the measured transfer gap, not direct proof of feature reuse. The same axis yields cleaner segmentation boundaries and fewer spurious components on texture-dominant targets (Fig. 4).
7 Conclusion and Future Work
We treated the axis of global attention as an experimental variable and introduced a strictly axis-decoupled backbone in which depthwise operators route all spatial structure and channel-token attention performs all global mixing. Moving global interaction from spatial to feature tokens converts identical ImageNet pretraining into several times larger downstream gains at matched capacity, outperforming spatial backbones across diverse segmentation tasks at a quarter of the parameters while reusing more pretrained early and mid-level structure, the signature of a transfer prior rather than a capacity effect. The gain is largest on low-contrast ultrasound and smaller but consistent on MRI and CT. Feature-centric global attention is thus a cheap, principled design choice for medical backbones; natural next steps are stronger pipelines (nnU-Net), other architecture families, and self-supervised pretraining.
Acknowledgements. This publication has emanated from research conducted with the financial support of Taighde Éireann – Research Ireland under Grant number 18/CRT/6183.
References
-
Al-Dhabyani, W., Gomaa, M., Khaled, H., Fahmy, A.: Dataset of breast ultrasound images. Data in Brief 28, 104863 (Feb 2020). https://doi.org/10.1016/j.dib.2019.104863
-
Ali, M.U., Zafar, A., Kim, S., Kim, K.S., Lee, S.W.: From task-specific to foundation models: A paradigm shift in medical vision-language analysis. Computer Science Review 59, 100831 (Feb 2026). https://doi.org/10.1016/j.cosrev.2025.100831
-
Antonelli, M., et al.: The Medical Segmentation Decathlon. Nature Communications 13(1), 4128 (Jul 2022). https://doi.org/10.1038/s41467-022-30695-9
-
Chen, R., He, S., Xie, J., Wang, T., Xu, Y., Fang, J., Zhao, X., Zhang, S., Wang, G., Lu, H., Yang, Z.: MedFuseNet: fusing local and global deep feature representations with hybrid attention mechanisms for medical image segmentation. Scientific Reports 15(1), 5093 (Feb 2025). https://doi.org/10.1038/s41598-025-89096-9
-
Chowdary, G.J., Yin, Z.: Med-Former: A Transformer Based Architecture for Medical Image Classification. In: Linguraru, M.G., Dou, Q., Feragen, A., Giannarou, S., Glocker, B., Lekadir, K., Schnabel, J.A. (eds.) Medical Image Computing and Computer Assisted Intervention – MICCAI 2024, vol. 15011, pp. 448–457. Springer Nature Switzerland, Cham (2024). https://doi.org/10.1007/978-3-031-72120-5_42
-
Dang, T.D.Q., Nguyen, H.H., Tiulpin, A.: LoG-VMamba: Local-global vision mamba for medical image segmentation. In: Asian Conference on Computer Vision (ACCV). pp. 548–565 (2024)
-
Ding, M., Xiao, B., Codella, N., Luo, P., Wang, J., Yuan, L.: DaViT: Dual Attention Vision Transformers. In: European Conference on Computer Vision (ECCV) (2022). https://doi.org/10.1007/978-3-031-20053-3_5
-
Dosovitskiy, A., Beyer, L., Kolesnikov, A., et al.: An image is worth words: Transformers for image recognition at scale. In: International Conference on Learning Representations (ICLR) (2021)
-
Dutta, K., Agarwal, D., Paulucci, D., Rai, A., Micsinai-Balan, M.: Parameter Efficient Fine-Tuning of Large Vision Foundational Models for Multi-Channel Medical Image Segmentation. In: Medical Imaging with Deep Learning (MIDL), Short Papers (2025)
-
El-Nouby, A., Touvron, H., Caron, M., Bojanowski, P., Douze, M., Joulin, A., Laptev, I., Neverova, N., Synnaeve, G., Verbeek, J., Jegou, H.: XCiT: Cross-covariance image transformers. In: Advances in Neural Information Processing Systems (NeurIPS) (2021)
-
Guan, Y., Wang, K.: Dynamic channel token vision transformer with linear computation complexity and multi-scale features. Neurocomputing 630, 129696 (2025)
-
Khan, A., Rauf, Z., Rehman Khan, A., Rathore, S., Hussain Khan, S., Saher Shah, N., Farooq, U., Asif, H., Asif, A., Zahoora, U., Ullah Khalil, R., Qamar, S., Hani Tayyab, U., Babar Khan, F., Majid, A., Gwak, J.: A Recent Survey of Vision Transformers for Medical Image Segmentation. IEEE Access 13, 191824–191849 (2025). https://doi.org/10.1109/ACCESS.2025.3618215
-
Kornblith, S., Norouzi, M., Lee, H., Hinton, G.: Similarity of neural network representations revisited. In: International Conference on Machine Learning (ICML) (2019)
-
Li, J., Xu, Q., He, X., Liu, Z., Zhang, D., Wang, R., Qu, R., Qiu, G.: CFFormer: Cross CNN-Transformer channel attention and spatial feature fusion for improved
A. Safdar and M. Saadeldin
segmentation of heterogeneous medical images. Expert Systems with Applications 295, 128835 (Jan 2026). https://doi.org/10.1016/j.eswa.2025.128835
-
Lin, X., Wang, Z., Yan, Z., Yu, L.: Revisiting Self-attention in Medical Transformers via Dependency Sparsification. In: Linguraru, M.G., Dou, Q., Feragen, A., Giannarou, S., Glocker, B., Lekadir, K., Schnabel, J.A. (eds.) Medical Image Computing and Computer Assisted Intervention – MICCAI 2024, vol. 15011, pp. 555–566. Springer Nature Switzerland, Cham (2024). https://doi.org/10.1007/978-3-031-72120-5_52
-
Liu, Z., Lin, Y., Cao, Y., Hu, H., Wei, Y., Zhang, Z., Lin, S., Guo, B.: Swin Transformer: Hierarchical Vision Transformer using Shifted Windows. In: 2021 IEEE/CVF International Conference on Computer Vision (ICCV). pp. 9992–10002. IEEE, Montreal, QC, Canada (Oct 2021). https://doi.org/10.1109/ICCV48922.2021.00986
-
Oquab, M., Darcet, T., Moutakanni, T., et al.: DINov2: Learning robust visual features without supervision. Transactions on Machine Learning Research (TMLR) (2024)
-
Qu, J., Han, X., Ai, J., Wu, J., Zhao, T., Xiao, T., Ning, S., Yang, Y., Qin, J., King, A.D., Chu, W.C.W., Cai, J., Ying, M.T.C.: Adapting Vision-Language Foundation Model for Next Generation Medical Ultrasound Image Analysis. Expert Systems with Applications 325, 132560 (2026). https://doi.org/10.1016/j.eswa.2026.132560
-
Ruffini, F., Ayllón, E.M., Shen, L., Soda, P., Guarrasi, V.: Benchmarking foundation models and parameter-efficient fine-tuning for prognosis prediction in medical imaging. Computer Methods and Programs in Biomedicine 275, 109196 (Feb 2026). https://doi.org/10.1016/j.cmpb.2025.109196
-
Sridhar, D., Li, Y., Vasconcelos, N.: SCHEME: Scalable channel mixer for vision transformers. arXiv preprint arXiv:2312.00412 (2024)
-
Wang, H., Yang, Z., Zhang, H., Zhao, D., Wei, B., Xu, Y.: FEAT: Full-Dimensional Efficient Attention Transformer for Medical Video Generation. In: Medical Image Computing and Computer Assisted Intervention (MICCAI). Lecture Notes in Computer Science, vol. 15968, pp. 267–277. Springer (2025)
-
Wang, W., Xie, E., Li, X., Fan, D.P., Song, K., Liang, D., Lu, T., Luo, P., Shao, L.: Pyramid Vision Transformer: A Versatile Backbone for Dense Prediction without Convolutions. In: 2021 IEEE/CVF International Conference on Computer Vision (ICCV). pp. 548–558. IEEE, Montreal, QC, Canada (Oct 2021). https://doi.org/10.1109/ICCV48922.2021.00061
-
Wu, H., Xiao, B., Codella, N., Liu, M., Dai, X., Yuan, L., Zhang, L.: CvT: Introducing Convolutions to Vision Transformers. In: 2021 IEEE/CVF International Conference on Computer Vision (ICCV). pp. 22–31. IEEE, Montreal, QC, Canada (Oct 2021). https://doi.org/10.1109/ICCV48922.2021.00009
-
Wu, J., Wang, Q., Xie, J., Zhu, P., Hu, Q.: Asymmetric factorized bilinear operation for vision transformer. In: International Conference on Learning Representations (ICLR) (2025)
-
Xie, B., Tang, H., Cai, D., Yan, Y.: MS-UMLP: Medical image segmentation via multi-scale u-shape mlp-mixer. In: Asian Conference on Computer Vision (ACCV). pp. 1793–1808 (2024)
-
Yang, J., Shi, R., Wei, D., Liu, Z., Zhao, L., Ke, B., Pfister, H., Ni, B.: MedMNIST v2 - A large-scale lightweight benchmark for 2D and 3D biomedical image classification. Scientific Data 10(1), 41 (Jan 2023). https://doi.org/10.1038/s41597-022-01721-8
-
Yap, M.H., Pons, G., Martí, J., Ganau, S., Sentís, M., Zwiggelaar, R., Davison, A.K., Martí, R.: Automated Breast Ultrasound Lesions Detection Using Convolutional Neural Networks. IEEE Journal of Biomedical and Health Informatics 22(4), 1218–1226 (Jul 2018). https://doi.org/10.1109/JBHI.2017.2731873
-
Yun, S., Ro, Y.: SHViT: Single-head vision transformer with memory efficient macro design. In: Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR) (2024)
-
Zhang, M., Zhang, Y., Liu, S., Han, Y., Cao, H., Qiao, B.: Dual-attention transformer-based hybrid network for multi-modal medical image segmentation. Scientific Reports 14(1), 25704 (Oct 2024). https://doi.org/10.1038/s41598-024-76234-y
-
Zheng, J., Yang, L., Li, Y., Yang, K., Wang, Z., Zhou, J.: Lightweight vision transformer with spatial and channel enhanced self-attention. In: IEEE/CVF International Conference on Computer Vision Workshops (ICCVW) (2023)