code: def _process_config(
      config: Union[ForwardRateAgreementConfig, Dict[str, Any], None]
  ) -> ForwardRateAgreementConfig:
      """Converts config to ForwardRateAgreementConfig."""
      if config is None:
          return ForwardRateAgreementConfig()
      if isinstance(config, ForwardRateAgreementConfig):
          return config
      model = config.get("model", "")
      discounting_curve = config.get("discounting_curve", dict())
      return ForwardRateAgreementConfig(
          discounting_curve=discounting_curve, model=model
      )
  
imports: from typing import Any, Optional, List, Dict, Union
  import dataclasses
  import tensorflow.compat.v2
  from tf_quant_finance import datetime
  from tf_quant_finance.experimental.pricing_platform.framework.core import curve_types
  from tf_quant_finance.experimental.pricing_platform.framework.core import instrument
  from tf_quant_finance.experimental.pricing_platform.framework.core import processed_market_data
  from tf_quant_finance.experimental.pricing_platform.framework.core import rate_indices
  from tf_quant_finance.experimental.pricing_platform.framework.core import types
  from tf_quant_finance.experimental.pricing_platform.framework.market_data import utils
  from tf_quant_finance.experimental.pricing_platform.framework.rate_instruments import cashflow_streams
  from tf_quant_finance.experimental.pricing_platform.framework.rate_instruments.forward_rate_agreement import proto_utils
  from tf_quant_finance.experimental.pricing_platform.instrument_protos import forward_rate_agreement_pb2
  from tf_quant_finance.experimental.pricing_platform.instrument_protos import period_pb2
label_desc: Use image node_id 1 for calling a global function with example usage: _process_config(config) and returns: ForwardRateAgreementConfig, ForwardRateAgreementConfig, config