Modeling Image Composition for Complex Scene Generation

Zuopeng Yang, Daqing Liu, Chaoyue Wang, Jie Yang, Dacheng Tao
6/2/2022
cs.CV
transformer-attention

Official code: JohnDreamer/TwFA (11 stars, Python, MIT, last commit 2024-11-05).

Abstract

We present a method that achieves state-of-the-art results on challenging (few-shot) layout-to-image generation tasks by accurately modeling textures, structures and relationships contained in a complex scene. After compressing RGB images into patch tokens, we propose the Transformer with Focal Attention (TwFA) for exploring dependencies of object-to-object, object-to-patch and patch-to-patch.

Show full abstract

Compared to existing CNN-based and Transformer-based generation models that entangled modeling on pixel-level&patch-level and object-level&patch-level respectively, the proposed focal attention predicts the current patch token by only focusing on its highly-related tokens that specified by the spatial layout, thereby achieving disambiguation during training. Furthermore, the proposed TwFA largely increases the data efficiency during training, therefore we propose the first few-shot complex scene generation strategy based on the well-trained TwFA. Comprehensive experiments show the superiority of our method, which significantly increases both quantitative metrics and qualitative visual realism with respect to state-of-the-art CNN-based and transformer-based methods. Code is available at https://github.com/JohnDreamer/TwFA.

View on arXivView PDF

Code Implementations(1)

JohnDreamer/TwFAOfficial100%
MIT
113PythonMar 26, 20222 years agoMIT

Similar Papers

Cite this paper

@article{yang2022modeling,
  title  = {Modeling Image Composition for Complex Scene Generation},
  author = {Zuopeng Yang and Daqing Liu and Chaoyue Wang and Jie Yang and Dacheng Tao},
  year   = {2022},
  eprint = {2206.00923},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2206.00923}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2206.00923.svg)](https://codeofpaper.com/paper/2206.00923)

Discussion