Class: Kernel
Base class for all kernels.
Constructors
new Kernel()
new Kernel(
opts
?):Kernel
Parameters
Parameter | Type | Description |
---|---|---|
opts ? | object | - |
opts.bounds ? | ArrayLike [] | The log-transformed bounds on the kernel’s hyperparameters theta |
Returns Kernel
Defined in generated/gaussian_process/kernels/Kernel.ts:21
Properties
Property | Type | Default value | Defined in |
---|---|---|---|
_isDisposed | boolean | false | generated/gaussian_process/kernels/Kernel.ts:19 |
_isInitialized | boolean | false | generated/gaussian_process/kernels/Kernel.ts:18 |
_py | PythonBridge | undefined | generated/gaussian_process/kernels/Kernel.ts:17 |
id | string | undefined | generated/gaussian_process/kernels/Kernel.ts:14 |
opts | any | undefined | generated/gaussian_process/kernels/Kernel.ts:15 |
Accessors
py
Get Signature
get py():
PythonBridge
Returns PythonBridge
Set Signature
set py(
pythonBridge
):void
Parameters
Parameter | Type |
---|---|
pythonBridge | PythonBridge |
Returns void
Defined in generated/gaussian_process/kernels/Kernel.ts:31
Methods
__call__()
__call__(
opts
):Promise
<any
>
Evaluate the kernel.
Parameters
Parameter | Type |
---|---|
opts | object |
Returns Promise
<any
>
Defined in generated/gaussian_process/kernels/Kernel.ts:99
clone_with_theta()
clone_with_theta(
opts
):Promise
<any
>
Returns a clone of self with given hyperparameters theta.
Parameters
Parameter | Type | Description |
---|---|---|
opts | object | - |
opts.theta ? | ArrayLike | The hyperparameters |
Returns Promise
<any
>
Defined in generated/gaussian_process/kernels/Kernel.ts:125
diag()
diag(
opts
):Promise
<ArrayLike
>
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.
Parameters
Parameter | 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/Kernel.ts:159
dispose()
dispose():
Promise
<void
>
Disposes of the underlying Python resources.
Once dispose()
is called, the instance is no longer usable.
Returns Promise
<void
>
Defined in generated/gaussian_process/kernels/Kernel.ts:82
init()
init(
py
):Promise
<void
>
Initializes the underlying Python resources.
This instance is not usable until the Promise
returned by init()
resolves.
Parameters
Parameter | Type |
---|---|
py | PythonBridge |
Returns Promise
<void
>
Defined in generated/gaussian_process/kernels/Kernel.ts:44
is_stationary()
is_stationary(
opts
):Promise
<any
>
Returns whether the kernel is stationary.
Parameters
Parameter | Type |
---|---|
opts | object |
Returns Promise
<any
>