Skip to content

Barbershop: GAN-based Image Compositing using Segmentation Masks (SIGGRAPH Asia 2021)

Notifications You must be signed in to change notification settings

cankocagil/Barbershop

 
 

Repository files navigation

Barbershop: GAN-based Image Compositing using Segmentation Masks

teaser

Barbershop: GAN-based Image Compositing using Segmentation Masks
Peihao Zhu, Rameen Abdal, John Femiani, Peter Wonka

arXiv | BibTeX | Project Page | Video

Abstract Seamlessly blending features from multiple images is extremely challenging because of complex relationships in lighting, geometry, and partial occlusion which cause coupling between different parts of the image. Even though recent work on GANs enables synthesis of realistic hair or faces, it remains difficult to combine them into a single, coherent, and plausible image rather than a disjointed set of image patches. We present a novel solution to image blending, particularly for the problem of hairstyle transfer, based on GAN-inversion. We propose a novel latent space for image blending which is better at preserving detail and encoding spatial information, and propose a new GAN-embedding algorithm which is able to slightly modify images to conform to a common segmentation mask. Our novel representation enables the transfer of the visual properties from multiple reference images including specific details such as moles and wrinkles, and because we do image blending in a latent-space we are able to synthesize images that are coherent. Our approach avoids blending artifacts present in other approaches and finds a globally consistent image. Our results demonstrate a significant improvement over the current state of the art in a user study, with users preferring our blending solution over 95 percent of the time.

Description

Official Implementation of Barbershop.

KEEP UPDATING !

python main.py --im_path1 90.png --im_path2 15.png --im_path3 117.png

Updates

18/12/2021 Add a rough version of the project.

2/6/2021 Add project page.

Todo List

  • add a detailed readme
  • update code
  • integrate image encoder
  • add preprocessing step
  • ...

BibTeX

@misc{zhu2021barbershop,
      title={Barbershop: GAN-based Image Compositing using Segmentation Masks},
      author={Peihao Zhu and Rameen Abdal and John Femiani and Peter Wonka},
      year={2021},
      eprint={2106.01505},
      archivePrefix={arXiv},
      primaryClass={cs.CV}
}

About

Barbershop: GAN-based Image Compositing using Segmentation Masks (SIGGRAPH Asia 2021)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 82.2%
  • Cuda 12.7%
  • C++ 4.7%
  • Other 0.4%