SGD as Free Energy Minimization: A Thermodynamic View on Neural Network Training

Ildus Sadrtdinov, Ivan Klimov, Ekaterina Lobacheva, Dmitry Vetrov
5/29/2025
cs.LG

No confident code implementation found for this paper.

Abstract

We present a thermodynamic interpretation of the stationary behavior of stochastic gradient descent (SGD) under fixed learning rates (LRs) in neural network training. We show that SGD implicitly minimizes a free energy function $F=U-TS$, balancing training loss $U$ and the entropy of the weights distribution $S$, with temperature $T$ determined by the LR.

Show full abstract

This perspective offers a new lens on why high LRs prevent training from converging to the loss minima and how different LRs lead to stabilization at different loss levels. We empirically validate the free energy framework on both underparameterized (UP) and overparameterized (OP) models. UP models consistently follow free energy minimization, with temperature increasing monotonically with LR, while for OP models, the temperature effectively drops to zero at low LRs, causing SGD to minimize the loss directly and converge to an optimum. We attribute this mismatch to differences in the signal-to-noise ratio of stochastic gradients near optima, supported by both a toy example and neural network experiments.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{sadrtdinov2025free,
  title  = {SGD as Free Energy Minimization: A Thermodynamic View on Neural Network Training},
  author = {Ildus Sadrtdinov and Ivan Klimov and Ekaterina Lobacheva and Dmitry Vetrov},
  year   = {2025},
  eprint = {2505.23489},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2505.23489v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2505.23489.svg)](https://codeofpaper.com/paper/2505.23489)

Discussion