From a source checkout:
uv sync --dev --extra inference
uv run python examples/synthetic_retrieval.py --seed 42 --output /tmp/tierra-demo.jsonThe model is a baseline transit depth plus a Gaussian-shaped basis function centered at 1.4 microns. Both coefficients have bounded uniform priors. Forty synthetic bins have known independent Gaussian uncertainty. The wavelength is illustrative; the feature is not a species identification or opacity table.
The output records the generated spectrum, injected parameters, priors, sampler
configuration and package versions, plus a canonical input hash. Compare
posterior_mean with analytic_mean, and inspect mean_error_in_analytic_sigma.
The analytic comparison assumes the posterior is far from prior boundaries.
posterior_mean_chi_square is a residual diagnostic, not a detection significance.
posterior.samples are weighted nested-sampling points. Use posterior.weights
for means, variances and posterior prediction. The output also records log evidence,
evidence error and effective sample size. Replaying the same software environment
and seed reproduces the input and sampler sequence; cross-version bitwise identity
is not promised.
The tests additionally compare a one-dimensional Gaussian posterior and known evidence with a real dynesty run. Atmospheric-backend replication is not included.
The source checkout also includes examples/coverage_check.py and complete repeated-noise
records under examples/results/. In 20 runs, nominal 90% intervals covered the
fixed baseline depth in 18 runs and feature amplitude in 16. The recorded Wilson
intervals are wide; the second parameter under-covers in this small experiment.
This is fixed-truth software validation, not prior-predictive SBC.
examples/wasp39_validation.py fits the original authors' tabulated PICASO model
and a flat-depth control to a fixed subset of the published WASP-39b PRISM spectrum.
It verifies data hashes, integrates the high-resolution model over explicit
approximate bins, preserves the weighted posterior, and compares one-parameter
inference to an analytic Gaussian calculation. The fixed template was selected on
these observations, so the conditional comparison is not independent atmospheric
validation. Both models fail the absolute residual check under the implemented
likelihood; see the repository's examples/results/wasp39-prism/README.md for all
measurements, assumptions and reproduction commands.