construct_model#

gpjax.gps.construct_model(prior, likelihood)[source]#

Construct the joint model for a prior/likelihood pair.

Selects the concrete JointModel subclass from the likelihood’s conjugacy. This is what prior * likelihood calls.

Parameters:
Returns:

A ConjugateModel for Gaussian likelihoods, a

NonConjugateModel otherwise.

Return type:

JointModel

Raises:

ValueError – For heteroscedastic likelihoods, which carry a second prior and must be constructed directly via HeteroscedasticModel(prior, likelihood, noise_prior=...).