Source-linked AI summary

IntroVAE: Introspective Variational Autoencoders for Photographic Image Synthesis

Huaibo Huang, Zhihang Li, Ran He, Zhenan Sun, Tieniu Tan

arXiv:1807.06358v2cs.LGcs.CVcs.GRstat.ML

TL;DR

High-resolution image synthesis must balance VAEs’ stable latent structure against their blurry outputs and GANs’ sharp images against their training difficulty. IntroVAE integrates both through introspective joint training, using the inference model as a discriminator without extra components. The method synthesizes high-resolution photographic images comparable to state-of-the-art GANs while retaining VAE advantages.

  • Problem

    VAEs provide stable training and useful latent manifolds but tend to produce blurry images, while adversarial training can introduce mode collapse and instability.

  • Method

    IntroVAE jointly trains inference and generator models in an introspective min-max game, using the inference model to distinguish generated from real samples without extra discriminators.

  • Results

    IntroVAE produces visually appealing 1024 × 1024 photographic images and samples comparable with PGGAN using a simpler single-stream, single-stage training process.

  • Takeaways & Limitations

    The method combines high-resolution photographic synthesis with stable training and a nice latent manifold in a single-stage architecture.

  • Takeaways & Limitations

    The adversarial training manner can still cause mode collapse and training instability, as in other GANs.

Abstract

from arXiv · show

We present a novel introspective variational autoencoder (IntroVAE) model for synthesizing high-resolution photographic images. IntroVAE is capable of self-evaluating the quality of its generated samples and improving itself accordingly. Its inference and generator models are jointly trained in an introspective way. On one hand, the generator is required to reconstruct the input images from the noisy outputs of the inference model as normal VAEs. On the other hand, the inference model is encouraged to classify between the generated and real samples while the generator tries to fool it as GANs. These two famous generative frameworks are integrated in a simple yet efficient single-stream architecture that can be trained in a single stage. IntroVAE preserves the advantages of VAEs, such as stable training and nice latent manifold. Unlike most other hybrid models of VAEs and GANs, IntroVAE requires no extra discriminators, because the inference model itself serves as a discriminator to distinguish between the generated and real samples. Experiments demonstrate that our method produces high-resolution photo-realistic images (e.g., CELEBA images at \(1024^{2}\)), which are comparable to or better than the state-of-the-art GANs.

1 Introduction

VAEs offer stable training and useful latent manifolds but often produce blurry images, while GANs generate sharp images with greater training complexity. IntroVAE combines these frameworks in a single-stream, single-stage model without extra discriminators for high-resolution photographic synthesis.

  • VAEs provide theoretically elegant, easy-to-train models with nice manifold representations but tend to produce blurry images lacking detail.
  • GANs and hybrid models have improved high-resolution synthesis, but many GAN approaches require multi-scale or multiple discriminators, increasing training complexity.
  • IntroVAE trains the inference and generator models introspectively, with the inference model distinguishing generated from real images while the generator attempts to mislead it.
  • IntroVAE requires no extra discriminator because its inference model estimates differences between generated and real images.
  • IntroVAE uses a single-stream, single-stage adversarial model for high-resolution photographic image synthesis, including CELEBA images at 1024^2.

2 Background

VAEs and GANs use different generative strategies: VAEs provide structured latent representations but blurry samples, whereas GANs produce sharp images but are difficult to train. Hybrid models typically add discriminators to impose adversarial constraints.

  • VAEs consist of a generator that samples visible variables from latent variables and an inference network that maps visible variables toward a prior.
  • VAEs commonly generate blurry samples, attributed to limited inference-model expressiveness, injected noise, and imperfect element-wise criteria such as squared error.
  • GANs use a two-player min-max game in which the generator produces samples to confuse a discriminator distinguishing generated samples from training data.
  • GANs can generate sharp images but are difficult to train, with instability and mode collapse especially problematic for high-resolution images.
  • Hybrid VAE-GAN models usually combine encoder and decoder networks with an extra discriminator acting in latent, data, or joint space.

3 Approach

