LCD$^3$: Layout-Conditioned Diffusion for Dataset Distillation in Object Detection

Yue Cao, Mohsen Zardadi, Yu Hu, Yanshuo Fan, Jozsef Hamari, Zheng Liu, Jianyang GuNeurIPS 2026

TL;DR

Training modern object detectors requires massive datasets, and shrinking them down—a process called dataset distillation—usually results in weird, unnatural copy-paste collages that break spatial context. This paper introduces LCD$^3$, a framework that separates where objects are (spatial layouts) from how they look (visual realizations). By preserving real-world bounding box layouts and using a diffusion model to paint fresh, diverse visual scenes into them, LCD$^3$ creates tiny, ultra-effective training sets that beat state-of-the-art methods while using far fewer objects per image.

What Problem Does This Paper Address?

Dataset distillation aims to compress a massive dataset of tens of thousands of images into a tiny handful of synthetic images that can train a model nearly as well as the original set. While this works well for simple image classification (where one centered object dominates the frame), object detection is a different beast. Detection requires learning both what objects look like and where they sit in complex scenes.

Real detection datasets are full of visual redundancy—think dozens of nearly identical red double-decker buses on gray London streets. Existing distillation methods try to pack more information into fewer images either by selecting real images (which keeps all that visual redundancy) or by densely copy-pasting cropped objects onto a blank canvas (like the previous state-of-the-art, OD$^3$). Copy-pasting boosts object density, sure, but it destroys local spatial context: scales don't match, lighting clashes, and objects float unnaturally over unrelated backgrounds.

Figure 1: (a) Real images in COCO have redundancy both within an image and across images (top row), limiting the information density for DD. Diffusion models can generate images that preserve plausible layout structure while introducing visual variety in object appearance, background, and viewpoint (bottom row). (b) Generated images significantly increase diversity across classes.

The authors notice a fundamental structural asymmetry: spatial layouts (bounding boxes and class labels) define the actual rules and geometry of the detection task, so making them up from scratch risks changing the problem. Visual realizations (the actual pixels, textures, and lighting), however, are just conditional samples attached to those layouts—and a prime target for diversification.

Methods

LCD$^3$ (Layout-Conditioned Diffusion for Dataset Distillation) decouples layout preservation from pixel generation in three main stages:

  1. Scene-Based 4-Quadrant Layout Construction (Novel): Instead of inventing bounding boxes, LCD$^3$ recombines real ones. First, it encodes all original training images using a pretrained vision model (like CLIP or DINOv2) and runs K-means clustering to group them into distinct scene types (e.g., indoor dining vs. city streets), setting the number of clusters equal to the target synthetic image budget. Each synthetic canvas is split into a $2 \times 2$ grid. Four source layouts from different scene clusters are scaled down and placed into the quadrants—starting with cluster medoids (most representative scenes) and greedily picking subsequent layouts to match the original dataset's class distribution.
  2. Crop Semantic Check (Novel): Pure text-to-image diffusion might drift away from the original dataset's visual style (creating a domain gap). To ground the generator, LCD$^3$ uses real object crops from the source images as visual references. Because real crops are often blurry or occluded, a frozen CLIP model performs zero-shot classification on every crop; only crops whose top-1 predicted class matches the ground truth enter the verified reference pool.
  3. Instance-Grounded Diffusion & Observer Filtering (Standard tools, novel integration): An off-the-shelf layout-guided diffusion model (GLIGEN or MS-Diffusion) renders the 4-quadrant layout into a coherent image, guided by the verified crops (when available) or text labels. Finally, because diffusion models occasionally miss a box, a pretrained detector ("observer" model, like DINO) scans the generated image and keeps only high-confidence bounding boxes ($\ge 0.2$) as final annotations.
Figure 2: Overview of the proposed pipeline. Given original training data, the Layout Construction module extracts scene embeddings and clusters images via K-means to sample representative layouts. The Crop Semantic Check module verifies each object crop through CLIP top-1 class matching to build a clean instance pool. The selected layouts and verified crops are combined into a 4-quadrant conditioning and fed into a layout-guided diffusion model to generate the final distilled data.

Datasets

No new datasets are introduced; the authors evaluate across three established object detection benchmarks under extreme compression ratios (IPD, or Images Per Dataset):

  • MS COCO: Distilled from train2017 (~118k images, 80 classes) at 0.25%, 0.5%, and 1.0% IPD, evaluated on val2017.
  • PASCAL VOC: Distilled from combined 2007+2012 train-val splits (~16.5k images, 20 classes) at 0.5% (~80 images!), 1.0%, and 2.0% IPD, evaluated on the VOC 2007 test set.
  • HRRSD: A remote sensing benchmark of 21,761 aerial images across 13 categories, distilled at 0.5% IPD to test cross-domain generalization outside natural photography.

