nami_toys.parameterised#
Classes
|
Gaussian mixture whose signal location depends on a parameter \(\theta\). |
- class nami_toys.parameterised.ParameterisedGaussian(sig_loc=<factory>, sig_cov=<factory>, bkg_loc=<factory>, bkg_cov=<factory>, sig_frac=0.3, param_dim=0)[source]#
Bases:
objectGaussian mixture whose signal location depends on a parameter \(\theta\).
The background distribution is fixed while the signal mean is set to \(\theta\) along
param_dim, keeping the base mean elsewhere.- Parameters:
sig_loc (
Tensor) – Base signal mean(d,); entry at param_dim is replaced by theta.sig_cov (
Tensor) – Signal covariance(d, d)(fixed).bkg_loc (
Tensor) – Background mean and covariance (fixed).bkg_cov (
Tensor) – Background mean and covariance (fixed).sig_frac (
float) – Expected signal fraction.param_dim (
int) – Dimension of the mean vector that theta controls.
- property bkg: MultivariateNormal#
- generate(theta, n_expected, *, generator=None)[source]#
Draw a Poisson-fluctuated dataset at the given theta.
- Return type:
- Parameters:
- log_likelihood_ratio(x, theta)[source]#
Per-event log-likelihood ratio \(\log p(x \mid \text{sig}, \theta) - \log p(x \mid \text{bkg})\).