IntroVAE combines VAE reconstruction and regularization with adversarial distribution matching, using the inference model as a discriminator and the generator as an adversary. The two models are trained jointly without extra discriminators, preserving VAE structure while targeting more realistic samples.

  • Introspective adversarial training: IntroVAE selects the VAE inference model E as the GAN discriminator and the generator G as the GAN generator.E distinguishes generated samples from training data while G attempts to produce samples that E evaluates as realistic.
  • VAE objective: The ELBO combines reconstruction error LAE with prior regularization LREG, which encourages qφ(z|x) to match the prior p(z).LAE reconstructs inputs, while LREG regularizes the encoder's approximate posterior.
  • Adversarial distribution matching: The adversarial objective minimizes LREG on real data and maximizes it on generated samples for E, while G minimizes LREG on generated samples.This trains E to separate real and generated distributions and G to make generated posteriors approximate the prior.
  • Theoretical analysis: At a Nash equilibrium, the theoretical system requires the generated distribution pG∗ to equal the data distribution pdata and E∗(x) to be constant within [0, m].The theorem assumes no region exists where pdata(x) = 0.
  • Hybrid objective: Adding LAE bridges E and G: real training samples retain the standard VAE ELBO, while generated samples induce a min-max game that encourages realism.This hybrid objective combines the adversarial terms with the ELBO objective.
  • Relation to hybrid models: Unlike other VAE-GAN hybrids, IntroVAE jointly and adversarially trains E and G across latent and data spaces without extra discriminators.The inference model supplies the prior-regularization signal used for adversarial training.

4 Experiments

Experiments evaluate IntroVAE on CelebA, CelebA-HQ, and LSUN BEDROOM through image quality, training behavior, diversity, and latent-manifold continuity. The method produces high-resolution photographic images, converges stably, achieves comparable or better quantitative performance than PGGAN, and exhibits continuous latent interpolations.

  • 4.1 Implementations: Experiments use CelebA, CelebA-HQ, and LSUN BEDROOM, including 1024 × 1024 CelebA-HQ images.CelebA-HQ contains 30,000 images at 1024 × 1024 resolution, while LSUN BEDROOM contributes 3,033,042 training images.
  • 4.2 High quality image synthesis: IntroVAE produces visually appealing 1024 × 1024 reconstructions and samples that preserve global input topology and photographic visual quality.Reconstructions do not retain exact pixel-wise similarity because VAEs inject random noise during training.
  • 4.2 High quality image synthesis: IntroVAE generates high-resolution samples comparable with PGGAN while training a single inference model and generator in one stage.The results indicate that direct high-resolution training can avoid decomposing synthesis into multiple low-to-high-resolution tasks.
  • 4.3 Training stability and speed: Training losses converge rapidly to a stable stage, with reconstruction and KL-divergence values fluctuating around a balance line while sample quality improves steadily.The inference model’s prediction reaches a constant γ in [0, m], consistent with the observed KL-divergence curves.
  • 4.3 Training stability and speed: Convergence time increases with image resolution because hardware limits minibatch size for high-resolution training.Training speed is evaluated at 128 × 128, 256 × 256, 512 × 512, and 1024 × 1024 resolutions.
  • 4.4 Diversity analysis: Using MS-SSIM and FID, IntroVAE achieves comparable or better quantitative performance than PGGAN, reflecting sample diversity to some degree.MS-SSIM uses 10K synthesized-image pairs at 128 × 128, while FID uses 50K images at the specified evaluation resolutions.
  • 4.5 Latent manifold analysis: Latent interpolations between real images show continuity across changes such as male-to-female transitions and profile-face rotation.The authors interpret this continuity as evidence that the model generalizes image contents rather than simply memorizing them.

5 Conclusion

IntroVAE trains the inference and generator models through a min-max game, allowing the inference model to estimate generated-image quality while preserving a standard VAE structure. The approach is presented as simpler, more efficient, stable, and extensible to related VAE tasks.

  • The inference model learns a latent manifold while acting as a discriminator that maximizes posterior-prior divergence for generated data.
  • IntroVAE self-estimates generated-image quality and improves its samples accordingly.
  • A single-stream network trained in one stage provides a simpler and more efficient alternative to other state-of-the-art methods.
  • The model synthesizes high-resolution photographic images through a stable training process.
  • Because IntroVAE uses a standard VAE architecture, it may be extended to conditional image synthesis and other VAE-related tasks.

