NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

EfficientViT: Memory Efficient Vision Transformer with Cascaded Group Attention

Xinyu Liu, Houwen Peng, Ningxin Zheng, Yuqing Yang, Han Hu, Yixuan Yuan · DOI

Introduction

Vision Transformers (ViTs) have set new benchmarks in computer vision, yet their deployment in real-time applications remains challenging due to significant latency overheads. While existing research often focuses on reducing indirect metrics like FLOPs or parameter counts, these do not always translate to actual wall-clock speed. EfficientViT is designed to bridge this "speed gap" by optimizing for memory efficiency and reducing computational redundancy.

The Latency Bottleneck

The authors identify two primary sources of inefficiency in standard ViTs that hinder real-time performance:

  1. Memory-Bound Operations: Operations such as tensor reshaping, element-wise additions, and normalizations in Multi-Head Self-Attention (MHSA) are often limited by memory access speeds rather than raw computation. Even with low FLOP counts, these operations consume a disproportionate amount of execution time.
  2. Attention Redundancy: Standard MHSA often results in different attention heads learning highly similar projections, leading to wasted computational effort and reduced representational diversity.

Architecture and Methodology

To address these issues, EfficientViT introduces three core structural innovations:

Sandwich Layout Block

Standard ViT architectures typically alternate 1:1 between MHSA and Feed-Forward Network (FFN) layers. EfficientViT employs a "sandwich" layout, placing a single MHSA layer between multiple memory-efficient FFN layers. This configuration reduces the frequency of memory-intensive MHSA operations while enhancing inter-channel communication through the FFNs.

Cascaded Group Attention (CGA)

Instead of providing the full feature set to every attention head, CGA partitions input features across heads. These heads are then "cascaded," where the output of one head is added to the input of the subsequent head. This mechanism forces each head to learn unique, refined features, effectively eliminating redundancy and improving representational power.

Overview of the EfficientViT architecture, featuring the sandwich layout and Cascaded Group Attention (CGA).

Parameter Reallocation

Through Taylor structured pruning analysis, the researchers found that Query (Q) and Key (K) projections are less critical for performance than the Value (V) projection. Consequently, EfficientViT slims down Q and K projections while maintaining a larger V projection to preserve information. Additionally, the FFN expansion ratio was reduced from the standard 4.0 to 2.0 to further save memory.

Experimental Results

EfficientViT was trained and evaluated on ImageNet-1K for classification, COCO for object detection, and various transfer learning benchmarks (CIFAR, Flowers, etc.).

Accuracy vs. Throughput

EfficientViT consistently outperforms both optimized CNNs and previous efficient ViTs in terms of the accuracy-speed trade-off. For instance, EfficientViT-M5 achieves 77.1% Top-1 accuracy on ImageNet, outperforming MobileNetV3-Large by 1.9% while running over 40% faster on both GPU and CPU hardware.

Top-1 Accuracy vs. Throughput on ImageNet-1K. EfficientViT variants (M0-M5) significantly outperform existing efficient CNNs and ViTs.

Real-World Speed

The smallest variant, EfficientViT-M0, demonstrates extreme efficiency, processing over 27,000 images per second on an Nvidia V100 GPU. Compared to MobileViT-XXS, the M2 variant is 1.8% more accurate and runs 5.8x faster, proving that memory-centric design is vital for real-world performance.

Key Insights

  • FLOPs are Misleading: The study confirms that models with fewer FLOPs can be significantly slower if they rely heavily on memory-bound operations. Memory efficiency is more important than raw operation counts for real-world speed.
  • Diversity via Feature Splitting: Grouping features for attention heads, similar to group convolutions in CNNs, naturally prevents head redundancy and encourages learning diverse features.
  • Hardware-Friendly Activations: The choice of standard ReLU over more complex functions like GELU or HardSwish ensures better support and faster execution across diverse deployment platforms.

Conclusion and Future Work

EfficientViT proves that ViTs can be competitive with CNNs in real-time mobile applications by prioritizing memory efficiency. While the current architecture was manually designed based on pruning insights, future work could involve Neural Architecture Search (NAS) to further refine the "sandwich" structures. Additionally, exploring specialized local-feature extraction could enhance performance on fine-grained vision tasks.

Summary updated

BibTeX
@inproceedings{liu2023efficientvit,
  author = {Xinyu Liu and Houwen Peng and Ningxin Zheng and Yuqing Yang and Han Hu and Yixuan Yuan},
  title = {{EfficientViT: Memory Efficient Vision Transformer with Cascaded Group Attention}},
  booktitle = {IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  year = {2023},
  doi = {10.1109/cvpr52729.2023.01386},
}
Figure