# Brain-like Variational Inference

arXiv: https://arxiv.org/abs/2410.19315 · HTML: https://mlsanity.com/paper/2410.19315/

## Key facts

- Cited by 6 papers in the map (data through 14 Oct 2026).
- First posted on arXiv 25 Oct 2024.

## Built on by (most cited first, 6 of 6)

- [Stop Probing, Start Coding: Why Linear Probes and Sparse Autoencoders Fail at Compositional Generalisation](https://mlsanity.com/paper/2603.28744/) (2026)
- [Inferring response times of perceptual decisions with Poisson variational autoencoders](https://mlsanity.com/paper/2511.11480/) (2025)
- [A hitchhiker's guide to Poisson gradient estimation](https://mlsanity.com/paper/2602.03896/) (2026)
- [Iterative Amortized Hierarchical VAE](https://mlsanity.com/paper/2601.15894/) (2026)
- [Metabolic cost of information processing in Poisson variational autoencoders](https://mlsanity.com/paper/2602.13421/) (2026)
- [Spike-based Belief Propagation in Nonlinear Dynamical Systems](https://mlsanity.com/paper/2608.19907/) (2026)

## Abstract (arXiv)

Inference in both brains and machines can be formalized by optimizing a shared objective: maximizing the evidence lower bound (ELBO) in machine learning, or minimizing variational free energy (F) in neuroscience (ELBO = -F). While this equivalence suggests a unifying framework, it leaves open how inference is implemented in neural systems. Here, we introduce FOND (Free energy Online Natural-gradient Dynamics), a framework that derives neural inference dynamics from three principles: (1) natural gradients on F, (2) online belief updating, and (3) iterative refinement. We apply FOND to derive iP-VAE (iterative Poisson variational autoencoder), a recurrent spiking neural network that performs variational inference through membrane potential dynamics, replacing amortized encoders with iterative inference updates. Theoretically, iP-VAE yields several desirable features such as emergent normalization via lateral competition, and hardware-efficient integer spike count representations. Empirically, iP-VAE outperforms both standard VAEs and Gaussian-based predictive coding models in sparsity, reconstruction, and biological plausibility, and scales to complex color image datasets such as CelebA. iP-VAE also exhibits strong generalization to out-of-distribution inputs, exceeding hybrid iterative-amortized VAEs. These results demonstrate how deriving inference algorithms from first principles can yield concrete architectures that are simultaneously biologically plausible and empirically effective.
