Deriving Neural Network Design and Learning from the Probabilistic Framework of Chain Graphs

Yuesong Shen, Daniel Cremers

Abstract

The last decade has witnessed a boom of deep learning research and applications achieving state-of-the-art results in various domains. However, most advances have been established empirically, and their theoretical analysis remains lacking. One major issue is that our current interpretation of neural networks (NNs) as function approximators is too generic to support in-depth analysis. In this paper, we remedy this by proposing an alternative interpretation that identifies NNs as chain graphs (CGs) and feed-forward as an approximate inference procedure. The CG interpretation specifies the nature of each NN component within the rich theoretical framework of probabilistic graphical models, while at the same time remains general enough to cover real-world NNs with arbitrary depth, multi-branching and varied activations, as well as common structures including convolution / recurrent layers, residual block and dropout. We demonstrate with concrete examples that the CG interpretation can provide novel theoretical support and insights for various NN techniques, as well as derive new deep learning approaches such as the concept of partially collapsed feed-forward inference. It is thus a promising framework that deepens our understanding of neural networks and provides a coherent theoretical formulation for future deep learning research.

Introduction: Beyond the Black Box

For the past decade, deep learning has been the undisputed king of empirical performance. We know that stacking layers and adding "tricks" like Dropout or Residual connections works, but our theoretical understanding often lags behind. We usually describe neural networks (NNs) as "universal function approximators"—a definition so broad it offers little insight into why a specific architecture succeeds or fails.

In their ICLR 2021 paper, Yuesong Shen and Daniel Cremers propose a shift in perspective. Instead of seeing NNs as just a sequence of functions, they interpret them as Chain Graphs (CGs)—a powerful class of Probabilistic Graphical Models (PGMs). This framework seeks a "middle ground": a framework mathematically rich enough to support in-depth analysis but general enough to cover real-world, finite-width architectures used in practice today.

Neural Networks as Layered Chain Graphs

The core of this proposal is the definition of a Layered Chain Graph, where each layer of a neural network is treated as a set of random variables. The authors establish two fundamental links between these worlds:

  1. Feed-Forward as Inference: They prove that if one assumes the relationships between layers are approximately linear, the process of calculating "expected features" in the graph looks exactly like the standard neural network feed-forward pass ($q = g(Wx + b)$).
  2. Distribution-Activation Mapping: The choice of "activation function" is shown to be a choice of the underlying probability distribution for the nodes. For instance, Sigmoid and Tanh emerge from binary nodes, while ReLU and Softplus emerge from "Rectified Gaussian" distributions.
Comparison of various activation functions derived from the Rectified Gaussian distribution within the chain graph framework.

Structural Interpretations and Insights

By using this PGM framework, common architectures can be re-derived with formal justifications. A Residual Block, for example, is mathematically shown to be a "refinement module" that adds a nonlinear extension to a base submodule, naturally increasing representational power.

Mapping between the probabilistic chain graph representation (left) and the corresponding neural network computational block (right).

Further insights include:

  • Dropout as Marginalization: Dropout is equivalent to adding auxiliary Bernoulli random variables to the graph. The common heuristic of scaling weights at test time is revealed to be a formal marginalization step.
  • Weight Decay: The linear approximation used to link NNs to CGs is only accurate when weights are small, providing a theoretical basis for why weight decay is crucial for stability.
  • RNN Architectures: Through the lens of chain graphs, Independently RNNs (IndRNNs) are shown to enforce specific intra-layer conditional independence, explaining their effectiveness for long sequences.

Partially Collapsed Feed-Forward (PCFF)

Leveraging PGM theory, the authors propose a novel stochastic regularization method called Partially Collapsed Feed-Forward (PCFF). Instead of adding binary noise like Dropout, PCFF randomly chooses a portion of nodes to "sample" (stochastic) while the rest are "collapsed" (deterministic). This offers a new way to balance the bias-variance trade-off during training.

Empirical Results and Conclusion

The authors validated their findings on standard benchmarks including MNIST, FashionMNIST, and CIFAR-10 (using ResNet20). PCFF showed more consistent performance across a wide range of sample rates compared to Dropout, which often deteriorated at high drop rates. PCFF achieved comparable or superior test errors across all tested datasets.

While the framework currently focuses on a specific subset of techniques, it opens the door to applying the rich history of PGM research—such as message passing or advanced sampling schemes—to discover entirely new neural network training procedures and architectures. The CG interpretation provides a promising path toward a more coherent theoretical formulation for deep learning.

Summary updated

Abstract

The last decade has witnessed a boom of deep learning research and applications achieving state-of-the-art results in various domains. However, most advances have been established empirically, and their theoretical analysis remains lacking. One major issue is that our current interpretation of neural networks (NNs) as function approximators is too generic to support in-depth analysis. In this paper, we remedy this by proposing an alternative interpretation that identifies NNs as chain graphs (CGs) and feed-forward as an approximate inference procedure. The CG interpretation specifies the nature of each NN component within the rich theoretical framework of probabilistic graphical models, while at the same time remains general enough to cover real-world NNs with arbitrary depth, multi-branching and varied activations, as well as common structures including convolution / recurrent layers, residual block and dropout. We demonstrate with concrete examples that the CG interpretation can provide novel theoretical support and insights for various NN techniques, as well as derive new deep learning approaches such as the concept of partially collapsed feed-forward inference. It is thus a promising framework that deepens our understanding of neural networks and provides a coherent theoretical formulation for future deep learning research.
BibTeX
@misc{shen2020deriving,
  author = {Yuesong Shen and Daniel Cremers},
  title = {{Deriving Neural Network Design and Learning from the Probabilistic Framework of Chain Graphs}},
  year = {2020},
  eprint = {2006.16856},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2006.16856},
}
Figure