Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GP ¶
type GP struct { // Configuration NDim int // number of dimensions Simil, Noise Kernel // kernels // Data ThetaSimil, ThetaNoise []float64 // kernel parameters X [][]float64 // inputs Y []float64 // outputs // Optimizations Parallel bool // when true, covariances are computed in parallel // Cached computations L mat.Cholesky // Cholesky decomposition of K Alpha *mat.VecDense // K^-1 y // contains filtered or unexported fields }
Type GP is the barebone implementation of GP.
func (*GP) Gradient ¶
Gradient computes the gradient of the log-likelihood with respect to the parameters and the inputs (GPML:5.9):
∇L = ½ tr((α α^⊤ - Σ^−1) ∂Σ/∂θ), where α = Σ^-1 y
func (*GP) LML ¶
LML computes log marginal likelihood of the kernel given the absorbed observations (GPML:5.8):
L = −½ log|Σ| − ½ y^⊤ α − n/2 log(2π), where α = Σ^-1 y
func (*GP) Observe ¶
Observe computes log marginal likelihood of the parameters given the observations. The argument is the concatenation of log-transformed hyperparameters, inputs, and outputs.
Optionally, the input can be only log-transformed hyperparameters, and then * only hyperparameters are inferred; * inputs must be assigned to fields X, Y of gp.
type Kernel ¶
Type Kernel is the kernel interface, implemented by both covariance and noise kernels.