Hierarchical Disentangled Representations

Babak Esmaeili, Hao Wu, Sarthak Jain, N. Siddharth, Brooks Paige, Jan-Willem van de Meent

Introduction

Unsupervised learning of latent representations aims to find compact codes that capture the underlying structure of high-dimensional data. A key goal is disentanglement, where individual dimensions of the latent code correspond to distinct semantic features. While models like the $\beta$-VAE have made strides, they often rely on a "flat" independence assumption that fails to capture the hierarchical or discrete nature of real-world data.

This paper introduces the Hierarchically Factorized VAE (HFVAE), a framework that moves beyond simple independence. By incorporating a structured prior and a decomposed objective function, HFVAE successfully separates discrete factors (e.g., object identity) from continuous ones (e.g., pose or style), improving both interpretability and generalization.

Methodology: ELBO Surgery and Hierarchical Priors

The core innovation of HFVAE lies in "ELBO surgery"—the decomposition of the standard Evidence Lower Bound (ELBO) into four intuitive components: reconstruction uniqueness, encoding uniqueness, marginal likelihood match, and prior match.

Visualizing the components of the decomposed ELBO objective

The "secret sauce" is the further decomposition of the prior match term (the KL divergence between the posterior and the prior) into a two-level hierarchy. This allows for precise control over independence at two scales:

  1. Between Groups: Ensuring that a block of variables representing "class" remains independent of a block representing "style."
  2. Within Groups: Controlling the independence of individual dimensions within those specific blocks.

To handle discrete categories within this framework, the authors utilize the Concrete distribution, a continuous relaxation that allows for backpropagation through categorical variables.

Key Insights

  • Structure over Flatness: Forcing every latent dimension to be independent is often too restrictive. HFVAE allows for structured dependencies, which leads to cleaner representations.
  • Discrete Anchors: By explicitly modeling discrete variables for identity, the model prevents "identity bleed." For example, changing the "thickness" of a digit doesn't cause it to morph into a different number.
  • Zero-Shot Generalization: The separation of "what" an object is from "how" it looks enables the synthesis of unseen feature combinations, such as a specific digit style never encountered during training.

Experimental Results

The HFVAE was evaluated across diverse domains, including handwritten digits (MNIST), 2D shapes (dSprites), and celebrity faces (CelebA).

Qualitative comparison of attribute disentanglement on CelebA between HFVAE and beta-VAE

Qualitatively, HFVAE demonstrates superior disentanglement. As shown in the CelebA traversals, HFVAE maintains facial identity more consistently while varying specific attributes like orientation or smiling. In contrast, $\beta$-VAE often suffers from entangled features where changing one attribute inadvertently affects others, a phenomenon also observed in MNIST experiments where $\beta$-VAE would change a digit's identity while attempting to adjust its thickness.

Quantitatively, the model achieved state-of-the-art disentanglement scores on the dSprites dataset, particularly in isolating discrete shape classes from continuous spatial factors. Furthermore, in text-based topic modeling (20NewsGroups), HFVAE successfully identified meaningful correlations between related topics (e.g., religion and politics) while maintaining their distinctness from unrelated categories.

Conclusion

The Hierarchically Factorized VAE provides a robust framework for learning structured latent representations. While it requires more careful hyperparameter tuning and some prior intuition about data hierarchy, its ability to anchor discrete identities and manage complex dependencies represents a significant step forward for unsupervised representation learning. Future work may focus on automated discovery of these hierarchical structures through causal inference.

Summary updated

Abstract

Deep latent-variable models learn representations of high-dimensional data in an unsupervised manner. A number of recent efforts have focused on learning representations that disentangle statistically independent axes of variation, often by introducing suitable modifications of the objective function. We synthesize this growing body of literature by formulating a generalization of the evidence lower bound that explicitly represents the trade-offs between sparsity of the latent code, bijectivity of representations, and coverage of the support of the empirical data distribution. Our objective is also suitable to learning hierarchical representations that disentangle blocks of variables whilst allowing for some degree of correlations within blocks. Experiments on a range of datasets demonstrate that learned representations contain interpretable features, are able to learn discrete attributes, and generalize to unseen combinations of factors.
BibTeX
@inproceedings{esmaeili2019hierarchical,
  author = {Babak Esmaeili and Hao Wu and Sarthak Jain and N. Siddharth and Brooks Paige and Jan-Willem van de Meent},
  title = {{Hierarchical Disentangled Representations}},
  booktitle = {International Conference on Artificial Intelligence and Statistics},
  year = {2019},
}
Figure