atlas

Research map / Probabilistic and scientific modeling / Variational and generative sampling

Restructuring Vector Quantization with the Rotation Trick

ICLR 2025 · Probabilistic and scientific modeling › Variational and generative sampling · approach: Regularizing VAE latent information · 1 citations (OpenAlex)

Read the paperCheck your idea against 108,967 papers

AI-extracted summary. Written by AI from the paper's full text. Numbers and claims can be wrong or missing context, so check the paper before you cite or build on it.

Proposes the rotation trick, a gradient estimator for VQ-VAE quantization that transports gradients from the codebook vector to the encoder output via a detached rotation-and-rescaling, improving reconstruction, codebook usage, and quantization error across 11 VQ-VAE/VQGAN/ViT-VQGAN/TimeSformer settings.

Problem

Straight-through estimators for vector quantization in VQ-VAEs discard information about where the encoder output lies within its Voronoi cell, contributing to codebook collapse, low codebook utilization, and high quantization error.

Approach

Replace the straight-through pass-through with a linear map q̃ = (||q||/||e||) R e, where R is a rotation aligning e to q treated as constant in backprop, so the gradient at q is rotated to e while preserving the angle between gradient and codebook vector; this lets the location of e within its quantization region affect the encoder update (push points apart or pull them together).

Key results

Measured effects reported in the paper

What was changedWhereMeasuredEffect
replace STE with the rotation trickImageNet VQ-VAE, Euclidean, 32×32×32 · ImageNetr-FID: 106.1 -> 85.7Helped
replace STE with the rotation trickImageNet VQ-VAE, Euclidean, 64×64×3 · ImageNetr-FID: 19.0 -> 16.5Helped
replace STE with the rotation trickVQGAN, autoregressive · ImageNetr-FID: 7.3 -> 4.6Helped
replace STE with the rotation trickVQGAN, autoregressive · FFHQ & CelebA-HQcodebook usage: 27% -> 99%Helped
replace STE with the rotation trickVQGAN, latent diffusion, 32×32×4 · ImageNetr-FID: 5.0 -> 1.1Helped
replace STE with the rotation trickVQGAN, latent diffusion, 32×32×4 · ImageNetr-IS: 141.5 -> 200.2Helped
replace STE with the rotation trickViT-VQGAN · ImageNetr-FID: 29.2 -> 11.2Helped
replace STE with the rotation trickTimeSformer VQ-VAE · BAIR videor-FVD: 1661.1 -> 21.4Helped
replace STE with the rotation trickTimeSformer VQ-VAE · UCF-101 videor-FVD: 2878.1 -> 229.1Helped
replace norm scaling with the additive rotation formulation (ablation)VQ-VAE, Euclidean, 64×64×3 · ImageNetr-IS: 106.3 -> 106.1No clear effect
use norm scaling ||q||/||e|| rather than the additive rotation formulation (ablation)VQGAN, latent diffusion, 64×64×3, 8192 codes · ImageNetr-FID: 0.6 -> 0.46Helped
replace rotation with the reflection trick (ablation)VQGAN · ImageNet, latent diffusionvalidation loss: approximately 3x higherHurt

Surprising findings

Limitations

Experimental setup

Datasets: ImageNet FFHQ CelebA-HQ BAIR Robot UCF-101

Benchmarks: ImageNet validation reconstruction FFHQ & CelebA-HQ reconstruction BAIR video reconstruction UCF-101 video reconstruction

Metrics: r-FID r-IS codebook usage quantization error validation reconstruction loss r-FVD

Baselines: VQ-VAE (straight-through) Gumbel VQ-VAE Hessian approximation exact gradients (double forward pass) VQGAN ViT-VQGAN

Builds on: VQ-VAE VQGAN ViT-VQGAN straight-through estimator Gumbel-Softmax

Closest papers by meaning

Writing a paper in this area? scime draft is a free LaTeX editor with AI included, real-time co-authors and a check of your references and venue rules before you submit. It also imports OpenAI Prism projects.

Open scime draft

Get the next scime Dispatch and a monthly field update

Free. We send a confirmation link first; every email has a one-click unsubscribe. Privacy