Sequences of Bernoulli Outcomes with the Same Probability
A first-principles probability note on why conditioning on the total
count makes all Bernoulli sequences with exactly k
successes equally likely.
Notes, derivations, and small experiments from my ongoing study of diffusion and generative models.
I'm working through a 52-week curriculum at my own pace, starting with probability and linear algebra and moving toward diffusion models, SDEs, and flow matching. These posts are where I share the questions I'm working through, the things I try, and what I think I learned.
Read from the beginning or pick a theme. The notes follow publication order, so you can follow the questions as they developed.
From conditioning and expectation to Gaussian scores and the limits of denoising.
A first-principles probability note on why conditioning on the total
count makes all Bernoulli sequences with exactly k
successes equally likely.
A diffusion note on what it really means for noisy images to stay centered around the original image on average.
A derivation-driven note on why the score of a one-dimensional Gaussian points toward higher log-density, which means back toward the mean.
A conditional-expectation note on why denoising under squared error is estimation, not exact inversion.
An interactive look at how covariance reshapes the score of a multivariate Gaussian, and why the direction of higher density does not always point straight to the mean.
Change of variables, posterior averages, a toy score-matching experiment, and reverse steps.
A short derivation of the density of a transformed random variable, with intuition for how the Jacobian compensates for stretched lengths and areas.
A derivation of how the noisy marginal score connects to the posterior conditional mean through an average over plausible clean samples.
A small experiment comparing two ways to train a toy neural network to learn the score of a noisy three-component Gaussian mixture.
A daily-life example using car and train commute-time distributions to understand why KL divergence is asymmetric and how it can be used to compare distributions.
A small-step Bayes derivation showing why the reverse conditional can be approximated by a Gaussian even when the previous-state marginal is not Gaussian.
Connecting the forward process to affine transformations, then asking what PCA leaves out.
A derivation and geometric playground connecting the affine Gaussian transformation in a diffusion forward process to covariance and the Jacobian determinant.
A geometric derivation of why PCA reconstruction mean-squared error equals the sum of the discarded eigenvalues, through orthogonal projections and a 2D example.
From sampled latent vectors to expected reconstruction losses.
Why averaging sampled reconstruction losses estimates an expectation in a VAE, through the law of large numbers and an indicator-variable approach to integration.
Browse all writing or subscribe via RSS for new notes.