class_docstr: Kernel supporting Kronecker style multitask Gaussian processes (where every data point is evaluated at every
  task) using :class:`gpytorch.kernels.IndexKernel` as a basic multitask kernel.
  
  Given a base covariance module to be used for the data, :math:`K_{XX}`, this kernel computes a task kernel of
  specified size :math:`K_{TT}` and returns :math:`K = K_{TT} \otimes K_{XX}`. as an
  :obj:`~linear_operator.operators.KroneckerProductLinearOperator`.
  
  :param ~gpytorch.kernels.Kernel data_covar_module: Kernel to use as the data kernel.
  :param int num_tasks: Number of tasks
  :param int rank: (default 1) Rank of index kernel to use for task covariance matrix.
  :param ~gpytorch.priors.Prior task_covar_prior: (default None) Prior to use for task kernel.
      See :class:`gpytorch.kernels.IndexKernel` for details.
  :param dict kwargs: Additional arguments to pass to the kernel.
class_docstr_tok: ["Kernel","supporting","Kronecker","style","multitask","Gaussian","processes","(","where","every","data","point","is","evaluated","at","every","task",")","using",":","class",":","`","gpytorch.kernels.IndexKernel","`","as","a","basic","multitask","kernel",".","Given","a","base","covariance","module","to","be","used","for","the","data",",",":","math",":","`","K_","{","XX","}","`",",","this","kernel","computes","a","task","kernel","of","specified","size",":","math",":","`","K_","{","TT","}","`","and","returns",":","math",":","`","K","=","K_","{","TT","}","\\otimes","K_","{","XX","}","`",".","as","an",":","obj",":","`","~linear_operator.operators.KroneckerProductLinearOperator","`",".",":","param","~gpytorch.kernels.Kernel","data_covar_module",":","Kernel","to","use","as","the","data","kernel",".",":","param","int","num_tasks",":","Number","of","tasks",":","param","int","rank",":","(","default","1",")","Rank","of","index","kernel","to","use","for","task","covariance","matrix",".",":","param","~gpytorch.priors.Prior","task_covar_prior",":","(","default","None",")","Prior","to","use","for","task","kernel",".","See",":","class",":","`","gpytorch.kernels.IndexKernel","`","for","details",".",":","param","dict","kwargs",":","Additional","arguments","to","pass","to","the","kernel","."]
code: def __init__(
      self,
      data_covar_module: Kernel,
      num_tasks: int,
      rank: Optional[int] = 1,
      task_covar_prior: Optional[Prior] = None,
      **kwargs,
  ):
      """"""
      super(MultitaskKernel, self).__init__(**kwargs)
      self.task_covar_module = IndexKernel(
          num_tasks=num_tasks,
          batch_shape=self.batch_shape,
          rank=rank,
          prior=task_covar_prior,
      )
      self.data_covar_module = data_covar_module
      self.num_tasks = num_tasks
  
file_path: gpytorch/gpytorch/kernels/multitask_kernel.py
imports: from typing import Optional
  from linear_operator import to_linear_operator
  from linear_operator.operators import KroneckerProductLinearOperator
  from ..priors import Prior
  from .index_kernel import IndexKernel
  from .kernel import Kernel
label_desc: Use image node_id 1 to create a new MultitaskKernel object from inherited base classes: Kernel with example: obj = MultitaskKernel(data_covar_module, num_tasks, rank, task_covar_prior)