class_docstr: Inverse gamma distribution with an upper bound on sampled values.
code: def _sample_n(self, n, seed=None):
      # TODO(b/151571025): revert to `super()._sample_n` once the InverseGamma
      # sampler is XLA-able.
      xs = 1.0 / gamma.Gamma(
          concentration=self.concentration, rate=self.scale
      ).sample(n, seed=seed)
      if self._upper_bound is not None:
          xs = tf.minimum(xs, self._upper_bound)
      return xs
  
imports: import collections
  import tensorflow.compat.v2
  from tensorflow_probability.python.bijectors import softplus
  from tensorflow_probability.python.distributions import bernoulli
  from tensorflow_probability.python.distributions import gamma
  from tensorflow_probability.python.distributions import inverse_gamma
  from tensorflow_probability.python.distributions import joint_distribution_auto_batched
  from tensorflow_probability.python.distributions import sample
  from tensorflow_probability.python.experimental.distributions.mvn_precision_factor_linop import MultivariateNormalPrecisionFactorLinearOperator
  from tensorflow_probability.python.internal import dtype_util
  from tensorflow_probability.python.internal import parameter_properties
  from tensorflow_probability.python.internal import prefer_static
  from tensorflow_probability.python.internal import samplers
  from tensorflow_probability.python.internal import vectorization_util
  from tensorflow_probability.python.mcmc.internal import util
label_desc: Use image node_id 3 for calling the InverseGammaWithSampleUpperBound obj's underlying member method code with example usage: obj._sample_n(n, seed) and returns: xs