class_docstr: A posterior based on GPyTorch's multi-variate Normal distributions.
docstr: A posterior based on GPyTorch's multi-variate Normal distributions.
  
  Args:
      distribution: A GPyTorch MultivariateNormal (single-output case) or
          MultitaskMultivariateNormal (multi-output case).
      mvn: Deprecated.
docstr_tok: ["A","posterior","based","on","GPyTorch","'s","multi-variate","Normal","distributions",".","Args",":","distribution",":","A","GPyTorch","MultivariateNormal","(","single-output","case",")","or","MultitaskMultivariateNormal","(","multi-output","case",")",".","mvn",":","Deprecated","."]
code: def __init__(
      self,
      distribution: Optional[MultivariateNormal] = None,
      mvn: Optional[MultivariateNormal] = None,
  ) -> None:
      r"""A posterior based on GPyTorch's multi-variate Normal distributions.
  
      Args:
          distribution: A GPyTorch MultivariateNormal (single-output case) or
              MultitaskMultivariateNormal (multi-output case).
          mvn: Deprecated.
      """
      if mvn is not None:
          if distribution is not None:
              raise RuntimeError(
                  "Got both a `distribution` and an `mvn` argument. "
                  "Use the `distribution` only."
              )
          warnings.warn(
              "The `mvn` argument of `GPyTorchPosterior`s has been renamed to "
              "`distribution` and will be removed in a future version.",
              DeprecationWarning,
          )
          distribution = mvn
      if distribution is None:
          raise RuntimeError(
              "GPyTorchPosterior must have a distribution specified."
          )
      super().__init__(distribution=distribution)
      self._is_mt = isinstance(
          distribution, MultitaskMultivariateNormal
      )
  
imports: from __future__ import annotations
  import warnings
  from contextlib import ExitStack
  from typing import Optional, Tuple, TYPE_CHECKING, Union
  import torch
  from botorch.exceptions.errors import BotorchTensorDimensionError
  from botorch.posteriors.base_samples import _reshape_base_samples_non_interleaved
  from botorch.posteriors.torch import TorchPosterior
  from gpytorch.distributions import MultitaskMultivariateNormal, MultivariateNormal
  from linear_operator import settings
  from linear_operator.operators import BlockDiagLinearOperator, DenseLinearOperator, LinearOperator, SumLinearOperator
  from torch import Tensor
  from torch.distributions import Normal
label_desc: Use image node_id 1 to create a new GPyTorchPosterior object from inherited base classes: TorchPosterior with example: obj = GPyTorchPosterior(distribution, mvn)