A Proof of theorem 1

The proof establishes the theorem’s saddle-point characterization by analyzing the objective with respect to the inference model and then ruling out alternatives for the generator and inference function.

  • Theorem statement: The theorem states that a saddle point satisfies pG*=pdata and E*(x)=γ for a constant γ∈[0,m].
  • Inference-model analysis: For fixed generator density pG*, the objective is minimized pointwise using ϕ(y)=ay+b[m−y]+, whose minimum occurs at m when a<b and at 0 otherwise.
  • Objective bound: The proof derives m≤V(G*,E*)≤m, yielding V(G*,E*)=m.
  • Generator condition: The equality condition ∫1[pdata(x)<pG*(x)](pdata(x)−pG*(x))dx=0 implies pG*=pdata almost everywhere.
  • Inference-function condition: Assuming E* is nonconstant, the proof constructs a generator G0 with pG0≤pdata on a set S and pG0<pdata on a positive-measure subset, contradicting the objective equation.

B Network Architecture

The 1024×1024 architecture uses residual blocks with resolution-dependent reductions for smaller images, and the residual design is reported to accelerate convergence at higher resolutions.

  • For smaller resolutions, the inference model uses fewer [Res-block + AvgPool] units and the generator uses fewer [Upsample + Res-block] units.
  • Residual blocks can accelerate image-synthesis convergence, especially above 256×256 resolution.
  • Table 3 specifies the network architecture for generating 1024×1024 images.

C Illustration of training flow

IntroVAE trains its inference model and generator iteratively, using an additional inference pass after generation or reconstruction and controlling adversarial-gradient flow for implementation convenience.

  • After images are generated or reconstructed, the training procedure makes an extra pass through the inference model.
  • Updating the inference model: The implementation stops adversarial-loss gradients from propagating to the generator during the first inference-model pass.
  • Updating the generator: Updating the generator first or omitting gradient stopping also works with one inference-model forward pass, but the reported choice is for realization convenience.
  • The flow distinguishes separate inference-model and generator update steps.
  • The inference model and generator are updated iteratively during training.

D Discussion of hyper-parameters

Hyper-parameters affect reconstruction quality, sample diversity, and convergence, while nearest-neighbor analysis compares generated images with training examples using pixel- and feature-space distances.

  • Hyper-parameter effects: On 256 × 256 CELEBA-HQ images, α values from 0.1 to 0.5 support training stability, while larger or smaller values may slow convergence.The passage notes that hyper-parameters still influence sample and reconstruction quality.
  • Hyper-parameter effects: With α fixed, increasing β improves reconstruction quality but may reduce sample diversity.RMSE is used for reconstruction quality and MS-SSIM for sample diversity in the hyper-parameter comparison.
  • Hyper-parameter effects: Figure 8 compares reconstructions and samples across settings using RMSE and MS-SSIM, with smaller values preferred for both measures.Each setting places reconstructions in the first image column and samples in the second.
  • Nearest-neighbor analysis: Nearest neighbors are identified using L1 pixel-space distance and cosine feature-space distance from LightCNN representations.The figure presents generated images alongside nearest training examples and compares low-level and high-level similarity measures.

F Qualitative comparison on LSUN CHURCHOUTDOOR

The paper includes qualitative comparisons for LSUN CHURCHOUTDOOR and DOG images, with the dog model trained on 256 × 256 ImageNet images.

  • Qualitative comparison: Figure 10 presents a qualitative comparison on LSUN CHURCHOUTDOOR.Images in panel (a) are copied from cited papers.
  • Qualitative comparison: Figure 11 presents a qualitative comparison on DOG images trained with 256 × 256 ImageNet images.Images in panel (a) are copied from cited papers.

H Additional 1024 × 1024 images

The paper reports additional results consisting of images at 1024 × 1024 resolution.

  • Additional results: Figures 12 and 13 show additional results of 1024 × 1024 images.
Loading 1807.06358v2…