Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

Puff — parameter estimation

Gaussian puff — parameter estimation of a constant emission rate

Given a time-series of concentration observations at a handful of downwind sensors, we invert the puff forward model to recover the source emission rate Q. The setup closely parallels the plume parameter-estimation notebook, but the puff model’s time-axis means each observation carries its own evaluation time — the NUTS posterior absorbs both spatial variation and the puff-cadence structure of the field.

See 00_gaussian_puff_derivation.md for the forward model and plumax.gauss_puff.inference for the NumPyro code.

1. Generate synthetic observations

Set a ground-truth emission rate (0.12 kg/s), run the forward model, sample at four downwind receptors at six time steps, and add Gaussian noise. This is the “observe the truth through a noisy instrument” setup that motivates the inverse problem.

Plot the observed concentration traces alongside the ground-truth field at one receptor to visualise SNR.

<Figure size 900x400 with 1 Axes>

2. NUTS inference with a fixed stability class

LogNormal prior on Q with mean 0.1 and std 0.08 (covers both under- and overestimate scenarios). HalfNormal prior on background. NUTS handles the continuous parameters directly.

Posterior Q: mean = 0.1187 kg/s, std = 0.0001
             90% CI = [0.1185, 0.1189]
True Q: 0.12

Posterior over Q

/tmp/ipykernel_12833/4205934252.py:25: RuntimeWarning: divide by zero encountered in divide
  1.0
<Figure size 750x400 with 1 Axes>

3. Posterior-predictive check

Re-run the forward model at each posterior draw, take the mean and 90% interval, and overlay on the observations. If the bands cover the observations and the posterior mean tracks the trend, the model has captured the data-generating process.

<Figure size 900x400 with 1 Axes>

4. Trace diagnostics

Posterior sample traces and autocorrelation for the two continuous latents. Look for adequate mixing (no long flat segments) and fast decay of autocorrelation.

<Figure size 1000x500 with 4 Axes>
Posterior summary:
  emission_rate: mean=0.1187, std=0.0001, 5th=0.1185, 95th=0.1189
  background:    mean=4.38e-08, std=1.44e-08

What next?

  • Puff — state estimation — when Q is time-varying, a constant-Q posterior is mis-specified. The state-estimation notebook drops the constant assumption via a random-walk prior on Q_i.