code: def testFiniteGradientAtDifficultPoints(self, skewness):
      eps = np.finfo(self.dtype).eps
      large = 1.0 / np.sqrt(eps)
  
      def make_fn(attr):
          x = np.array(
              [-large, -eps, 0.0, eps, large], dtype=self.dtype
          )
          return lambda d, m, s, g: getattr(  # pylint: disable=g-long-lambda
              two_piece_student_t.TwoPieceStudentT(
                  df=d, loc=m, scale=s, skewness=g, validate_args=True
              ),
              attr,
          )(
              x
          )
  
      df = tf.constant(6.0, self.dtype)
      loc = tf.constant(0.0, self.dtype)
      scale = tf.constant(1.0, self.dtype)
  
      for attr in ("log_prob", "cdf", "survival_function"):
          value, grads = self.evaluate(
              gradient.value_and_gradient(
                  make_fn(attr),
                  [df, loc, scale, tf.constant(skewness, self.dtype)],
              )
          )
          self.assertAllFinite(value)
          self.assertAllFinite(grads[0])  # d/d df
          self.assertAllFinite(grads[1])  # d/d loc
          self.assertAllFinite(grads[2])  # d/d scale
          self.assertAllFinite(grads[3])
  
imports: from absl.testing import parameterized
  import numpy
  import tensorflow.compat.v2
  from tensorflow_probability.python.distributions import two_piece_student_t
  from tensorflow_probability.python.internal import test_util
  from tensorflow_probability.python.math import gradient
label_desc: Use image node_id 16 for calling the _TwoPieceStudentTTest obj's underlying member method code with example usage: obj.testFiniteGradientAtDifficultPoints(skewness) and returns: function