def __init__(self, train_x, train_y, likelihood): super(MultitaskModel, self).__init__(train_x, train_y, likelihood) self.mean_module = gpytorch.means.MultitaskMean( gpytorch.means.ConstantMean(), num_tasks=2) # self.mean_module = gpytorch.means.ConstantMean() # self.covar_module = mk_kernel.MultitaskRBFKernel(num_tasks=2,log_task_lengthscales=torch.Tensor([math.log(2.5), math.log(0.3)])) self.covar_module = mk_kernel.MultitaskRBFKernel(num_tasks=2)
def __init__(self, train_x, train_y, likelihood): super(MultitaskModel, self).__init__(train_x, train_y, likelihood) self.mean_module = gpytorch.means.MultitaskMean( gpytorch.means.ConstantMean(), num_tasks=2) self.covar_module = mk_kernel.MultitaskRBFKernel(num_tasks=2)