Manuscript Offprint

arXiv:2611.07553

Improving Long-Tail Detection via Layout-Instruction Conditioned Diffusion Synthesis

Xinyu Zhang, Xiaodi Wang, Yanpeng Sun, Lingfeng Yang, Jingdong Wang, Lingqiao Liu

Xinyu Zhang¹, Xiaodi Wang², Yanpeng Sun³, Lingfeng Yang⁴, Jingdong Wang⁵, Lingqiao Liu⁶

¹ University of Auckland, Auckland, New Zealand ² Dcar, Beijing, China

³ Singapore University of Technology and Design, Singapore ⁴ WIZYELAB PTE. LTD., Singapore

⁵ Baidu Inc., Beijing, China ⁶ Adelaide University, Adelaide, Australia

xinyu.zhang@auckland.ac.nz; wangxiaodigm@gmail.com; yanpengsun115@gmail.com; ylingfeng98@gmail.com

Abstract—Synthetic data from diffusion models can improve object detection, but long-tail performance is still limited by scarce rare classes and inflexible conditioning (e.g., text-only or layout-only inputs). In this paper, we propose Tail-SD, a layout-instruction conditioned stable diffusion framework that supports text, layouts, or their hybrid, enabling controllable synthesis from boxes, masks, and/or prompts to better cover the long-tail objects. To train a single model across heterogeneous conditions, we introduce a multi-task cross-attention module and multi-task embedding tokens, improving generation quality and diversity. Extensive experiments on COCO and LVIS demonstrate that diffusion synthesis with hybrid conditioning consistently benefits detection, e.g., on LVIS val, it achieves +4.89% / +5.68% rare Box/Mask AP, highlighting strong potential for addressing long-tail challenges.

Index Terms—Long-tail object detection, layout-instruction conditioned stable diffusion, controllable synthesis

I. INTRODUCTION

Stable diffusion models [1]–[13] have demonstrated significant progress in generative technology, presenting advanced capabilities to generate high-fidelity and realistic images. Some works [14]–[26] leverages diffusion-generated images as synthetic data to improve downstream perception tasks [27]–[35], including object detection.

Despite these advances, improving long-tail object detection remains a challenge. Real-world datasets are highly imbalanced: rare categories have limited instances and weak coverage of intra-class variations, causing detectors to underfit rare concepts and overfit head classes. A natural solution is to synthesize additional training samples, but long-tail gains require more than “more images”: effective augmentation must be targeted (to deliberately increase rare-class exposure), controllable (to ensure the desired category appears with correct attributes), and diverse (to enrich backgrounds, poses, viewpoints, and co-occurrences). However, existing diffusion-based synthesis pipelines often constrain conditioning to a single fixed format, limiting their ability to generate reliable and diverse rare-category samples.

Existing diffusion synthesis methods for detection [20], [22], [25], [33]–[38] can be broadly categorized into two lines by their input formats: layout-based and instruction-based. Layout-based approaches [20], [33], [34], [36], [37], [39] take structured layouts (e.g., masks or bounding boxes) to guide object composition and spatial arrangement. While

Figure

Fig. 1: Our Tail-SD is a flexible and versatile image generation pipeline, supporting text, layouts and a hybrid of both as inputs. The last three synthetic images are sampled from different seeds. (Zoom in for best view)

precise, they often require costly manual layout specification and are hard to scale to many rare categories. Moreover, fixed or simplistic layouts can bottleneck diversity, which is crucial for long-tail generalization. Recent attempts [22], [38], [40], [41] try to automatically generate layouts, yet maintaining reliability remains difficult, especially in object size, shape, position, and inter-object relationships. In contrast, instruction-based methods [19], [21], [23], [35] enable flexible prompting without explicit layouts, but may provide weaker spatial control and inconsistent instruction execution, making it difficult to reliably synthesize rare objects with desired attributes and minimal artifacts. These limitations motivate a unified framework that can exploit both the structural controllability of layouts and the semantic flexibility of instructions.

To this end, we propose Tail-SD, a layout-instruction conditioned stable diffusion framework tailored for long-tail detection. Tail-SD supports text, layouts, or their hybrid as inputs, allowing users to generate images based on what they have (boxes/masks) and what they want (instructions), which is particularly useful for targeted rare-class augmentation. Importantly, Tail-SD trains a single diffusion model that can flexibly adapt to different condition types via multi-task learning, so that robust condition-to-image alignment learned from abundant head classes can regularize and transfer to rare classes, improving the reliability of long-tail targeted synthesis. We design a multi-task cross-attention module together with multi-task embedding tokens to unify heterogeneous conditions in a simple yet effective way, improving generation fidelity while enhancing diversity across modalities.

We evaluate Tail-SD on object detection task. Following standard settings [33], [34], [42], we augment detector training data by mixing synthetic images generated by Tail-SD with the original data. Experiments show consistent improvements on both COCO and LVIS, and most importantly, substantial gains on LVIS rare categories, demonstrating the effectiveness of layout-instruction hybrid diffusion synthesis for addressing long-tail challenges. Our contributions are summarized as:

  • We introduce Tail-SD, a layout-instruction conditioned stable diffusion framework that supports text, layouts, or hybrid inputs for targeted and diverse synthetic augmentation in long-tail detection.

  • We propose a multi-task cross-attention module and multi-task embedding tokens to enable effective multi-task learning across heterogeneous conditioning modalities within a single diffusion model.

  • Extensive experiments on COCO and LVIS demonstrate consistent detection gains, with particularly strong improvements on rare categories, highlighting the potential of Tail-SD for long-tail challenges.

References (56)