# pymc.gp.cov.Periodic#

class pymc.gp.cov.Periodic(input_dim, period, ls=None, ls_inv=None, active_dims=None)[source]#

The Periodic kernel.

$k(x, x') = \mathrm{exp}\left( -\frac{\mathrm{sin}^2(\pi |x-x'| \frac{1}{T})}{2\ell^2} \right)$

Notes

Note that the scaling factor for this kernel is different compared to the more common definition (see [1]). Here, 0.5 is in the exponent instead of the more common value, 2. Divide the length-scale by 2 when initializing the kernel to recover the standard definition.

References

1

David Duvenaud, “The Kernel Cookbook” https://www.cs.toronto.edu/~duvenaud/cookbook/

Methods

 Periodic.__init__(input_dim, period[, ls, ...]) Periodic.full(X[, Xs])

Attributes

 n_dims The dimensionality of the input, as taken from the active_dims.