paper-with-me

Papers

BinaryViT: Pushing Binary Vision Transformers Towards Convolutional Models

2023-06-29 · Phuoc-Hoan Charles Le, Xinlin Li

With the increasing popularity and the increasing size of vision transformers (ViTs), there has been an increasing interest in making them more efficient and less computationally costly for deployment on edge devices with limited computing resources. Binarization can be used to help reduce the size of ViT models and their computational cost significantly, using popcount operations when the weights and the activations are in binary. However, ViTs suffer a larger performance drop when directly applying convolutional neural network (CNN) binarization methods or existing binarization methods to binarize ViTs compared to CNNs on datasets with a large number of classes such as ImageNet-1k. With extensive analysis, we find that binary vanilla ViTs such as DeiT miss out on a lot of key architectural properties that CNNs have that allow binary CNNs to have much higher representational capability than binary vanilla ViT. Therefore, we propose BinaryViT, in which inspired by the CNN architecture, we include operations from the CNN architecture into a pure ViT architecture to enrich the representational capability of a binary ViT without introducing convolutions. These include an average pooling layer instead of a token pooling layer, a block that contains multiple average pooling branches, an affine transformation right before the addition of each main residual connection, and a pyramid structure. Experimental results on the ImageNet-1k dataset show the effectiveness of these operations that allow a binary pure ViT model to be competitive with previous state-of-the-art (SOTA) binary CNN models.

📄 PDF Abstract BibTeX arXiv:2306.16678

Code (1)

phuoc-hoan-le/binaryvit 공식 구현 pytorch

Tasks

BinarizationImage ClassificationStochastic Optimization

Methods 이 논문이 사용한 방법론

Attention 설명 없음
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$…
Linear Layer A Linear Layer is a projection $\mathbf{XW + b}$.
Multi-Head Attention 설명 없음
Dense Connections Dense Connections, or Fully Connected Connections, are a type of layer in a deep neural network that use a linear operation where every input is connected to every output…
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…
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…
Average Pooling 설명 없음

Similar Papers 제목 키워드 기반

BinaryViT: Towards Efficient and Accurate Binary Vision Transformers

2023-05-24 · Junrui Xiao, Zhikai Li, Lianwei Yang, Qingyi Gu

Vision Transformers (ViTs) have emerged as the fundamental architecture for most computer vision fields, but the considerable memory and computation costs hinders their application on resource-limited devices. As one of …

BinarizationQuantization

BinaryAttention: One-Bit QK-Attention for Vision and Diffusion Transformers

2026-03-10 · Chaodong Xiao, Zhengqiang Zhang, Lei Zhang arxiv

Transformers have achieved widespread and remarkable success, while the computational complexity of their attention modules remains a major bottleneck for vision tasks. Existing methods mainly employ 8-bit or 4-bit quant…

Should we Replace CNNs with Transformers for Medical Images?

2021-09-29 · Christos Matsoukas, Johan Fredin Haslum, Moein Sorkhei, Magnus Soderberg 외

Convolutional Neural Networks (CNNs) have reigned for a decade as the de facto approach to automated medical image diagnosis, pushing the state-of-the-art in classification, detection and segmentation tasks. Recently, vi…

Segmentation

Pretrained ViTs Yield Versatile Representations For Medical Images

2023-03-13 · Christos Matsoukas, Johan Fredin Haslum, Moein Sorkhei, Magnus Söderberg 외

Convolutional Neural Networks (CNNs) have reigned for a decade as the de facto approach to automated medical image diagnosis, pushing the state-of-the-art in classification, detection and segmentation tasks. Over the las…

image-classificationImage ClassificationMedical Image Classification

BiViT: Extremely Compressed Binary Vision Transformers

2023-01-01 · ICCV 2023 1 · Yefei He, Zhenyu Lou, Luoming Zhang, Jing Liu 외

Model binarization can significantly compress model size, reduce energy consumption, and accelerate inference through efficient bit-wise operations. Although binarizing convolutional neural networks have been extensi…

Binarizationobject-detectionObject Detection