# DiRotQ: Rotation-Aware Quantization for 4-bit Diffusion Transformers

*Sayeh Sharify, Mahsa Salmani, Hesham Mostafa*

[NeurIPS page](https://neurips.cc/virtual/2026/poster/155781) · [Open on the map](../papers.html#p155781)

Category: [Efficient LLM Inference & Training](../pcat/14.md) › [Low-bit Post-Training Quantization](../pgroup/507.md) · Type: new method · Keywords: diffusion transformers, post-training quantization, PCA, activation quantization, image generation, efficient inference

Areas: [Code & Coding Agents](../areas/codegen.md) › Code Generation and Optimization › Model Quantization

## Summary
DiRotQ is a rotation-aware post-training quantization framework that uses PCA to preserve dominant activation variance, quantizes the rest to 4-bit, and achieves high-quality image generation while drastically reducing memory and computation.

## Explained to a 5-year-old
A big computer program draws pictures using many tiny steps. To make the program fit on a smaller computer, we cut most of those steps down to just four bits. This makes the pictures blurry, so we find the most important steps and keep them clear, while the rest we make very small. We also rotate the steps so the important parts stay bright. This helps the program still draw nice pictures, uses less memory, and runs faster.

## Explained to a 5-year-old, longer
The program that creates pictures is called a diffusion transformer, and it works like a very detailed recipe. When we want to use this recipe on a small device, we need to shrink the recipe because the original is too big. Shrinking everything makes the pictures look fuzzy. To fix this, we look at the recipe and find the most important actions that change the picture. We keep those actions at full detail, while the less important actions we shrink down to just four bits. We also rotate the order of the actions so the important ones stay in the right place. This way the picture stays clear, the program uses much less memory, and it can run faster on a regular computer. The new method also adds a special judge that checks if the pictures match the words we describe, making sure the shrunken version still understands the description. Finally, we create a fast piece of code that helps the program run even quicker, so even a big model like FLUX.1-dev can fit on a modest graphics card.

## For a technical reader
The method identifies a low-rank subspace of activation variance via PCA, rotates activations into this subspace at inference, preserves subspace coefficients at higher precision, and quantizes the rest to 4-bit, with the inverse rotation fused into layer weights. It combines this with GPTQ weight quantization to achieve W4A4 post-training quantization. Evaluation on PixArt-Σ over MJHQ-30K yields FID 15.9 and PSNR 19.1 dB, surpassing SVDQuant. A Triton custom kernel reduces memory usage of the 12B FLUX.1-dev model by 2.1× and provides 2.3× speedup over BF16 on a 24GB RTX 4090 GPU.

## Problem
Quantizing diffusion transformers to 4-bit precision typically causes severe quality loss, leaving a noticeable gap to full-precision performance. Existing quantization methods only partially mitigate this degradation, making efficient inference challenging.

## Method
The approach uses PCA to find a low-rank subspace that captures dominant activation variance, preserves coefficients in this subspace at higher precision while quantizing the remaining components to 4-bit, and rotates activations into the PCA basis at inference using calibration-derived orthogonal transformations with the inverse rotation fused into layer weights. It also applies GPTQ-based weight quantization to complete the W4A4 post-training quantization pipeline.

## Results
The approach achieves an FID of 15.9 and PSNR of 19.1 dB on PixArt-Σ over MJHQ-30K, beating the prior state-of-the-art SVDQuant (FID 18.9, PSNR 17.6). It also reduces memory usage of the 12B FLUX.1-dev model by 2.1× and provides a 2.3× speedup over BF16 on a 24GB RTX 4090 GPU.

## Contributions
The paper introduces a rotation-aware activation quantization scheme that leverages PCA to preserve dominant activation variance, a VLM-as-a-Judge evaluation protocol for diffusion model quantization, and a Triton-based custom kernel for efficient inference, demonstrating significant memory savings and speedups on a large diffusion model.

## Practical relevance
The work enables practical deployment of large diffusion models on consumer-grade GPUs by drastically reducing memory footprint and accelerating inference while preserving image quality.

## Research questions this paper is counted under

- [How can diffusion transformers be quantized to low-bit precision while maintaining output quality?](../q/243.md)

This page was written by language models from the title and abstract of each paper, and the answers were checked by two other models. It can be wrong: check the paper itself. [Suggest a correction](../feedback/?on=p/155781)
