Back to all posts

D2PO: Training Diffusion Samplers by Preference

Image generators take pictures step by step, and most samplers are trained by regression - match the target, step after step. A new framework called D2PO throws that out and trains samplers by preference instead. The surprising part is where those preferences come from.

diffusion sampler optimizationDirect Preference Optimizationlow-NFE constraintsenergy-based modelstructural consistency
main thumbnail for D2PO: Training Diffusion Samplers by Preference
main thumbnail for D2PO: Training Diffusion Samplers by Preference
Reader Lens

Automation needs a narrow first win

The best first AI workflow is usually a repeated task with a clear input, clear output, and a human approval step.

Image generators produce pictures in a series of small steps - and the recipe that decides how those steps unfold is called a sampler. A new paper on arXiv proposes D2PO, or Dynamic Direct Preference Optimization, a framework that treats the question of how to build a better sampler not as a math regression problem but as a preference-alignment problem - the same family of technique that helped large language models learn from human taste.

Why Regression Isn't the Only Way to Build a Sampler

Most existing approaches to designing diffusion samplers work by regression: you train the sampler to match some target output, step by step, and hope closeness in numbers translates into quality in images. The D2PO paper reformulates this entirely. Instead of asking "did you match the target?" it asks "which of these outputs is better?" - and optimizes the sampler using Direct Preference Optimization (DPO), the method that lets models improve by comparing pairs of outcomes rather than replicating exact answers.

The technical move underneath this is modeling the sampling policy as an energy-based model (EBM), with the energy derived from pretrained score networks - networks already trained to understand how images should be structured. That gives the system something like an internal sense of what makes an image coherent, which it uses to judge preferences rather than just measure error.

inside paper visual for D2PO: Training Diffusion Samplers by Preference
main thumbnail for D2PO: Training Diffusion Samplers by Preference

Worth a look

Phugialy Picks

AI Engineering: Building Applications with Foundation Models
Amazon

AI Engineering: Building Applications with Foundation Models

A practical guide to building real-world applications with foundation models and LLMs.

GMKtec K15 AI Mini PC Oculink Intel Ultra 5 125U 32GB DDR5 512GB SSD | Desktop Computer AI Boost, 3X M.2 2280 Storage Expansion, Dual NIC...
Amazon

GMKtec K15 AI Mini PC Oculink Intel Ultra 5 125U 32GB DDR5 512GB SSD | Desktop Computer AI Boost, 3X M.2 2280 Storage Expansion, Dual NIC...

AI: Understand the Revolution: From Basics and Buzzwords to Tech Giants, Governments, and Your Future
Amazon

AI: Understand the Revolution: From Basics and Buzzwords to Tech Giants, Governments, and Your Future

Some Phugialy Picks use affiliate links. If you buy through one, Phugialy may earn a commission. It doesn't change what we recommend. Full disclosure →

The Two Details That Do the Real Work

Two pieces of this framework are easy to gloss over, but they're where most of the value lives.

First, the "dynamic" in Dynamic D2PO: preferences aren't fixed at the start. They progressively improve during learning, so as the sampler gets better, its sense of what counts as a good output sharpens too. Static preferences would freeze the teacher's judgment at day one; dynamic ones let it keep up with the student.

Second, preference evaluation happens in perturbed spaces - deliberately noisy versions of the outputs - which lets the method capture both structural consistency (does the overall composition hold together?) and fine-grained details (are small textures right?). Those are two different kinds of quality, and evaluating preferences under perturbation is what lets one signal address both.

The payoff: under low-NFE constraints - NFE meaning number of function evaluations, essentially how many expensive model calls you can afford - D2PO-trained student samplers outperform conventional regression-based schedulers. In plain terms: when you can only take a few steps, choosing each step by preference beats trying to regress your way there.

What This Actually Points To

Here's my read on why this matters more than it might first appear. The real story isn't "a new sampler beats an old one" - it's that preference-based alignment is migrating from language models into image generation's inner machinery. Most coverage treats DPO as a chatbot technique for matching human opinions. This paper applies it at a lower level: not to align what an image model says about taste, but to shape how it physically generates pixels at inference time.

That distinction matters because low-NFE settings are where efficiency and quality collide. Every step you cut from generation saves compute and latency, but regression-based methods tend to lose fine detail fastest in that regime. If preference-based optimization holds up there - as this paper reports - it suggests a broader shift: alignment-style training becoming a general-purpose tool for model behavior, not just for making models agreeable. My interpretation is that we'll see more papers borrowing alignment machinery for problems that were never framed as alignment problems at all; this one reframes sampling itself as "learning which outputs are preferred," and that reframing is arguably its most transferable idea.

Source and trust note

Built from source research and filtered through practical implementation judgment.

Reference: arxiv.org

Got a question about how this applies to you? →

Keep reading

Follow the thread