code: def setUp(self):
      self._swap_1 = ir_swap.InterestRateSwap(
          effective_date=date_pb2.Date(year=2019, month=10, day=3),
          maturity_date=date_pb2.Date(year=2029, month=10, day=3),
          currency=Currency.USD(),
          pay_leg=ir_swap.SwapLeg(
              fixed_leg=ir_swap.FixedLeg(
                  currency=Currency.USD(),
                  coupon_frequency=period_pb2.Period(
                      type="MONTH", amount=6
                  ),
                  notional_amount=decimal_pb2.Decimal(units=1000000),
                  fixed_rate=decimal_pb2.Decimal(nanos=31340000),
                  daycount_convention=DayCountConventions.ACTUAL_360(),
                  business_day_convention=BusinessDayConvention.MODIFIED_FOLLOWING(),
                  settlement_days=2,
              )
          ),
          receive_leg=ir_swap.SwapLeg(
              floating_leg=ir_swap.FloatingLeg(
                  currency=Currency.USD(),
                  coupon_frequency=period_pb2.Period(
                      type="MONTH", amount=3
                  ),
                  reset_frequency=period_pb2.Period(
                      type="MONTH", amount=3
                  ),
                  notional_amount=decimal_pb2.Decimal(units=1000000),
                  floating_rate_type=RateIndex(type="LIBOR_3M"),
                  daycount_convention=DayCountConventions.ACTUAL_360(),
                  business_day_convention=BusinessDayConvention.MODIFIED_FOLLOWING(),
                  settlement_days=2,
              )
          ),
      )
      self._swap_2 = ir_swap.InterestRateSwap(
          effective_date=date_pb2.Date(year=2019, month=10, day=3),
          maturity_date=date_pb2.Date(year=2029, month=10, day=3),
          currency=Currency.USD(),
          pay_leg=ir_swap.SwapLeg(
              fixed_leg=ir_swap.FixedLeg(
                  currency=Currency.USD(),
                  coupon_frequency=period_pb2.Period(
                      type="MONTH", amount=3
                  ),
                  notional_amount=decimal_pb2.Decimal(units=1000000),
                  fixed_rate=decimal_pb2.Decimal(nanos=31340000),
                  daycount_convention=DayCountConventions.ACTUAL_360(),
                  business_day_convention=BusinessDayConvention.MODIFIED_FOLLOWING(),
                  settlement_days=2,
              )
          ),
          receive_leg=ir_swap.SwapLeg(
              floating_leg=ir_swap.FloatingLeg(
                  currency=Currency.USD(),
                  coupon_frequency=period_pb2.Period(
                      type="MONTH", amount=3
                  ),
                  reset_frequency=period_pb2.Period(
                      type="MONTH", amount=3
                  ),
                  notional_amount=decimal_pb2.Decimal(units=1000000),
                  floating_rate_type=RateIndex(type="LIBOR_3M"),
                  daycount_convention=DayCountConventions.ACTUAL_360(),
                  business_day_convention=BusinessDayConvention.MODIFIED_FOLLOWING(),
                  settlement_days=2,
              )
          ),
      )
      dates = [
          [2021, 2, 8],
          [2022, 2, 8],
          [2023, 2, 8],
          [2025, 2, 8],
          [2027, 2, 8],
          [2030, 2, 8],
          [2050, 2, 8],
      ]
      discounts = [
          0.97197441,
          0.94022746,
          0.91074031,
          0.85495089,
          0.8013675,
          0.72494879,
          0.37602059,
      ]
      libor_3m_config = {
          "interpolation_method": interpolation_method.InterpolationMethod.LINEAR
      }
      self._market_data_dict = {
          "rates": {
              "USD": {
                  "risk_free_curve": {
                      "dates": dates,
                      "discounts": discounts,
                  },
                  "LIBOR_3M": {
                      "dates": dates,
                      "discounts": discounts,
                      "config": libor_3m_config,
                  },
              }
          },
          "reference_date": [(2020, 6, 24)],
      }
      super(InterestRateSwapTest, self).setUp()
  
file_path: tf-quant-finance/tf_quant_finance/experimental/pricing_platform/framework/rate_instruments/interest_rate_swap/interest_rate_swap_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 InterestRateSwapTest obj's underlying member method code with example usage: obj.setUp() without return types