code: def testKumaraswamyModeEnableAllowNanStats(self):
      with tf1.Session():
          a = np.array([1.0, 2, 3])
          b = np.array([2.0, 4, 1.2])
          dist = kumaraswamy.Kumaraswamy(
              a, b, allow_nan_stats=True, validate_args=True
          )
  
          expected_mode = _kumaraswamy_mode(a, b)
          expected_mode[0] = np.nan
          self.assertEqual((3,), dist.mode().shape)
          self.assertAllClose(expected_mode, self.evaluate(dist.mode()))
  
          a = np.array([2.0, 2, 3])
          b = np.array([1.0, 4, 1.2])
          dist = kumaraswamy.Kumaraswamy(
              a, b, allow_nan_stats=True, validate_args=True
          )
  
          expected_mode = _kumaraswamy_mode(a, b)
          expected_mode[0] = np.nan
          self.assertEqual((3,), dist.mode().shape)
          self.assertAllClose(expected_mode, self.evaluate(dist.mode()))
  
imports: import numpy
  from scipy import special
  from scipy import stats
  import tensorflow.compat.v1
  import tensorflow.compat.v2
  from tensorflow_probability.python.distributions import kumaraswamy
  from tensorflow_probability.python.internal import test_util
label_desc: Use image node_id 18 for calling the KumaraswamyTest obj's underlying member method code with example usage: obj.testKumaraswamyModeEnableAllowNanStats() without return types