Abstract
Semantic Image Synthesis (SIS) aims to transform segmentation maps into realistic photographs. While current diffusion-based models excel at generating high-quality images, providing users with precise control over the appearance of specific objects using reference images remains a significant challenge. This paper introduces the Appearance Matching Adapter (AM-Adapter), a learnable module designed to enable high-fidelity appearance transfer in complex, multi-object scenes. By integrating semantic segmentation into a 4D cost-aggregation framework, AM-Adapter ensures that textures and styles are mapped accurately to the correct semantic categories, effectively addressing the issue of "semantic bleeding" in "in-the-wild" scenarios.
Introduction
The goal of exemplar-based SIS is to allow users to dictate the appearance of a generated scene by providing a reference image. However, existing methods often struggle with complex scenes containing multiple diverse objects. Tools like ControlNet rely on vague text prompts, while other exemplar-based methods often apply styles globally, leading to artifacts where textures from one object (e.g., a car) bleed into another (e.g., a tree). The AM-Adapter addresses these "in-the-wild" challenges by providing a mechanism for faithful, category-aware appearance transfer that maintains structural integrity.
The AM-Adapter Framework
The core of the proposed method is the Appearance Matching Adapter, which bridges an Appearance Net (extracting reference features) and a Structure Net (generating the target image).
Key Technical Components
- Categorical Matching Cost: To prevent semantic mismatching, the model utilizes segmentation maps from both the reference and target images. This creates a binary mask that restricts the matching process, ensuring that "car" pixels only match with other "car" pixels, and so on.
- 4D Cost Aggregation: Moving beyond standard 2D operations, the framework employs a lightweight 4D convolution. This allows the model to refine matching scores across the entire 4D space, capturing precise pixel-to-pixel correspondences between the target and reference images.
- Stage-wise Training: Stability is maintained through a "freeze-and-train" strategy. The structure-guidance network and base diffusion model are frozen while only the AM-Adapter is trained, preventing the model from losing its generative quality while learning style matching.
- Retrieval-based Inference: For users without a specific reference, the system includes an automated retrieval mechanism to find structurally similar images from a database to serve as style guides.
Experimental Results
The researchers evaluated the AM-Adapter on diverse datasets, including BDD100K, Cityscapes, and NYUv2, alongside a custom benchmark of 300 highly complex image pairs.
Quantitative and Qualitative Performance
AM-Adapter significantly outperformed existing baselines like ControlNet + IP-Adapter and Ctrl-X. It achieved a lower FID score of 75.89 (compared to the next best 84.82), indicating superior image realism. Qualitative results show that the model successfully transfers intricate vehicle colors, building textures, and indoor patterns that other models typically blur or ignore. In a user study with 45 participants, the AM-Adapter was overwhelmingly preferred for its ability to balance structural consistency with faithful appearance capture.
Conclusion and Future Work
AM-Adapter represents a significant step forward in controllable image synthesis by leveraging semantic information to guide appearance matching. While the model's performance is currently linked to the quality of the underlying structure-guidance model, it sets a new state-of-the-art for in-the-wild synthesis. Future work will focus on improving temporal consistency for video applications by fine-tuning the adapter on video datasets to reduce flickering in dynamic scenes.
Summary updated