Abstract
Example-guided image synthesis aims to generate realistic images from semantic label maps while following the style of a reference image. Current methods often struggle when the reference image and target layout are spatially or semantically unaligned. This paper presents a novel framework utilizing Masked Spatial-Channel Attention (MSCA) and a self-supervised training strategy to achieve high-quality, controllable synthesis in these challenging "wild" scenarios.
The Challenge of Unaligned Synthesis
Semantic image synthesis has advanced significantly with models like SPADE, but providing fine-grained user control over style—such as specific lighting, texture, and color—remains difficult. While previous example-guided approaches exist, they typically require the exemplar to share a similar layout or category with the target (e.g., a face guiding another face).
This work addresses the more general problem of transferring style from an arbitrary reference image to a completely different semantic structure. The core difficulty lies in establishing meaningful correspondences between two scenes that differ both in spatial layout and semantic content. For instance, using a photograph of a mountain range to guide the synthesis of a beach scene requires the model to intelligently map "sky" to "sky" while ignoring "snow" if the target has no such category.
Proposed Methodology
The authors propose a three-stage architecture consisting of Feature Extraction, Alignment, and Synthesis, powered by two main innovations:
1. Masked Spatial-Channel Attention (MSCA)
To handle unaligned scenes efficiently, the MSCA module decouples attention into spatial and channel components. Standard attention is computationally expensive; MSCA solves this by first identifying $K$ representative regions in the exemplar and then using a gating mechanism to filter out semantic features that do not exist in the target label map. Finally, it redistributes these filtered style features into the target's spatial layout. This decoupling allows the model to handle higher resolutions without the quadratic memory cost of standard self-attention.
2. Self-Supervised Training Scheme
Since ground-truth pairs for cross-scene style transfer are unavailable, the model is trained using a "style is stationary" assumption. The authors realize that style remains consistent within a single image. They train the model using:
- Cross-reconstruction: The model takes two different patches from the same image and is asked to reconstruct the structure of Patch A using the style of Patch B. Since they come from the same photo, the style is a ground-truth match despite the different structures.
- Self-reconstruction: A global-scale task where the model reconstructs an image from itself to maintain overall coherence.
Key Results and Insights
The model demonstrates superior performance over baselines like cI2I and SPADE-VAE across all metrics, including PSNR (pixel accuracy), LPIPS (perceptual similarity), and FID (realism). For the "retrieving" task, it achieved an FID of 91.91 compared to SPADE-VAE's 102.68.
Qualitatively, the MSCA module allows for much better color and texture preservation, accurately transferring specific "golden hour" lighting or complex textures from a reference photo to a new scene. The model also naturally supports extensions like style interpolation (blending two reference styles) and image extrapolation.
Conclusion
By combining a decoupled attention mechanism with a clever self-supervised training scheme, this framework enables flexible and high-quality example-guided image synthesis. It moves beyond the limitations of layout-dependent style transfer, opening new possibilities for interactive scene editing and creative content generation.
Summary updated