code: def testSampleUnbiasedVectorBatch(self):
      for counts in np.float32(5.0), np.float32(50.0):
          probs = self._rng.rand(4).astype(np.float32)
          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], sample_mean.shape)
          # Pass f64 values to avoid errors in scipy.
          self.assertAllClose(
              stats.binom.mean(
                  counts.astype(np.float64), probs.astype(np.float64)
              ),
              sample_mean_,
              atol=0.0,
              rtol=0.10,
          )
          self.assertAllEqual([4], sample_variance.shape)
          self.assertAllClose(
              stats.binom.var(
                  counts.astype(np.float64), probs.astype(np.float64)
              ),
              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 23 for calling the BinomialTest obj's underlying member method code with example usage: obj.testSampleUnbiasedVectorBatch() without return types