Skip to content
BIASED

Autoregressive models

Block 1 of 8~2 min

One value at a time

In Latent diffusion, a sampling step updates a whole latent. Here we take another route: predict one value from the values already known. This gives an exact probability for a complete record, but ordinary sampling must build that record in order.

Imagine a sensor reporting 0 or 1 at each of 12 time steps. There are 212=40962^{12}=4096 possible records. Even two values per step create many combinations. The chain rule rewrites their joint probability:

p(x1,…,xD)=∏i=1Dp(xi∣x<i),x<i=(x1,…,xi−1).p(x_1,\ldots,x_D)=\prod_{i=1}^{D}p(x_i\mid x_{<i}),\qquad x_{<i}=(x_1,\ldots,x_{i-1}).

It follows by repeatedly applying p(a,b)=p(a)p(b∣a)p(a,b)=p(a)p(b\mid a). At a prefix of positive probability, the conditional is defined by the usual ratio. At a zero-probability prefix, any normalized conditional can be assigned: the joint remains zero.

This identity works for any coordinate order. It does not assert independence, a first-order Markov property or physical causation. Those restrictions enter when we choose a model for each factor. For images, a common order is left to right within each row, then top to bottom; colour channels can be ordered R, G, B inside each pixel.

Answers are saved on the server and tied to this browser until you sign in.

Go deeper — optional

Code and labs do not count toward the main percentage or the certificate.

  • Sensor: probability and prefix completionoptional

    Fit a Markov model to synthetic records. Check normalization, bits per symbol and completion of a given prefix. No downloads or third-party libraries.

    ~20 min · easier on a computer · The autoregressive-model lesson; Python lists and functions.

    Self-check in the notebook — not part of mastery or the certificate.