Diffusion models have become the leading approach to high-fidelity image and video generation, but their large memory footprint and long sampling latency make deployment costly. Quantizing both weights and activations to 4 bits (W4A4) substantially reduces both, but makes generation quality hard to preserve. At this aggressive precision, keeping a small high-precision low-rank branch to absorb outliers, as in SVDQ, has proven effective. Such methods, however, still fall short for two reasons: their calibration objective, the layer output error, fails to reflect the error in the network output of the denoising step (the step output error), and their bypass allocation primarily targets weight reconstruction rather than transmitted activation error. We propose KLI-Quant, a W4A4 post-training quantization framework for diffusion models that addresses both limitations. First, KLI-Quant weights the calibration objective by downstream sensitivity, estimated from a frozen full-precision model, so that the objective tracks the step output error rather than the layer output error. Second, it retains this low-rank bypass but regroups the deployed layer error into an activation term that depends on the bypass but not on residual quantization codes, and a weight term measured under quantized inputs. This grouping defines complementary targets for two-stage calibration, first allocating the bypass against activation error and then calibrating the residual weights under quantized inputs. We further provide efficient W4A4 kernels for the resulting two-branch layer. On MiniMax-H3, KLI-Quant achieves state-of-the-art video generation quality among the evaluated W4A4 methods, while achieving a $3.12\times$ average GEMM speedup and a $1.93\times$ end-to-end speedup over BF16.
翻译:暂无翻译