Ejemplo n.º 1
0
 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=_num_tasks
     )
     self.covar_module = mk_kernel.MultiKernel(
         [gpytorch.kernels.RBFKernel() for _ in range(_num_tasks)]
     )
Ejemplo n.º 2
0
 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.MultiKernel(
         [gpytorch.kernels.RBFKernel(),
          gpytorch.kernels.RBFKernel()])
Ejemplo n.º 3
0
 def __init__(self, train_x, train_y, likelihood):
     super(MKModel, self).__init__(train_x, train_y, likelihood)
     self.mean_module = gpytorch.means.MultitaskMean(
         gpytorch.means.ConstantMean(), num_tasks=n_tasks)
     self.covar_module = mk_kernel.MultiKernel(kern_list)