arXiv:2610.31889cs.LGOct 2026

Manuscript Offprint

arXiv:2610.31889

Scaling Transformer Energy-based Models For High Quality Image Synthesis

Jungsoo Lee, Alexi Gladstone, Yilun Du

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

ABSTRACT

Energy-Based Models (EBMs) are a flexible class of generative models that decouple probabilistic modeling from the generation process. This decoupling directly enables compositional generation and inference-time scaling, where sample quality can be refined simply by increasing sampling steps. However, severe challenges in high-dimensional sampling and training instabilities with deep architectures have restricted EBMs to low-dimensional regimes. To resolve these bottlenecks, we introduce the Transformer Energy-Based Model (TEM), a scalable transformer energy function operating entirely within a latent space. On top of this backbone, we extract energies at multiple layers and sum them, composing complementary constraints from local texture to global semantics. Furthermore, two components make this high-quality at scale: Positive Representation Alignment (PRA), which supervises TEM's intermediate representations with a vision foundation model, and advanced sampling strategies that improve sample quality at inference. TEM-XL achieves an FID-50K of 3.82 on class-conditional ImageNet 256×256 without classifier-free guidance, showing that a contrastive EBM can generate high-fidelity images. On ImageNet 512×512, TEM achieves an FID-50K of 8.24, demonstrating that the approach scales to higher resolution. We further validate the core promises of EBMs: compositional generation, zero-shot inpainting, and out-of-distribution detection.

1 INTRODUCTION

Energy-Based Models (EBMs) [9, 23] parameterize probability distributions via an energy function that assigns lower energies to more probable samples and higher energies to less probable samples. EBMs provide a flexible and mathematically elegant framework that fundamentally separates explicit generation from probabilistic modeling. Unlike Diffusion [18, 38] and Flow [24] models, which are mathematically constrained to pre-defined generative trajectories governed by carefully designed timestep schedules, EBMs define the data distribution solely through an energy function, entirely decoupling the model from the generative process. This decoupling of the model from the generative process yields profound advantages. First, EBMs decouple learning from inference, allowing the sampling procedure to be chosen independently of model training. This enables flexible test-time compute scaling by increasing the MCMC steps, progressively refining the samples through a deeper exploration of the learned energy landscape. Second, this flexibility enables the composition of different distributions together [9, 11], which can enable zero-shot generation and generalization capabilities.

However, despite their theoretical advantages and compositional properties, EBMs have struggled with widespread adoption due to several critical unresolved challenges. First, EBMs face severe vulnerability to the curse of dimensionality: MCMC sampling suffers from poor mixing in high-dimensional spaces, leading to slow convergence and mode collapse. Second, EBMs scale poorly with model capacity. As network depth increases, conventional architectures exhibit severe training instability, making robust optimization exceedingly difficult [9,10][9, 10]. Consequently, existing EBM

*bus6479@mit.edu

Figure

Figure

"zebra"

"beach"

composed result

Figure 1: High-fidelity ImageNet 256×256256 \times 256, 512×512512 \times 512 generation and compositional synthesis by TEM-XL/2. Left: uncurated class-conditional samples from 80 Langevin steps. The two large images are 512×512512 \times 512 samples and the remaining tiles are 256×256256 \times 256. Right: compositional generation by summing the energy functions of two independent classes, producing a coherent scene that satisfies both concepts without retraining.

research has been largely limited to smaller-scale benchmarks, unable to demonstrate competitive performance on challenging, high-resolution datasets.

In this work, we address these fundamental limitations and demonstrate that EBMs trained contrastively, with negatives drawn from the model's own MCMC sampler, can generate high-quality 256×256256 \times 256 ImageNet [6] samples through persistent sampling initialized solely from Gaussian noise, achieving performance competitive with strong generative models (Table 1). We further validate the core theoretical promises of EBMs by demonstrating compositional generalization as well as flexible inference-time control. Our work addresses the long-standing scalability bottleneck of contrastive EBMs, reestablishing them as a viable contender for high-fidelity image generation.

Our key contributions are: (1) A scalable Vision Transformer-based EBM architecture with multiple energy heads that enables stable training at high resolution. (2) A comprehensive training framework encompassing latent space design, representation alignment, and advanced sampling strategies that together achieve state-of-the-art quality images for contrastive energy-based models. (3) Empirical validation of the theoretical advantages of energy-based modeling at high resolution: compositional generation, zero-shot inpainting, and out-of-distribution detection from a single scalar energy.

References (48)