ScaleTok: How Should Latent Token Budgets Scale for Diffusion Transformers?
Abstract
A continuous visual tokenizer with aspect-aware positional embeddings decouples latent sequence length from the patch grid and shows that square-root visual budget allocation can preserve reconstruction and generation quality at reduced diffusion transformer cost.
Training generative vision models natively across multiple resolutions and aspect ratios is costly with standard patch-based tokenizers. The visual token count grows linearly with image area, while the cost of computing self-attention scores in a diffusion transformer (DiT) grows quadratically with token count. We introduce ScaleTok, a continuous visual tokenizer that decouples latent sequence length from the patch grid. Its Continuous Aspect-Aware Positional Embeddings (CAPE) crop a shared coordinate grid to each aspect ratio before interpolation, enabling us to compare fixed, square-root, and linear allocation while training a single tokenizer per configuration jointly across four ImageNet-1K geometries. To distinguish the capacity available inside the tokenizer from the visual budget passed to the generator, we vary the number of padded text positions while holding the class name and visual budget fixed. With a ViT-B/16 backbone, these additional positions improve reconstruction FID under fixed and square-root allocation at larger image sizes but worsen it under linear allocation, suggesting a register-like role when the visual budget is constrained. We show that the visual budget can grow with the square root of image area while retaining both reconstruction fidelity and generation quality. At 512x512 with 256 text-token positions, square-root allocation approaches linear reconstruction fidelity with half as many visual tokens and yields comparable generation FID at roughly half the estimated DiT-XL cost per denoising step.
Community
Higher-resolution images typically mean more visual tokens and more expensive diffusion transformers. ScaleTok studies how quickly that token budget actually needs to grow.
A controlled comparison across image geometries. Using Continuous Aspect-Aware Positional Embeddings (CAPE), ScaleTok compares fixed, square-root, and linear allocation, with each tokenizer configuration trained jointly across resolutions and aspect ratios.
Sublinear scaling offers a better quality–compute tradeoff. At 512 × 512, square-root allocation approaches linear reconstruction fidelity and achieves comparable generation FID using 512 instead of 1,024 visual tokens, with approximately 53% lower estimated DiT-XL FLOPs per denoising step.
Capacity inside the tokenizer matters too. Holding class-name content and visual budgets fixed, additional padded text positions improve larger-image reconstruction FID under fixed and square-root allocation, but worsen it under linear allocation. This suggests a register-like role when the visual budget is constrained.
Explore the project, interactive comparisons, and visual examples
Get this paper in your agent:
hf papers read 2612.06314 Don't have the latest CLI?
curl -LsSf https://hf.co/cli/install.sh | bash Models citing this paper 0
No model linking this paper
Datasets citing this paper 0
No dataset linking this paper
Spaces citing this paper 0
No Space linking this paper
Collections including this paper 0
No Collection including this paper