Table of Contents
Fetching ...

StableQuant: Layer Adaptive Post-Training Quantization for Speech Foundation Models

Yeona Hong, Hyewon Han, Woo-jin Chung, Hong-Goo Kang

TL;DR

This paper tackles the challenge of post-training quantization for speech foundation models, whose CNN feature extractors and Transformer backbones create layer-wise activation distributions ill-suited to vanilla PTQ. It introduces StableQuant, a layer-wise adaptive calibration method that selectively clips outliers and searches per-layer scaling factors, differentiating treatment for CNN and Transformer layers. Empirical results on wav2vec2.0 and HuBERT-Large show that 8-bit quantization can preserve ASR performance with minimal WER degradation (<0.3%), while achieving roughly 4x model size reduction and near 2x faster inference. The approach yields competitive results relative to QAT and AdaRound, enabling efficient deployment of SFMs on hardware with limited resources, and the authors provide reproducible code.

Abstract

In this paper, we propose StableQuant, a novel adaptive post-training quantization (PTQ) algorithm for widely used speech foundation models (SFMs). While PTQ has been successfully employed for compressing large language models (LLMs) due to its ability to bypass additional fine-tuning, directly applying these techniques to SFMs may not yield optimal results, as SFMs utilize distinct network architecture for feature extraction. StableQuant demonstrates optimal quantization performance regardless of the network architecture type, as it adaptively determines the quantization range for each layer by analyzing both the scale distributions and overall performance. We evaluate our algorithm on two SFMs, HuBERT and wav2vec2.0, for an automatic speech recognition (ASR) task, and achieve superior performance compared to traditional PTQ methods. StableQuant successfully reduces the sizes of SFM models to a quarter and doubles the inference speed while limiting the word error rate (WER) performance drop to less than 0.3% with 8-bit quantization.

StableQuant: Layer Adaptive Post-Training Quantization for Speech Foundation Models

TL;DR

This paper tackles the challenge of post-training quantization for speech foundation models, whose CNN feature extractors and Transformer backbones create layer-wise activation distributions ill-suited to vanilla PTQ. It introduces StableQuant, a layer-wise adaptive calibration method that selectively clips outliers and searches per-layer scaling factors, differentiating treatment for CNN and Transformer layers. Empirical results on wav2vec2.0 and HuBERT-Large show that 8-bit quantization can preserve ASR performance with minimal WER degradation (<0.3%), while achieving roughly 4x model size reduction and near 2x faster inference. The approach yields competitive results relative to QAT and AdaRound, enabling efficient deployment of SFMs on hardware with limited resources, and the authors provide reproducible code.

Abstract

In this paper, we propose StableQuant, a novel adaptive post-training quantization (PTQ) algorithm for widely used speech foundation models (SFMs). While PTQ has been successfully employed for compressing large language models (LLMs) due to its ability to bypass additional fine-tuning, directly applying these techniques to SFMs may not yield optimal results, as SFMs utilize distinct network architecture for feature extraction. StableQuant demonstrates optimal quantization performance regardless of the network architecture type, as it adaptively determines the quantization range for each layer by analyzing both the scale distributions and overall performance. We evaluate our algorithm on two SFMs, HuBERT and wav2vec2.0, for an automatic speech recognition (ASR) task, and achieve superior performance compared to traditional PTQ methods. StableQuant successfully reduces the sizes of SFM models to a quarter and doubles the inference speed while limiting the word error rate (WER) performance drop to less than 0.3% with 8-bit quantization.

Paper Structure

This paper contains 12 sections, 1 equation, 2 figures, 3 tables, 2 algorithms.

Figures (2)

  • Figure 1: (a) Amplitude distribution of activations for each convolution layer in wav2vec2.0. (b) Amplitude distributions of activations in wav2vec2.0 and HuBERT. (c) Amplitude distributions of weights in wav2vec2.0 and HuBERT.
  • Figure 2: Inference speed of SFMs (ms) vs. Audio length (s)