Adversarial Image Composition with Auxiliary Illumination

Fangneng Zhan, Shijian Lu, Changgong Zhang, Feiying Ma, Xuansong Xie

Introduction

Image composition—the process of inserting a foreground object into a new background—is a fundamental task in computer vision and graphics. However, simple "copy-paste" operations often result in visual artifacts due to style inconsistencies (color, lighting, texture) and the absence of environmental interactions, most notably shadows. Existing image harmonization techniques typically focus on pixel adjustments within the object boundary, leaving the object appearing "detached" from the scene. This paper introduces the Adversarial Image Composition Net (AIC-Net), a framework designed to achieve high-fidelity compositions by simultaneously harmonizing object style and generating realistic, context-aware shadows.

AIC-Net: Architecture and Methodology

The core innovation of AIC-Net lies in its branched architecture, which disentangles the complex task of composition into manageable sub-problems.

Overview of the AIC-Net composition process, showing the progression from raw foregrounds to harmonized local and global images.

Branched Generation Mechanism

AIC-Net employs two specialized branches:

  1. Texture Branch: Focuses on style transfer to match the foreground object's appearance with the background environment. It utilizes a Guided Feature Filter to preserve essential object details while adapting its color and lighting.
  2. Shadow Branch: Dedicated to generating projected shadows. This branch is informed by an Auxiliary Illumination Model that estimates scene lighting using Spherical Harmonics (SH). By "reading" the background's lighting cues, the network ensures that generated shadows are consistent with existing light sources in direction and intensity.

Global Consistency and Training

To bridge the gap between local object editing and global scene integration, AIC-Net incorporates a Differentiable Spatial Transformer Module (STM). This allows the network to be trained end-to-end, ensuring that the local harmonization is optimized for the global context. The system is supervised by Dual Discriminators: one evaluates the local realism of the object and its shadow, while the other ensures the object fits seamlessly into the full-scale global image without visible seams.

Experimental Results

The researchers evaluated AIC-Net on pedestrian and vehicle composition tasks using datasets such as PRID 2011, WILDTRACK, UA-DETRAC, and Cityscapes.

A harmonized composition showing a pedestrian with a realistically generated shadow that matches the scene's lighting.

Quantitative and Qualitative Performance

AIC-Net demonstrates superior performance compared to state-of-the-art methods like CycleGAN and DeepIH. In terms of Frechet Inception Distance (FID), AIC-Net achieved a score of 84.4 for car composition, significantly lower (better) than competitors. Furthermore, a user study conducted via Amazon Mechanical Turk revealed that participants preferred AIC-Net's results as the most realistic in over 40% of cases, a substantial margin over traditional harmonization methods.

Qualitatively, the model successfully generates shadows that follow the direction of existing background shadows, even in complex outdoor scenes. This interaction between the object and the ground acts as the "glue" that creates a convincing sense of presence.

Conclusion and Future Work

AIC-Net advances the field of image composition by treating shadow generation as an integral part of the harmonization process. By leveraging auxiliary illumination cues and a branched adversarial framework, it produces results that are both locally detailed and globally consistent. Future research will focus on handling more complex 3D geometries, such as shadows falling across uneven surfaces like stairs or curbs, and extending the model to a wider variety of object categories.

Summary updated

BibTeX
@inproceedings{zhan2020adversarial,
  author = {Fangneng Zhan and Shijian Lu and Changgong Zhang and Feiying Ma and Xuansong Xie},
  title = {{Adversarial Image Composition with Auxiliary Illumination}},
  booktitle = {ACCV},
  year = {2020},
  doi = {10.1007/978-3-030-69532-3\_15},
}
Figure