syne_tune.optimizer.schedulers.searchers.bayesopt.gpautograd.likelihood module

class syne_tune.optimizer.schedulers.searchers.bayesopt.gpautograd.likelihood.MarginalLikelihood(prefix=None, params=None)[source]

Bases: Block

Interface for marginal likelihood of Gaussian-linear model.

get_posterior_state(data)[source]
Return type:

PosteriorState

forward(data)[source]

Overrides to implement forward computation using NDArray. Only accepts positional arguments. Parameters ———- *args : list of NDArray

Input tensors.

param_encoding_pairs()[source]

Return a list of tuples with the Gluon parameters of the likelihood and their respective encodings

Return type:

List[tuple]

box_constraints_internal()[source]
Return type:

Dict[str, Tuple[float, float]]

Returns:

Box constraints for all the underlying parameters

get_noise_variance(as_ndarray=False)[source]
get_params()[source]
Return type:

Dict[str, ndarray]

set_params(param_dict)[source]
reset_params(random_state)[source]

Reset hyperparameters to their initial values (or resample them).

data_precomputations(data, overwrite=False)[source]

Some models require precomputations based on data. Precomputed variables are appended to data. This is done only if not already included in data, unless overwrite is True.

Parameters:
  • data (Dict[str, Any]) –

  • overwrite (bool) –

on_fit_start(data)[source]

Called at the beginning of fit.

Parameters:

data (Dict[str, Any]) – Argument passed to fit

class syne_tune.optimizer.schedulers.searchers.bayesopt.gpautograd.likelihood.GaussianProcessMarginalLikelihood(kernel, mean=None, target_transform=None, initial_noise_variance=None, encoding_type=None, **kwargs)[source]

Bases: MarginalLikelihood

Marginal likelihood of Gaussian process with Gaussian likelihood

Parameters:
  • kernel (KernelFunction) – Kernel function

  • mean (Optional[MeanFunction]) – Mean function which depends on the input X only (by default, a scalar fitted while optimizing the likelihood)

  • target_transform (Optional[ScalarTargetTransform]) – Invertible transform of target values y to latent values z, which are then modelled as Gaussian. Defaults to the identity

  • initial_noise_variance – A scalar to initialize the value of the residual noise variance

static assert_data_entries(data)[source]
get_posterior_state(data)[source]
Return type:

PosteriorState

forward(data)[source]

Overrides to implement forward computation using NDArray. Only accepts positional arguments. Parameters ———- *args : list of NDArray

Input tensors.

param_encoding_pairs()[source]

Return a list of tuples with the Gluon parameters of the likelihood and their respective encodings

Return type:

List[tuple]

get_noise_variance(as_ndarray=False)[source]
get_params()[source]
Return type:

Dict[str, ndarray]

set_params(param_dict)[source]
on_fit_start(data)[source]

Called at the beginning of fit.

Parameters:

data (Dict[str, Any]) – Argument passed to fit