CAViT -- Channel-Aware Vision Transformer for Dynamic Feature Fusion
Aon Safdar, Mohamed Saadeldin
TL;DR
This paper tackles the rigidity of static channel mixing in Vision Transformers by introducing a dual-attention block called CAViT. It replaces the fixed MLP with a channel-wise attention stage learned via a dimension-swapping mechanism that treats channels as tokens, enabling dynamic inter-channel interactions conditioned on global context. Across five natural and medical imaging datasets, CAViT achieves up to +3.6% accuracy while reducing parameters and FLOPs by over 30% compared to ViT baselines, with qualitative attention maps showing sharper, semantically meaningful focus. This work demonstrates that unified, attention-based token mixing can boost representational power without increasing depth, suggesting a scalable path for efficient vision transformers.
Abstract
Vision Transformers (ViTs) have demonstrated strong performance across a range of computer vision tasks by modeling long-range spatial interactions via self-attention. However, channel-wise mixing in ViTs remains static, relying on fixed multilayer perceptrons (MLPs) that lack adaptability to input content. We introduce 'CAViT', a dual-attention architecture that replaces the static MLP with a dynamic, attention-based mechanism for feature interaction. Each Transformer block in CAViT performs spatial self-attention followed by channel-wise self-attention, allowing the model to dynamically recalibrate feature representations based on global image context. This unified and content-aware token mixing strategy enhances representational expressiveness without increasing depth or complexity. We validate CAViT across five benchmark datasets spanning both natural and medical domains, where it outperforms the standard ViT baseline by up to +3.6% in accuracy, while reducing parameter count and FLOPs by over 30%. Qualitative attention maps reveal sharper and semantically meaningful activation patterns, validating the effectiveness of our attention-driven token mixing.
