code: def testAssertionCategoricalEventShape(self):
      total_count = tf.constant(10.0, dtype=tf.float16)
      too_many_classes = 2**11 + 1
      concentration = tf.Variable(tf.ones(too_many_classes, tf.float16))
      with self.assertRaisesRegexp(
          ValueError, "Number of classes exceeds `dtype` precision"
      ):
          dm.DirichletMultinomial(
              total_count, concentration, validate_args=True
          )
  
imports: import numpy
  import tensorflow.compat.v1
  import tensorflow.compat.v2
  from tensorflow_probability.python.distributions import dirichlet_multinomial
  from tensorflow_probability.python.internal import test_util
  from tensorflow_probability.python.math import gradient
label_desc: Use image node_id 1 for calling the DirichletMultinomialFromVariableTest obj's underlying member method code with example usage: obj.testAssertionCategoricalEventShape() without return types