class LaplacianKernel¶
- class deeptime.kernels.LaplacianKernel(sigma)¶
Implementation of the Laplacian kernel
where is the bandwidth of the kernel.
Methods
apply
(data_1, data_2)Applies the kernel to data arrays.
gram
(data)Computes the corresponding Gram matrix, see also
apply()
.- __call__(x, y)¶
Computes the value of the kernel at two specific points.
- Parameters:
x ((d,) ndarray) – X point.
y ((d,) ndarray) – Y point.
- Returns:
kxy – The kernel evaluation .
- Return type:
float
Notes
This dispatches to
_evaluate()
which is an interface method intended to be overridden by a specific kernel implementation.
- apply(data_1: ndarray, data_2: ndarray) ndarray ¶
Applies the kernel to data arrays.
Given and , it yields a kernel matrix
Note that this corresponds to the kernel Gramian in case .
- Parameters:
data_1 ((T_1, d) ndarray) – Data array.
data_2 ((T_2, d) ndarray) – Data array.
- Returns:
K – The kernel matrix.
- Return type:
(T_1, T_2) ndarray