[Paper Review] Auto-ViT-Acc: An FPGA-Aware Automatic Acceleration Framework for Vision Transformer with Mixed-Scheme Quantization
This paper presents Auto-ViT-Acc, an FPGA-aware automated framework for accelerating Vision Transformers using mixed-scheme quantization (fixed-point and power-of-two). By jointly optimizing bit-widths and quantization scheme ratios via FPGA resource modeling, it achieves 5.6× higher frame rate (56.8 FPS) than a 32-bit baseline on DeiT-Base with only 0.71% accuracy drop, outperforming prior quantization methods in accuracy and throughput.
Vision transformers (ViTs) are emerging with significantly improved accuracy in computer vision tasks. However, their complex architecture and enormous computation/storage demand impose urgent needs for new hardware accelerator design methodology. This work proposes an FPGA-aware automatic ViT acceleration framework based on the proposed mixed-scheme quantization. To the best of our knowledge, this is the first FPGA-based ViT acceleration framework exploring model quantization. Compared with state-of-the-art ViT quantization work (algorithmic approach only without hardware acceleration), our quantization achieves 0.47% to 1.36% higher Top-1 accuracy under the same bit-width. Compared with the 32-bit floating-point baseline FPGA accelerator, our accelerator achieves around 5.6x improvement on the frame rate (i.e., 56.8 FPS vs. 10.0 FPS) with 0.71% accuracy drop on ImageNet dataset for DeiT-base.
Motivation & Objective
- To address the challenge of deploying Vision Transformers on resource-constrained FPGAs with high efficiency and accuracy.
- To investigate whether traditional CNN quantization schemes (fixed-point, PoT) are effective for ViTs and how to combine them optimally.
- To develop an automated, FPGA-aware workflow that co-optimizes quantization parameters and hardware resource utilization for target performance.
- To design a novel FPGA compute engine for ViT multi-head attention with hardware-aware optimizations.
- To demonstrate that mixed-scheme quantization can outperform pure fixed-point or PoT schemes in both accuracy and throughput on FPGAs.
Proposed method
- The framework uses FPGA resource utilization modeling to predict frame rate (FPS) based on bit-widths and mixing ratios of fixed-point and PoT quantization.
- It automates the search for optimal quantization configurations (bit-widths and PoT ratio) to meet a user-defined target FPS.
- A novel FPGA compute engine is designed for ViT multi-head attention, leveraging DSPs for fixed-point operations and LUTs for shift-based PoT operations.
- Mixed-scheme quantization is applied: weights are split into fixed-point and PoT components, with the ratio tuned to maximize resource utilization and accuracy.
- The framework integrates quantization, hardware modeling, and accelerator generation into an end-to-end pipeline driven by a target FPS.
- The entire workflow is automated, generating both a quantized ViT model and a corresponding FPGA accelerator.
Experimental results
Research questions
- RQ1Can traditional CNN quantization schemes (fixed-point and power-of-two) be effectively applied to Vision Transformers on FPGAs?
- RQ2How can mixed-scheme quantization (combining fixed-point and PoT) be systematically optimized for ViT inference on FPGAs to balance accuracy and throughput?
- RQ3What is the optimal combination of bit-widths and mixing ratios between fixed-point and PoT quantization for achieving target frame rates on FPGA?
- RQ4Can an automated, FPGA-aware framework co-optimize model quantization and hardware accelerator design for ViTs?
- RQ5Does mixed-scheme quantization outperform pure fixed-point or PoT quantization in terms of accuracy and inference speed on FPGA for ViTs?
Key findings
- For DeiT-small, the framework achieves 77.94% Top-1 accuracy at 150 FPS using W4A4 + W3A4 mixed quantization with 43% PoT ratio, outperforming a W8A8 model from prior work by 0.47% in accuracy.
- At 100 FPS, the framework achieves 78.74% Top-1 accuracy with W8A8 + W4A8 quantization and 43% PoT ratio, a 1.27% improvement over the prior work.
- For DeiT-base, the framework achieves 55 FPS with 81.14% Top-1 accuracy using W4A4 + W3A4 mixed quantization and 40% PoT ratio.
- At 33 FPS, DeiT-base achieves 81.84% Top-1 accuracy with W8A8 + W4A8 quantization and 45% PoT ratio, outperforming the W8A8 model from prior work by 0.66% in accuracy despite lower bit-width.
- Compared to a 32-bit floating-point baseline FPGA accelerator, the proposed accelerator achieves 5.6× higher frame rate (56.8 FPS vs. 10.0 FPS) on DeiT-base with only 0.71% accuracy drop.
- Even without quantization, the FPGA implementation on ZCU102 outperforms the Jetson TX2 GPU in both speed (10.0 FPS vs. 7.87 FPS for DeiT-base) and power efficiency (9.91W vs. 12.28W).
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.