code: def _create_term_structure_maturities(fixed_leg_payment_times):
      """Create maturities needed for termstructure simulations."""
  
      with tf.name_scope("create_termstructure_maturities"):
          maturities = fixed_leg_payment_times
          maturities_shape = tf.shape(maturities)
  
          # We should eventually remove tf.unique, but keeping it for now because
          # PDE solvers are not xla compatible in TFF currently.
          unique_maturities, _ = tf.unique(
              tf.reshape(maturities, shape=[-1])
          )
          unique_maturities = tf.sort(
              unique_maturities, name="sort_maturities"
          )
  
          return maturities, unique_maturities, maturities_shape
  
file_path: tf-quant-finance/tf_quant_finance/models/hjm/swaption_pricing.py
imports: from typing import Callable, Union
  import tensorflow.compat.v2
  from tf_quant_finance import types
  from tf_quant_finance.math import pde
  from tf_quant_finance.math import random
  from tf_quant_finance.models import utils
  from tf_quant_finance.models import valuation_method
  from tf_quant_finance.models.hjm import gaussian_hjm
  from tf_quant_finance.models.hjm import quasi_gaussian_hjm
  from tf_quant_finance.models.hjm import swaption_util
label_desc: Use image node_id 6 for calling a global function with example usage: _create_term_structure_maturities(fixed_leg_payment_times) and returns: maturities,  unique_maturities,  maturities_shape