class_docstr: Abstract base class for Samplers.
  
  Subclasses must implement the `forward` method.
  
  Example:
      This method is usually not called directly, but via the sampler's
      `__call__` method:
      >>> posterior = model.posterior(test_X)
      >>> samples = sampler(posterior)
  
  :meta private:
class_docstr_tok: ["Abstract","base","class","for","Samplers",".","Subclasses","must","implement","the","`","forward","`","method",".","Example",":","This","method","is","usually","not","called","directly",",","but","via","the","sampler's","`","__call__","`","method",":",">",">",">","posterior","=","model.posterior","(","test_X",")",">",">",">","samples","=","sampler","(","posterior",")",":","meta","private",":"]
docstr: Get the shape of the base samples expected by the posterior.
  
  Args:
      posterior: The posterior to sample from.
  
  Returns:
      The extended shape of the base samples expected by the posterior.
docstr_tok: ["Get","the","shape","of","the","base","samples","expected","by","the","posterior",".","Args",":","posterior",":","The","posterior","to","sample","from",".","Returns",":","The","extended","shape","of","the","base","samples","expected","by","the","posterior","."]
code: def _get_extended_base_sample_shape(
      self, posterior: Posterior
  ) -> torch.Size:
      r"""Get the shape of the base samples expected by the posterior.
  
      Args:
          posterior: The posterior to sample from.
  
      Returns:
          The extended shape of the base samples expected by the posterior.
      """
      return self.sample_shape + posterior.base_sample_shape
  
file_path: botorch/botorch/sampling/base.py
imports: from __future__ import annotations
  import warnings
  from abc import ABC, abstractmethod
  from typing import Any, Optional, Tuple
  import torch
  from botorch.exceptions.errors import InputDataError
  from botorch.posteriors import Posterior
  from torch import Tensor
  from torch.nn import Module
label_desc: Use image node_id 5 for calling the MCSampler obj's underlying member method code with example usage: obj._get_extended_base_sample_shape(posterior) and returns: unknown