code: def test_log_prob_for_inflated_lognormal_is_diffable(self):
      x = tf.constant([0.0, 1.0])
  
      # pylint: disable=g-long-lambda
      lp, grad = gradient.value_and_gradient(
          lambda loc: inflated.Inflated(
              lognormal.LogNormal(loc=loc, scale=1.0),
              inflated_loc_probs=0.5,
          ).log_prob(x),
          5.0,
      )
      # pylint: enable=g-long-lambda
      self.assertAllFinite(lp)
      self.assertAllFinite(grad)
  
file_path: probability/tensorflow_probability/python/distributions/inflated_test.py
imports: import numpy
  import tensorflow.compat.v2
  from tensorflow_probability.python.distributions import gamma
  from tensorflow_probability.python.distributions import inflated
  from tensorflow_probability.python.distributions import lognormal
  from tensorflow_probability.python.distributions import negative_binomial
  from tensorflow_probability.python.distributions import normal
  from tensorflow_probability.python.experimental.util import trainable
  from tensorflow_probability.python.internal import test_util
  from tensorflow_probability.python.math import gradient
label_desc: Use image node_id 8 for calling the DistributionsTest obj's underlying member method code with example usage: obj.test_log_prob_for_inflated_lognormal_is_diffable() without return types