Diagnosing and Enhancing VAE Models
\nameBin Dai \addrInstitute for Advanced Study Tsinghua University Beijing, China \AND\nameDavid Wipf \addrMicrosoft Research Beijing, China
Abstract
Although variational autoencoders (VAEs) represent a widely influential deep generative model, many aspects of the underlying energy function remain poorly understood. In particular, it is commonly believed that Gaussian encoder/decoder assumptions reduce the effectiveness of VAEs in generating realistic samples. In this regard, we rigorously analyze the VAE objective, differentiating situations where this belief is and is not actually true. We then leverage the corresponding insights to develop a simple VAE enhancement that requires no additional hyperparameters or sensitive tuning. Quantitatively, this proposal produces crisp samples and stable FID scores that significantly reduce the gap with GAN models when a neutral architecture is applied, all while retaining desirable attributes of the original VAE architecture. A shorter version of this work has been accepted to the ICLR 2019 conference proceedings (Dai and Wipf, 2019). The code for our model is available at https://github.com/daib13/TwoStageVAE.
中文速览
变分自编码器(VAE)生成的图像经常模糊,人们普遍认为这是编码器和解码器都采用高斯分布假设所造成的根本缺陷。这篇论文对VAE的目标函数进行了严格的数学分析,发现真正的问题不在于高斯假设本身——当数据流形维度等于环境空间维度时,高斯VAE在理论上完全可以恢复真实的数据分布;但当数据存在低维结构(即流形维度小于环境空间维度)时,VAE的最优解虽然能学到正确的流形,却无法保证在流形上学到正确的概率测度。基于这一洞察,作者提出了一个两阶段VAE(Two-Stage VAE):第一阶段用普通VAE学习数据流形并得到紧凑的低维表示,第二阶段再用一个小型VAE在该表示空间上学习正确的概率分布。这个方法无需修改损失函数或引入额外超参数,却能生成清晰锐利的图像,并在FID分数上大幅缩小与GAN的差距,同时保留VAE训练稳定、具备推断网络等固有优势。
原文 arXiv:1903.05789;中英对照 + 大白话阅读 https://aha.fim.ai/paper/1903.05789v2