Skip to content

Latest commit

 

History

History
250 lines (146 loc) · 7.23 KB

DotProduct.md

File metadata and controls

250 lines (146 loc) · 7.23 KB

DotProduct

Dot-Product kernel.

The DotProduct kernel is non-stationary and can be obtained from linear regression by putting \(N(0, 1)\) priors on the coefficients of \(x_d (d = 1, . . . , D)\) and a prior of \(N(0, \sigma_0^2)\) on the bias. The DotProduct kernel is invariant to a rotation of the coordinates about the origin, but not translations. It is parameterized by a parameter sigma_0 \(\sigma\) which controls the inhomogenity of the kernel. For \(\sigma_0^2 =0\), the kernel is called the homogeneous linear kernel, otherwise it is inhomogeneous. The kernel is given by

Python Reference

Constructors

constructor()

Signature

new DotProduct(opts?: object): DotProduct;

Parameters

Name Type Description
opts? object -
opts.sigma_0? any Parameter controlling the inhomogenity of the kernel. If sigma_0=0, the kernel is homogeneous. Default Value 1
opts.sigma_0_bounds? "fixed" The lower and upper bound on ‘sigma_0’. If set to “fixed”, ‘sigma_0’ cannot be changed during hyperparameter tuning.

Returns

DotProduct

Defined in: generated/gaussian_process/kernels/DotProduct.ts:23

Methods

__call__()

Return the kernel k(X, Y) and optionally its gradient.

Signature

__call__(opts: object): Promise<ArrayLike[]>;

Parameters

Name Type Description
opts object -
opts.X? ArrayLike[] Left argument of the returned kernel k(X, Y)
opts.Y? ArrayLike[] Right argument of the returned kernel k(X, Y). If undefined, k(X, X) if evaluated instead.
opts.eval_gradient? boolean Determines whether the gradient with respect to the log of the kernel hyperparameter is computed. Only supported when Y is undefined. Default Value false

Returns

Promise<ArrayLike[]>

Defined in: generated/gaussian_process/kernels/DotProduct.ts:110

clone_with_theta()

Returns a clone of self with given hyperparameters theta.

Signature

clone_with_theta(opts: object): Promise<any>;

Parameters

Name Type Description
opts object -
opts.theta? ArrayLike The hyperparameters

Returns

Promise<any>

Defined in: generated/gaussian_process/kernels/DotProduct.ts:159

diag()

Returns the diagonal of the kernel k(X, X).

The result of this method is identical to np.diag(self(X)); however, it can be evaluated more efficiently since only the diagonal is evaluated.

Signature

diag(opts: object): Promise<ArrayLike>;

Parameters

Name Type Description
opts object -
opts.X? ArrayLike[] Left argument of the returned kernel k(X, Y).

Returns

Promise<ArrayLike>

Defined in: generated/gaussian_process/kernels/DotProduct.ts:194

dispose()

Disposes of the underlying Python resources.

Once dispose() is called, the instance is no longer usable.

Signature

dispose(): Promise<void>;

Returns

Promise<void>

Defined in: generated/gaussian_process/kernels/DotProduct.ts:93

init()

Initializes the underlying Python resources.

This instance is not usable until the Promise returned by init() resolves.

Signature

init(py: PythonBridge): Promise<void>;

Parameters

Name Type
py PythonBridge

Returns

Promise<void>

Defined in: generated/gaussian_process/kernels/DotProduct.ts:53

is_stationary()

Returns whether the kernel is stationary.

Signature

is_stationary(opts: object): Promise<any>;

Parameters

Name Type
opts object

Returns

Promise<any>

Defined in: generated/gaussian_process/kernels/DotProduct.ts:227

Properties

_isDisposed

boolean = false

Defined in: generated/gaussian_process/kernels/DotProduct.ts:21

_isInitialized

boolean = false

Defined in: generated/gaussian_process/kernels/DotProduct.ts:20

_py

PythonBridge

Defined in: generated/gaussian_process/kernels/DotProduct.ts:19

id

string

Defined in: generated/gaussian_process/kernels/DotProduct.ts:16

opts

any

Defined in: generated/gaussian_process/kernels/DotProduct.ts:17

Accessors

hyperparameter_sigma_0

Signature

hyperparameter_sigma_0(): Promise<any>;

Returns

Promise<any>

Defined in: generated/gaussian_process/kernels/DotProduct.ts:250

py

Signature

py(): PythonBridge;

Returns

PythonBridge

Defined in: generated/gaussian_process/kernels/DotProduct.ts:40

Signature

py(pythonBridge: PythonBridge): void;

Parameters

Name Type
pythonBridge PythonBridge

Returns

void

Defined in: generated/gaussian_process/kernels/DotProduct.ts:44