Ask what should change under a concrete input, then trace that expectation through the equation.
Foundation Lab
Energy-Based Models & Score Functions
Unifies discriminative and generative modeling: classifier logits ARE energy differences
Selected Foundation Object
Keep the equation fixed; move through the evidence.
The partition function Z is intractable—all EBM training tricks avoid computing it
Use the key equation and canonical papers as the available witnesses, without implying that a runnable panel exists.
The useful learning product is the reusable mechanism you can carry into another model, paper, or engineering tradeoff.
Use prerequisites, dependents, and semantic links to repair the next gap without leaving the object behind.
Why It Matters for Modern Models
- Unifies discriminative and generative modeling: classifier logits ARE energy differences
- GAN discriminators can be viewed as learning energy functions
- Score-based diffusion models are EBMs trained via denoising score matching
What Tutorials Skip
What is still poorly explained in textbooks and papers:
- The partition function Z is intractable—all EBM training tricks avoid computing it
- Energy = "how wrong this input looks"—low energy = high probability
- MCMC sampling from EBMs is slow; diffusion sidesteps this by learning the denoising path directly
Visualization Status
Core Math (Optional Deep Dive)
If you want intuition first, start with the key equation and cited sources. Come back here for the full walkthrough.
Energy-based models define probability via unnormalized energy:
The score function is the gradient of log-probability:
Contrastive divergence training: