code: def test_forward_rates(self, dtype):
      # Discount factors at start dates
      df_start_dates = [[0.95, 0.9, 0.75], [0.95, 0.99, 0.85]]
      # Discount factors at end dates
      df_end_dates = [[0.8, 0.6, 0.5], [0.8, 0.9, 0.5]]
      # Daycount fractions between the dates
      daycount_fractions = [[0.5, 1.0, 2], [0.6, 0.4, 4.0]]
      forward_rates = self.evaluate(
          tff.rates.analytics.forwards.forward_rates(
              df_start_dates,
              df_end_dates,
              daycount_fractions,
              dtype=dtype,
          )
      )
      expected_forward_rates = np.array(
          [[0.375, 0.5, 0.25], [0.3125, 0.25, 0.175]], dtype=dtype
      )
      np.testing.assert_allclose(
          forward_rates, expected_forward_rates, atol=1e-6
      )
  
file_path: tf-quant-finance/tf_quant_finance/rates/analytics/forwards_test.py
imports: from absl.testing import parameterized
  import numpy
  import tensorflow.compat.v2
  import tf_quant_finance
  from tensorflow.python.framework import test_util
label_desc: Use image node_id 1 for calling the ForwardRatesTest obj's underlying member method code with example usage: obj.test_forward_rates(dtype) without return types