ConeKernel#
- class datafold.pcfold.ConeKernel(zeta=0.0, epsilon=1.0, fd_accuracy=4, distance=None)[source]#
Bases:
TSCManifoldKernel
Compute a dynamically adapted cone kernel on time series collection data.
The equations below describe the kernel evaluation and are taken from the referenced paper below.
A single kernel evaluation between time series samples and is computed with
where,
is the angle between samples,
is a difference vector between the point pairs,
is the (constant) time sampling in the time series,
is an additional scaling parameter of the kernel bandwidth,
is the parameter to control the angular influence, and
is the approximation of the dynamical vector field. The approximation is carried out with , a -th order accurate central finite difference (in a sense that ) with associated weights .
Note
In the centered finite difference the time values are shifted such that no samples are taken from the future. For exmaple, for the scheme , at time , then the new assigned time value is t+1. See also
TSCAccessor.time_derivative()
.- Parameters:
zeta (
float
) – A scalar between to control the angular influence. The weight from one point to a neighboring point is increased if the relative displacement vector is aligned with the dynamical flow. The special case of zeta=0, corresponds to the so-called “Non-Linear Laplacian Spectral Analysis” kernel (NLSA).epsilon (
float
) – An additional scaling parameter with which the kernel scale can be adapted to the actual time sampling frequency.fd_accuracy (
int
) – The accuracy of the centered finite difference scheme ( in the description). Note, that the higher the order the more smaples are required in a warm-up phase, where the centered scheme cannot be evaluated with the given accuracy. All samples from this warm-up phase are dropped in the kernel evaluation.
- Variables:
timederiv_X (np.ndarray) – The time derivative from the finite difference scheme for the reference data X. Required for the component-wise evaluation and only available after a pairse evaluation of the kernel.
norm_timederiv_X (np.ndarray) – Norm of the time derivative for the reference data X. Required for the component-wise evaluation and only available after a pairse evaluation of the kernel.
References
Giannakis [2015] (the equations are taken from the arXiv version)
Methods Summary
__call__
(X[, Y])Compute kernel matrix.
Methods Documentation