class_docstr: Naive Marsaglia & Tsang rejection sampler for standard Gamma distibution.
  This assumes `concentration >= 1` and does not boost `concentration` or augment shape.
code: def expand(self, batch_shape, _instance=None):
      new = self._get_checked_instance(
          RejectionStandardGamma, _instance
      )
      batch_shape = torch.Size(batch_shape)
      new.concentration = self.concentration.expand(batch_shape)
      new._standard_gamma = self._standard_gamma.expand(batch_shape)
      new._d = self._d.expand(batch_shape)
      new._c = self._c.expand(batch_shape)
      # Compute log scale using Gamma.log_prob().
      x = new._d.detach()  # just an arbitrary x.
      log_scale = (
          new.propose_log_prob(x)
          + new.log_prob_accept(x)
          - new.log_prob(x)
      )
      super(RejectionStandardGamma, new).__init__(
          new.propose,
          new.log_prob_accept,
          log_scale,
          batch_shape=batch_shape,
          event_shape=(),
      )
      new._validate_args = self._validate_args
      return new
  
imports: import torch
  from pyro.distributions.rejector import Rejector
  from pyro.distributions.score_parts import ScoreParts
  from pyro.distributions.torch import Beta, Dirichlet, Gamma, Normal
  from pyro.distributions.util import copy_docs_from, weakmethod
label_desc: Use image node_id 2 for calling the RejectionStandardGamma obj's underlying member method code with example usage: obj.expand(batch_shape, _instance) and returns: new