code: def test_interpolated_yields_consistency(self):
      dtypes = [np.float32, np.float64]
      for dtype in dtypes:
          reference_times = np.array([1.0, 2.0, 3.0, 4.0], dtype=dtype)
          yields = np.array([5.0, 4.75, 4.53333333, 4.775], dtype=dtype)
  
          # Times for which the interpolated values are required.
          interpolation_times_1 = tf.constant(
              [0.25, 0.5, 1.0, 2.0, 3.0], dtype=dtype
          )
          interpolation_times_2 = tf.constant(
              [1.1, 2.5, 2.9, 3.6, 4.0], dtype=dtype
          )
          expected = np.array(
              [
                  5.1171875,
                  5.09375,
                  5.0,
                  4.75,
                  4.533333,
                  4.9746,
                  4.624082,
                  4.535422,
                  4.661777,
                  4.775,
              ],
              dtype=dtype,
          )
          actual_1 = monotone_convex.interpolate_yields(
              interpolation_times_1, reference_times, yields=yields
          )
          actual_2 = monotone_convex.interpolate_yields(
              interpolation_times_2, reference_times, yields=yields
          )
          actual = self.evaluate(
              tf.concat([actual_1, actual_2], axis=0)
          )
          np.testing.assert_allclose(actual, expected, rtol=1e-5)
  
imports: from absl.testing import parameterized
  import numpy
  import tensorflow.compat.v2
  from tensorflow.python.framework import test_util
  from tf_quant_finance.rates.hagan_west import monotone_convex
label_desc: Use image node_id 13 for calling the MonotoneConvexTest obj's underlying member method code with example usage: obj.test_interpolated_yields_consistency() without return types