Data Model
hydra_tod implements a hierarchical Bayesian model for radio telescope
observations. This page describes the mathematical framework.
Observation Model
The time-ordered data (TOD) from a radio telescope is modeled as:
where:
\(d(t)\) is the observed data at time \(t\)
\(T_{\mathrm{sys}}(t)\) is the system temperature
\(n(t)\) is multiplicative correlated noise
\(g(t)\) is the time-varying instrument gain
System Temperature
The system temperature decomposes into sky and local components:
The sky temperature is obtained by projecting a pixelized sky map through the telescope beam:
where \(B(t,p)\) is the beam response at pixel \(p\) and time \(t\), and \(T_p\) is the sky temperature at pixel \(p\).
In matrix form: \(\mathbf{T}_{\mathrm{sky}} = \mathbf{U}_{\mathrm{sky}} \, \boldsymbol{\theta}_{\mathrm{sky}}\).
The local temperature includes receiver noise and noise diode contributions:
parameterized as \(\mathbf{T}_{\mathrm{loc}} = \mathbf{U}_{\mathrm{loc}} \, \boldsymbol{\theta}_{\mathrm{loc}}\).
Gain Model
The instrument gain is parameterized using Legendre polynomial basis functions:
Linear model: \(g(t) = \mathbf{G} \, \mathbf{p}_g\)
Log-linear model: \(g(t) = \exp(\mathbf{G} \, \mathbf{p}_g)\)
Factorized model: \(g(t) = g_0 \cdot (\mathbf{G} \, \mathbf{p}_g + 1)\)
where \(\mathbf{G}\) is the polynomial projection matrix and \(\mathbf{p}_g\) are the gain coefficients.
Gibbs Sampling
The joint posterior is sampled using a Gibbs sampler that alternates between conditionally conjugate updates:
Sample gains \(\mathbf{p}_g \mid T_{\mathrm{sys}}, n, d\)
Sample local temperatures \(\boldsymbol{\theta}_{\mathrm{loc}} \mid T_{\mathrm{sky}}, g, n, d\)
Sample sky temperatures \(\boldsymbol{\theta}_{\mathrm{sky}} \mid T_{\mathrm{loc}}, g, n, d\)
Sample noise parameters \((\log f_0, \alpha) \mid T_{\mathrm{sys}}, g, d\)
Steps 1–3 are conjugate Gaussian updates solved via iterative linear solvers. Step 4 uses MCMC (emcee) or NUTS (NumPyro) to sample from the non-Gaussian noise parameter posterior.
For full details, see Zhang et al. (2026), RASTI, rzag024.