DualVAE: Controlling Colours of Generated and Real Images

Keerth Rathakumar, David Liebowitz, Christian Walder, Kristen Moore, Salil S. KanherearXiv 2023 · DOI

Abstract

DualVAE is a novel hybrid generative model that achieves high-fidelity image synthesis while providing precise, disentangled control over color and geometry. By introducing a dual-branch architecture and a specialized regularization loss, the framework successfully separates structural content ("what") from appearance ("what color"), outperforming standard models like VQ-GAN in both image quality and attribute steerability.

Introduction

In deep generative modeling, a persistent trade-off exists between image quality and controllability. While Vector Quantized Variational AutoEncoders (VQ-VAEs) produce high-resolution images, they often lack intuitive parameters for attribute manipulation. Conversely, Generative Adversarial Networks (GANs) like StyleGAN offer better control but suffer from training instabilities and mode collapse. The core challenge lies in disentanglement: isolating structural information (geometry) from appearance (color) so that one can be modified without affecting the other. DualVAE addresses this by partitioning the latent space into discrete geometry and continuous color representations.

Methodology

The DualVAE architecture splits the latent representation into two distinct components: a Geometry Latent ($z_g$), which uses discrete tokens to capture localized spatial features, and a Color Latent ($z_c$), which utilizes a continuous Gaussian representation for global color attributes.

The DualVAE architecture employs a dual-branch decoder that processes structural signals before integrating color information ($z_c$).

Key Architectural Innovations

  1. Learned Geometry Module: Rather than relying on fixed grayscale transforms, the model uses a sequence of convolutions to learn an "adaptive intensity transform." This preserves critical boundaries that standard methods might obscure.
  2. Dual-Branch Architecture: The decoder features separate skip connections for geometry and color. By processing structural signals prior to color signals, the model is biased toward establishing the image "skeleton" first.
  3. Implicit ELBO Regularization: To prevent "latent degeneracy"—where one variable dominates the representation—the authors introduced a modified Evidence Lower Bound (ELBO) objective. This forces the decoder to utilize both pathways effectively during reconstruction.

The authors also developed ReDualVAE, a variant optimized for manipulating existing images, enabling tasks such as high-fidelity recoloring and color transfer.

Experimental Evaluation

The model was evaluated across diverse datasets, including Metfaces, Anime Faces, CUB_Birds, and Art Landscapes. DualVAE demonstrated significant improvements in image realism, achieving a Fréchet Inception Distance (FID) nearly twice as good as the baseline VQ-GAN on several benchmarks.

Qualitative results on the Metfaces dataset demonstrate the model's ability to perform precise color transfer by applying the palette of an exemplar image to a target structure.

Key Insights

  • Disentanglement Success: Quantitative ablation studies confirmed that the specialized regularization loss is critical. Without it, the geometry latent tends to absorb color information, leading to poor control.
  • Representation Alignment: By matching discrete tokens to shape and continuous variables to color, the model mirrors the physical nature of images—where shapes have hard boundaries and colors exist on a spectrum.
  • Stability: As a likelihood-based VAE, DualVAE avoids the adversarial training hurdles of GANs while maintaining competitive or superior control over color distributions.

Conclusion and Future Work

DualVAE provides a robust framework for disentangled image generation. While it excels at global color manipulation, it faces challenges with complex datasets like Logos, where multiple small, distinct objects require localized color control. Future research may explore more sophisticated color descriptors or multi-object latent structures to extend these capabilities to more complex scenes.

Summary updated

BibTeX
@misc{rathakumar2023dualvae,
  author = {Keerth Rathakumar and David Liebowitz and Christian Walder and Kristen Moore and Salil S. Kanhere},
  title = {{DualVAE: Controlling Colours of Generated and Real Images}},
  year = {2023},
  eprint = {2305.18769},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2305.18769},
}
Figure