WACV 2027

ComposeAnything

Composite Object Priors for Text-to-Image Generation
Inria, École normale supérieure, CNRS, PSL Research University
Editable 2.5D object prior
A collage that fixes each object's appearance, position, size and depth order before generation starts.
Prior-guided diffusion
Object Prior Reinforcement keeps the objects; Spatial-Controlled Denoising ties each region to its own caption.
Inference time only
No retraining. Works on top of SD3-M, SDXL and FLUX.
FLUX, RPG, Flow-GRPO and ComposeAnything on 'A chicken behind a clock' and 'Three bears, two girls, three chickens, one chair and two cups'

ComposeAnything vs. FLUX, RPG and Flow-GRPO.

Abstract

Layout-based compositional methods improve text-to-image generation by specifying where objects should appear, but most rely on sparse 2D constraints with limited appearance, occlusion, and depth-aware cues. We show that compositional generation can be substantially improved by replacing purely geometric guidance with an editable visual prior for diffusion initialization. We introduce ComposeAnything, an inference-time framework built around a 2.5D Composite Object Prior, an editable RGB image that specifies object appearance, layout, scale, and depth-aware ordering. We transfer this prior through Prior-Guided Diffusion, which combines Object Prior Reinforcement (OPR) to preserve object structure and appearance with Spatial-Controlled Denoising (SCD) to improve region-text alignment and reduce semantic leakage. Early guidance preserves the prior structure, after which standard denoising refines the image coherently. Extensive evaluations on T2I-CompBench, NSR-1K, and GenEval show strong gains in spatial reasoning, 3D-spatial relations, counting, and surreal compositions while maintaining visual quality and efficiency.

How It Works

Overview

From prompt to image in three steps

ComposeAnything framework: 2.5D layout planning, composite object prior, prior-guided diffusion
1

2.5D layout planning

An LLM writes a caption, box and depth for every object, plus background and global captions.

2

Composite object prior

Each object is generated alone, cut out, resized to its box and pasted back to front into a collage.

3

Prior-guided diffusion

Generation starts from the noised collage: guided early steps, then normal denoising.

Prior-guided diffusion

Two kinds of guidance in the early steps

Prior-guided diffusion: spatial-controlled denoising (left) and object prior reinforcement (right)

Object Prior Reinforcement (OPR) · right

Resets the object regions to the noised prior after every step until tp, keeping their appearance and depth order.

Spatial-Controlled Denoising (SCD) · left

Denoises each region with its own caption, next to a global branch with the full prompt, until tsc.

Lower tp, tsc = stronger guidance. Defaults: tp = 0.91, tsc = 0.96, 28 steps.

What the Prior Does

Robustness

A guide, not a template

The prior acts only in the early steps, so the model fixes what the collage gets wrong. Left: prior, right: final.

Four prior and final image pairs: cyclist with cars, hikers at a campfire, clown in a cable car, girls petting goats
Bicycle addedcars move behind the rider, with shadows
Firelight addedthe fire lights up the faces
Clown placedmoved inside the cable car
Natural posesthe girls now pet the goats
26% of priors were judged wrong, yet 63% of those still gave a correct image.
Guidance strength

How strongly to follow the prior

tp (OPR) and tsc (SCD) set the strength; lower means stronger.

SD3-M baseline, the object prior, and three guidance strengths for 'two apples, one bag, two dogs, four clocks and three microwaves'
SD3-Mmisses objects
Object priorthe LLM's collage
Too weaklayout drifts, counts wrong
Defaultevery object; the blue box becomes the 4th clock
Too strongprior copied, the box stays a box
2.5D prior

Depth order for 3D relations

2D layouts cannot say which object is in front; our prior is pasted back to front.

'A chicken behind a clock' with RPG region layout, CreatiLayout 2D boxes, an incorrectly layered 2.5D prior and a correctly layered 2.5D prior
RPGside by side
CreatiLayoutchicken in front
Wrong layeringchicken in front
Correct layeringchicken behind the clock
Editing

Fix the prior by hand

The prior is a picture, so a person can correct it before generating.

LLM-generated prior, incorrect generation, edited prior and correct generation for 'A turtle behind a bowl' and 'four drums, three cakes, three dogs and two helmets'
Top: turtlemoved behind the bowl
Bottom: drumsdogs resized, cakes moved to the front, OPR and SCD slightly stronger
Editing 48 failed 3D-spatial priors raises the 3D-spatial score from 77.16 to 94.27.

Results

T2I-CompBench and NSR-1K

Best on 2D/3D-spatial, counting and complex prompts, and on NSR-1K.

Method T2I-CompBench NSR-1K
2D-SpatialCount3D-SpatialComplexColorTexture SpatialCount
SD-v112.4644.61–30.8037.6541.5616.8931.45
Attend-Excite v214.5547.67–34.0164.0059.6326.8639.41
SDXL21.3349.8847.1232.3758.7952.9931.5730.62
PixArt-α20.8250.5838.6233.57*68.8670.44––
RealCompo31.7365.92–31.27*77.4174.27––
SD3-M31.3260.2249.4337.7181.3273.3444.4344.61
FLUX26.1360.5859.5137.0374.0769.2239.2955.97
RPG*40.2656.3950.9336.5376.8061.9552.2439.81
RAGD*42.5657.3862.4236.6880.3970.85––
Inference-scale31.5167.89–38.1083.0373.64––
ComposeAnything48.2468.2177.1638.6681.1173.7463.8059.36

Inference-based methods. * reproduced.

GenEval

Best overall, and 7–18× faster than Reflect-DiT and InstanceGen.

MethodSingle obj.Two obj.CountColorPositionAttributeOverall ↑Time (s) ↓
SD3-M0.990.840.560.840.320.520.684.0
RPG*0.990.820.430.760.630.640.7115.49
CARINOX1.000.860.660.900.160.480.6870.0
Reflect-DiT0.980.960.800.880.660.600.81118.0
InstanceGen0.970.870.680.850.640.730.79300.0
ComposeAnything1.000.930.700.850.830.720.8416.37

* reproduced. Time: seconds per image.

Qualitative comparison

SD3-M, RPG, CreatiLayout, Flow-GRPO and ComposeAnything on four counting, 2D-spatial and 3D-spatial prompts

Counting, 2D- and 3D-spatial prompts, against inference-only and training-based methods.

BibTeX

@inproceedings{khan2027composeanything,
  title     = {ComposeAnything: Composite Object Priors for Text-to-Image Generation},
  author    = {Khan, Zeeshan and Chen, Shizhe and Schmid, Cordelia},
  booktitle = {Proceedings of the IEEE/CVF Winter Conference on Applications of Computer Vision (WACV)},
  year      = {2027}
}

Acknowledgements

This work was granted access to the HPC resources of IDRIS under the allocation AD011014688R1 made by GENCI. It was funded in part by the French government under management of Agence Nationale de la Recherche as part of the “France 2030” program, reference ANR-23-IACL-0008 (PR[AI]RIE-PSAI projet), and Paris Île-de-France Région in the frame of the DIM AI4IDF. Cordelia Schmid would like to acknowledge the support by the Körber European Science Prize.

Copyright

The documents contained in these directories are included by the contributing authors as a means to ensure timely dissemination of scholarly and technical work on a non-commercial basis. Copyright and all rights therein are maintained by the authors or by other copyright holders, notwithstanding that they have offered their works here electronically. It is understood that all persons copying this information will adhere to the terms and constraints invoked by each author's copyright.