stheno.model.gp module¶
-
class
stheno.model.gp.
GP
[source]¶ Bases:
stheno.random.RandomProcess
Gaussian process.
- Parameters
mean (
mlkernels.Mean
, optional) – Mean function of the process. Defaults to zero.kernel (
mlkernels.Kernel
) – Kernel of the process.measure (
measure.Measure
) – Measure to attach to. Must be given as a keyword argument.name (str, optional) – Name. Must be given as a keyword argument.
-
condition
(*args)[source]¶ Condition self.measure on data and obtain the posterior GP.
See
measure.Measure.condition()
for a description of the arguments.- Returns
Posterior GP.
- Return type
-
diff
(dim=0)[source]¶ Differentiate the GP. See
measure.Measure.diff()
.
-
diff_approx
(deriv=1, order=6)[source]¶ Approximate the derivative of the GP by constructing a finite difference approximation.
- Parameters
deriv (int, optional) – Order of the derivative. Defaults to 1.
order (int, optional) – Order of the estimate. Defaults to 6.
- Returns
Approximation of the derivative of the GP.
- Return type
-
display
(formatter=<function GP.<lambda>>)[source]¶ Display the GP.
- Parameters
formatter (function, optional) – Function to format values.
- Returns
GP as a string.
- Return type
str
-
property
kernel
¶ Kernel of the GP.
-
property
mean
¶ Mean function of the GP.
-
property
measure
¶ Measure that the GP was constructed with.
-
property
name
¶ Name of the GP.
-
select
(*dims)[source]¶ Select dimensions from the input. See
measure.Measure.select()
.
-
shift
(shift)[source]¶ Shift the GP. See
measure.Measure.shift()
.
-
property
stationary
¶ Stationarity of the GP.
-
stretch
(stretch)[source]¶ Stretch the GP. See
measure.Measure.stretch()
.
-
transform
(f)[source]¶ Input transform the GP. See
measure.Measure.transform()
.
-
stheno.model.gp.
assert_same_measure
(*ps)[source]¶ Assert that processes are associated to the same measure.
- Parameters
*ps (
gp.GP
) – Processes.