paper-with-me

홈 › Papers

TerViT: An Efficient Ternary Vision Transformer

2022-01-20 · Sheng Xu, Yanjing Li, Teli Ma, Bohan Zeng, Baochang Zhang, Peng Gao, Jinhu Lv

Vision transformers (ViTs) have demonstrated great potential in various visual tasks, but suffer from expensive computational and memory cost problems when deployed on resource-constrained devices. In this paper, we introduce a ternary vision transformer (TerViT) to ternarize the weights in ViTs, which are challenged by the large loss surface gap between real-valued and ternary parameters. To address the issue, we introduce a progressive training scheme by first training 8-bit transformers and then TerViT, and achieve a better optimization than conventional methods. Furthermore, we introduce channel-wise ternarization, by partitioning each matrix to different channels, each of which is with an unique distribution and ternarization interval. We apply our methods to popular DeiT and Swin backbones, and extensive results show that we can achieve competitive performance. For example, TerViT can quantize Swin-S to 13.1MB model size while achieving above 79% Top-1 accuracy on ImageNet dataset.

📄 PDF Abstract BibTeX arXiv:2201.08050

Code (0)

등록된 구현이 없습니다.

Methods 이 논문이 사용한 방법론

Attention 설명 없음
Linear Layer A Linear Layer is a projection $\mathbf{XW + b}$.
Attention Dropout Attention Dropout is a type of dropout used in attention-based architectures, where elements are randomly dropped out of the…
Dropout Dropout is a regularization technique for neural networks that drops a unit (along with connections) at training time with a specified probability $p$ (a common value is…
Layer Normalization Unlike batch normalization, Layer Normalization directly estimates the normalization statistics from the summed inputs…
Softmax The Softmax output function transforms a previous layer's output into a vector of probabilities. It is commonly used for multiclass classification. Given an input vector $x$…
Residual Connection 설명 없음
Feedforward Network A Feedforward Network, or a Multilayer Perceptron (MLP), is a neural network with solely densely connected layers. This is the classic neural network architecture of the…

Similar Papers 제목 키워드 기반

FTerViT: Fully Ternary Vision Transformer

2026-05-20 · Szymon Ruciński, Pietro Bonazzi, Engin Türetken, Simon Narduzzi 외 arxiv

Ternary Vision Transformers offer substantial model compression, however state-of-the-art methods only ternarize the encoder layers, leaving patch embeddings, LayerNorm parameters, and classifier heads in full precision.…

Knowledge DistillationModel Compression

FasterViT: Fast Vision Transformers with Hierarchical Attention

2023-06-09 · Ali Hatamizadeh, Greg Heinrich, Hongxu Yin, Andrew Tao 외

We design a new family of hybrid CNN-ViT neural networks, named FasterViT, with a focus on high image throughput for computer vision (CV) applications. FasterViT combines the benefits of fast local representation learnin…

Image Classificationobject-detectionObject DetectionRepresentation Learning

TurboViT: Generating Fast Vision Transformers via Generative Architecture Search

2023-08-22 · Alexander Wong, Saad Abbasi, Saeejith Nair

Vision transformers have shown unprecedented levels of performance in tackling various visual perception tasks in recent years. However, the architectural and computational complexity of such network architectures have m…

Computational Efficiency

Enhancing COVID-19 Diagnosis through Vision Transformer-Based Analysis of Chest X-ray Images

2023-06-12 · Sultan Zavrak

The advent of 2019 Coronavirus (COVID-19) has engendered a momentous global health crisis, necessitating the identification of the ailment in individuals through diverse diagnostic modalities. Radiological imaging, parti…

Binary ClassificationClassificationCOVID-19 DiagnosisDiagnostic

Mechanistic Interpretability of Binary and Ternary Transformers

2024-05-27 · Jason Li

Recent research (arXiv:2310.11453, arXiv:2402.17764) has proposed binary and ternary transformer networks as a way to significantly reduce memory and improve inference speed in Large Language Models (LLMs) while maintain…