Sum#

class tinygp.kernels.quasisep.Sum(kernel1: Quasisep, kernel2: Quasisep, use_block: bool = True)[source]#

Bases: Quasisep

A helper to represent the sum of two quasiseparable kernels

Parameters:
  • kernel1 – The first kernel.

  • kernel2 – The second kernel.

  • use_block – If True (default), use Block diagonal matrices for the transition matrices, design matrices, and stationary covariance. If False, use dense block_diag representations instead, which avoids compatibility issues with some operations (e.g. banded noise, product kernels) at a small performance cost for the state-space matrices.

coord_to_sortable(X: tinygp.helpers.JAXArray) tinygp.helpers.JAXArray[source]#

We assume that both kernels use the same coordinates

design_matrix() tinygp.helpers.JAXArray[source]#

The design matrix for the process

evaluate(X1: tinygp.helpers.JAXArray, X2: tinygp.helpers.JAXArray) tinygp.helpers.JAXArray#

The kernel evaluated via the quasiseparable representation

evaluate_diag(X: tinygp.helpers.JAXArray) tinygp.helpers.JAXArray#

For quasiseparable kernels, the variance is simple to compute

observation_model(X: tinygp.helpers.JAXArray) tinygp.helpers.JAXArray[source]#

The observation model for the process

stationary_covariance() tinygp.helpers.JAXArray[source]#

The stationary covariance of the process

to_general_qsm(X1: tinygp.helpers.JAXArray, X2: tinygp.helpers.JAXArray) GeneralQSM#

The generalized quasiseparable representation of this kernel

to_symm_qsm(X: tinygp.helpers.JAXArray) SymmQSM#

The symmetric quasiseparable representation of this kernel

transition_matrix(X1: tinygp.helpers.JAXArray, X2: tinygp.helpers.JAXArray) tinygp.helpers.JAXArray[source]#

The transition matrix between two coordinates