NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Generative learning for deep networks

Boris Flach, Alexander Shekhovtsov, Ondrej FikararXiv 2017

Introduction

Deep Neural Networks (DNNs) are typically viewed as deterministic mappings from inputs to outputs. While highly effective, they often lack the probabilistic interpretability of Bayesian networks, which are conversely limited by computational intractability. The paper "Generative learning for deep networks" by Flach et al. proposes a bridge between these paradigms through the Stacked (Deep) Conditional Independent Model (DCIM). This framework demonstrates that the standard forward pass of a DNN is a simplified form of approximate Bayesian inference, allowing for a unified model that performs both classification and data generation using shared parameters.

The Stacked Conditional Independent Model (DCIM)

Most modern DNNs are discriminative, modeling the conditional probability $p(y|x)$. While excellent for classification, they do not inherently capture the underlying data distribution $p(x)$. Generative models like Variational Autoencoders (VAEs) or Deep Boltzmann Machines (DBMs) address this but often introduce training complexities or decouple encoder and decoder parameters.

The DCIM addresses this by establishing a probabilistic interpretation of standard DNN architectures:

  1. Probabilistic Foundation: By assuming a directed graphical model where each layer is "strongly conditionally independent," the authors derive that logistic sigmoid and softmax activations are the natural mathematical consequences of calculating expectations of binary random variables.
  2. DNN as Inference: The deterministic forward computation in a DNN is shown to be a first-order Taylor expansion of the marginal distribution in a DCIM. Thus, a standard DNN can be viewed as an efficient approximation of a Bayesian network.
  3. Weight Transposition: To maintain consistency within a single joint distribution, the weights of the recognition (forward) and generation (backward) paths are constrained to be transposes of each other ($W$ and $W^T$).

Bidirectional Learning

The model is trained by optimizing a joint objective function: $$\mathcal{L} = \log p(\text{output} | \text{input}) + \log p(\text{input} | \text{output})$$ This dual objective forces the network to simultaneously excel at classification and data reconstruction, effectively using generative learning as a form of regularization.

Accuracy and loss curves comparing generative and discriminative training regimes on MNIST.

Key Insights and Results

The researchers evaluated the DCIM on the MNIST dataset using both dense and convolutional architectures.

Generative Regularization

A significant finding is that generative training acts as a powerful regularizer. It mitigates overfitting and the "vanishing gradient" problem without requiring common techniques like dropout. As shown in the performance plots, the generative approach achieves competitive validation accuracy (98.9% to 99.0%) with only a negligible drop compared to purely discriminative models.

Capturing Data Distributions

While early iterations produced "mean" (blurry) shapes, refinements allowed the model to capture multi-modal distributions. By sampling from the layer immediately preceding the image, the model can generate various writing styles for the same digit class.

Examples of digits generated by the DCIM model, illustrating its ability to capture diverse writing styles.

Discussion and Limitations

The DCIM provides a formal probabilistic justification for tied weights in autoencoders and offers a new perspective on standard activation functions. However, limitations remain:

  • Generative Fidelity: The image quality is currently lower than that of GANs, capturing the "essence" of data rather than high-frequency details.
  • Activation Constraints: The current derivation applies to sigmoid and tanh; extending this statistical interpretation to ReLU remains an open challenge.
  • Layer Dependencies: The assumption of intra-layer independence could be relaxed by introducing neuron interactions (e.g., Deep CRFs) to better capture complex textures.

In conclusion, this work provides a theoretically grounded framework for integrating generative and discriminative learning, suggesting that the "black box" of deep learning has deep roots in Bayesian statistics.

Reference: Flach, B., Shekhovtsov, A., & Fikar, O. (2017). Generative learning for deep networks. arXiv:1709.08524.

Summary updated

BibTeX
@misc{flach2017generative,
  author = {Boris Flach and Alexander Shekhovtsov and Ondrej Fikar},
  title = {{Generative learning for deep networks}},
  year = {2017},
  eprint = {1709.08524},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1709.08524},
}
Figure