Neal’s Funnel Distribution¶
-
class
pints.toy.
NealsFunnelLogPDF
(dimensions=10)[source]¶ Toy distribution based on a d-dimensional distribution of the form,
\[f(x_1, x_2,...,x_d,\nu) = \left[\prod_{i=1}^d\mathcal{N}(x_i|0,e^{\nu/2})\right] \times \mathcal{N}(\nu|0,3)\]where
x
is a d-dimensional real. This distribution was introduced in [1].Extends
pints.toy.ToyLogPDF
.Parameters: dimensions (int) – The dimensionality of funnel (by default equal to 10) which must exceed 1. References
[1] “Slice sampling”. R. Neal, Annals of statistics, 705 (2003) https://doi.org/10.1214/aos/1056562461 -
kl_divergence
(samples)[source]¶ Calculates the KL divergence of samples of the \(nu\) parameter of Neal’s funnel from the analytic \(\mathcal{N}(0, 3)\) result.
-