Key Insights and Ideas

  • Quality and diversity beat brute-force density: Previous methods assumed cramming more objects per canvas was key—OD$^3$ packs an average of 86.7 objects per image! LCD$^3$ averages just 12.0 objects per image, yet achieves lower inter-object similarity and trains significantly stronger detectors. Preserving realistic intra-quadrant spatial context matters far more than sheer object count.
  • Detector-agnostic synthesis enables true generalization: Copy-paste methods that rely on a specific detector (e.g., Faster R-CNN) to select crops bake that architecture's biases right into the synthetic pixels, causing performance to tank when training other models. Because LCD$^3$ builds layouts and pixels without a detector in the loop, the distilled data transfers smoothly across CNNs and Transformers alike.
  • Natural-image diffusion priors work even on aerial imagery: Even without fine-tuning the diffusion generator on satellite photos, LCD$^3$ works well on remote sensing data (HRRSD) because grounding the diffusion process with real in-domain object crops and real spatial layouts anchors the pixels to reality.

Key Results

LCD$^3$ consistently outperforms prior state-of-the-art methods across both standard ("hard" ground-truth boxes) and knowledge-distillation ("soft" teacher-guided) training setups:

  • PASCAL VOC: At a tiny 0.5% IPD (~80 images), LCD$^3$ beats OD$^3$ by +12.5% $\text{mAP}_{50}$ (34.2% vs. 21.7%) under hard labels, and by +7.5% $\text{mAP}_{50}$ (61.6% vs. 54.1%) under soft labels.
  • MS COCO: At 0.25% IPD (~300 images), LCD$^3$ outperforms OD$^3$ by +3.2% mAP (8.7% vs. 5.5%) under hard labels and +5.7% $\text{mAP}_{50}$ (29.1% vs. 23.4%) under soft labels.
  • Cross-Architecture Transfer: When a single 1.0% IPD COCO dataset is used to train diverse architectures, OD$^3$ collapses on non-Faster R-CNN detectors, whereas LCD$^3$ more than doubles mAP on RetinaNet (10.0% vs. 4.3%) and DINO (14.4% vs. 6.3%).
Table 3: Cross-architecture evaluation on MS COCO at 1.0% IPD. The distilled dataset is generated once and used to train different detector architectures. All models use ResNet-50 backbone[42].
  • Scene Embedding Trade-offs: In ablations, using the massive SAM 3 segmentation encoder for scene clustering pushes VOC 0.5% IPD accuracy even higher (to 38.2% $\text{mAP}_{50}$), though it takes ~60$\times$ longer per image than CLIP or DINOv2.

Limitations and Future Work

The authors note two primary limitations:

  1. Single-task evaluation: While separating layout from visual realization is conceptually universal, they only test it on bounding-box object detection. Extending it to pixel-level dense prediction tasks like instance segmentation is a natural next step.
  2. Rigid $2 \times 2$ grid: Every composite image uses a fixed 4-quadrant split regardless of how crowded or simple the source scenes are (going to $3 \times 3$ shrinks sub-images too much for diffusion to render fine details). Future work aims to explore adaptive grid strategies that partition canvases dynamically based on scene complexity, as well as testing domains far outside natural images, such as medical imaging.

Summary updated

Abstract

Object detection data contains a structural asymmetry that is easy to overlook in dataset distillation (DD). Each detection image couples a spatial layout with a visual realization. Layouts define detection targets through object categories and bounding boxes, while pixels instantiate these targets with particular object appearances and backgrounds. Although both forms can be redundant across a dataset, they play different roles. Layouts define the task distribution, so synthesizing them freely risks altering the detection problem. Visual realizations, on the other hand, are conditional samples attached to layouts. This motivates a separation principle: preserve and recombine layouts from the original data, then use generative priors to diversify their visual realizations. Based on this principle, we propose LCD$^3$, a layout-conditioned diffusion framework for object detection DD. LCD$^3$ constructs composite layouts from diverse groups based on scene-level embeddings. A layout-conditioned diffusion model then generates new images from these layouts, enriching object appearance and scene realization without discarding the spatial structure needed for detection. The generation process is grounded with semantically verified object crops to retain the original visual style. Experiments show that this separation between layout and realization produces more effective distilled detection datasets. LCD$^3$ consistently outperforms the previous state-of-the-art, OD$^3$, across benchmarks using fewer objects per distilled image, e.g., a $12.5$\% mAP50 improvement at a $0.5$\% compression ratio on PASCAL VOC.
BibTeX
@inproceedings{cao2026lcd,
  author = {Yue Cao and Mohsen Zardadi and Yu Hu and Yanshuo Fan and Jozsef Hamari and Zheng Liu and Jianyang Gu},
  title = {{LCD$^3$: Layout-Conditioned Diffusion for Dataset Distillation in Object Detection}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2026},
  url = {https://openreview.net/forum?id=htxCgIKQGB},
}
Figure