NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

LAW-Diffusion: Complex Scene Generation by Diffusion with Layouts

Binbin Yang, Yi Luo, Ziliang Chen, Guangrun Wang, Xiaodan Liang, Liang Lin

Abstract

Generating complex scenes with multiple interacting objects remains a significant challenge for text-to-image models. While layout-to-image (L2I) synthesis offers a solution by providing spatial constraints, existing methods often fail to capture the intricate dependencies between objects. This paper introduces LAW-Diffusion (Layout-AWare Diffusion), a framework designed to model spatial relationships explicitly. By utilizing a Spatial Dependency Parser and an Adaptive Guidance Schedule, LAW-Diffusion achieves superior image quality and semantic accuracy, setting new benchmarks on COCO-Stuff and Visual Genome datasets.

1. Introduction

State-of-the-art text-to-image (T2I) models, such as Stable Diffusion, have demonstrated remarkable capabilities in generating high-fidelity images. However, these models frequently struggle with complex scenes involving multiple objects. Textual descriptions are often insufficient for specifying precise coordinates, sizes, and overlapping relationships, leading to issues like "object leakage" or incorrect spatial arrangements (e.g., a mountain appearing beside a house instead of behind it).

Layout-to-Image (L2I) generation addresses these limitations by using bounding boxes and class labels as conditioning inputs. Despite this, previous L2I approaches often treat objects in isolation or use simplistic encoders that ignore fine-grained spatial coherence. LAW-Diffusion addresses these gaps by explicitly modeling the "harmony" of neighboring and overlapping objects through a layout-aware approach.

2. Methodology

LAW-Diffusion introduces three primary technical innovations to improve layout-conditioned synthesis.

2.1 Spatial Dependency Parser

The Spatial Dependency Parser moves beyond simple label lists by instantiating each object as a "region map." These maps are partitioned into spatial fragments (patches). A location-aware cross-object attention mechanism processes these fragments, enabling the model to understand which objects occupy adjacent or overlapping spaces. This approach allows the latent space to encode complex spatial dependencies, such as occlusion and relative positioning, more effectively than previous methods. By breaking the layout into spatial fragments rather than just linguistic tokens, the model learns local context—understanding, for instance, how a "car" fragment should change when it overlaps a "road" versus a "sidewalk."

2.2 Adaptive Guidance Schedule

Diffusion models typically use a constant guidance scale to balance fidelity and adherence to the input condition. However, high guidance often results in over-saturated, "burnt" textures. LAW-Diffusion employs a cosine-annealed Adaptive Guidance Schedule. This schedule applies high guidance during the early denoising stages to lock in the global layout structure and gradually reduces it in later stages to allow for the generation of fine, realistic textures. This recognizes that layout is most critical during the structural phase of denoising, while texture fidelity requires more freedom in the final stages.

2.3 Layout-aware Latent Grafting

For image editing, the authors propose a training-free mechanism called Latent Grafting. By transferring latent noise from a specific region of one generation to another at the same noise level, users can modify specific instances—adding, removing, or restyling objects—without altering the rest of the scene.

3. Experiments and Evaluation

The model was trained and evaluated on two standard benchmarks for complex scene understanding:

  • COCO-Stuff: An extension of MS-COCO containing 80 "thing" classes and 91 "stuff" classes (backgrounds like sky or grass).
  • Visual Genome (VG): A challenging dataset featuring 178 categories and dense object interactions.

In addition to standard metrics like FID and Classification Accuracy Score (CAS), the authors introduced the Scene Relation Score (SRS). SRS utilizes a pre-trained scene graph generator to verify if the spatial relationships in the generated image (e.g., verifying if a "boat" is actually "on" the "water") match the input layout, providing a more rigorous measure of spatial coherence.

4. Results

LAW-Diffusion achieved state-of-the-art (SOTA) results across multiple dimensions:

  • Image Quality: On the 256×256 COCO-Stuff dataset, the model achieved an FID of 19.02, significantly outperforming previous diffusion-based L2I models like LDM (40.91) and Frido (21.67).
  • Semantic Accuracy: High CAS scores indicate that generated objects are highly recognizable by independent classifiers.
  • Relationship Preservation: The SRS metric confirmed that LAW-Diffusion is superior at maintaining rational and harmonious relationships between contextual objects compared to GAN or Transformer-based baselines.

5. Conclusion and Limitations

LAW-Diffusion represents a significant step forward in layout-conditioned image synthesis by focusing on spatial dependencies and adaptive guidance. However, the authors acknowledge certain constraints: the model is currently limited to a closed-world vocabulary based on its training sets and lacks a mechanism for simultaneous global style control (e.g., "oil painting"). Future work aims to integrate open-vocabulary models like RegionCLIP to allow for more flexible, fine-grained semantic control over both known and unknown object categories.

Summary updated

BibTeX
@inproceedings{yang2023law,
  author = {Binbin Yang and Yi Luo and Ziliang Chen and Guangrun Wang and Xiaodan Liang and Liang Lin},
  title = {{LAW-Diffusion: Complex Scene Generation by Diffusion with Layouts}},
  booktitle = {IEEE/CVF International Conference on Computer Vision},
  year = {2023},
}
Figure