code: def testProbBatchMultivariate(self):
      dist = make_multivariate_mixture(
          batch_shape=[2, 3], num_components=2, event_shape=[4]
      )
  
      for x in [
          np.random.randn(2, 3, 4).astype(np.float32),
          np.random.randn(4, 2, 3, 4).astype(np.float32),
      ]:
          p_x = dist.prob(x)
          self.assertEqual(x.shape[:-1], p_x.shape)
  
          cat_probs = tf.math.softmax(dist.cat.logits)
          dist_probs = [d.prob(x) for d in dist.components]
  
          p_x_value, cat_probs_value, dist_probs_value = self.evaluate(
              [p_x, cat_probs, dist_probs]
          )
          self.assertEqual(x.shape[:-1], p_x_value.shape)
  
          cat_probs_value = _swap_first_last_axes(cat_probs_value)
          total_prob = sum(
              c_p_value * d_p_value
              for (c_p_value, d_p_value) in zip(
                  cat_probs_value, dist_probs_value
              )
          )
  
          self.assertAllClose(total_prob, p_x_value)
  
imports: import contextlib
  import warnings
  import numpy
  from scipy import stats
  import tensorflow.compat.v1
  import tensorflow.compat.v2
  from tensorflow_probability.python.distributions import categorical
  from tensorflow_probability.python.distributions import dirichlet
  from tensorflow_probability.python.distributions import distribution
  from tensorflow_probability.python.distributions import gamma
  from tensorflow_probability.python.distributions import half_normal
  from tensorflow_probability.python.distributions import independent
  from tensorflow_probability.python.distributions import mixture
  from tensorflow_probability.python.distributions import mvn_diag
  from tensorflow_probability.python.distributions import mvn_tril
  from tensorflow_probability.python.distributions import normal
  from tensorflow_probability.python.internal import hypothesis_testlib
  from tensorflow_probability.python.internal import reparameterization
  from tensorflow_probability.python.internal import tensorshape_util
  from tensorflow_probability.python.internal import test_util
label_desc: Use image node_id 14 for calling the MixtureTest obj's underlying member method code with example usage: obj.testProbBatchMultivariate() without return types