code: def testSampleUnbiasedBroadcastingBatch(self):
      probs = self._rng.rand(4, 3).astype(np.float64)
      counts = np.float64([4, 11.0, 20.0])
      dist = binomial_lib.Binomial(
          total_count=counts, probs=probs, validate_args=True
      )
      n = int(1e5)
      x = dist.sample(n, seed=test_util.test_seed())
      sample_mean, sample_variance = tf.nn.moments(x=x, axes=0)
      [
          sample_mean_,
          sample_variance_,
      ] = self.evaluate(
          [
              sample_mean,
              sample_variance,
          ]
      )
      self.assertAllEqual([4, 3], sample_mean.shape)
      self.assertAllClose(
          stats.binom.mean(counts, probs),
          sample_mean_,
          atol=0.0,
          rtol=0.10,
      )
      self.assertAllEqual([4, 3], sample_variance.shape)
      self.assertAllClose(
          stats.binom.var(counts, probs),
          sample_variance_,
          atol=0.0,
          rtol=0.20,
      )
  
imports: import numpy
  from scipy import stats
  import tensorflow.compat.v1
  import tensorflow.compat.v2
  from tensorflow_probability.python.distributions import binomial
  from tensorflow_probability.python.internal import implementation_selection
  from tensorflow_probability.python.internal import test_util
  from tensorflow_probability.python.math import gradient
label_desc: Use image node_id 22 for calling the BinomialTest obj's underlying member method code with example usage: obj.testSampleUnbiasedBroadcastingBatch() without return types