code: def create_decoder_config(
      args: argparse.Namespace,
      encoder_num_hidden: int,
      max_seq_len_source: int,
      max_seq_len_target: int,
      num_embed_target: int,
  ) -> transformer.TransformerConfig:
      """
      Create the config for the decoder.
  
      :param args: Arguments as returned by argparse.
      :param encoder_num_hidden: Number of hidden units of the Encoder.
      :param max_seq_len_source: Maximum source sequence length.
      :param max_seq_len_target: Maximum target sequence length.
      :param num_embed_target: The size of the target embedding.
      :return: The config for the decoder.
      """
      _, decoder_num_layers = args.num_layers
  
      _, decoder_transformer_preprocess = args.transformer_preprocess
      _, decoder_transformer_postprocess = args.transformer_postprocess
      _, decoder_transformer_model_size = args.transformer_model_size
  
      total_target_factor_size = 0
      for factor_combine, factor_size in zip(
          args.target_factors_combine, args.target_factors_num_embed
      ):
          if factor_combine == C.FACTORS_COMBINE_CONCAT:
              total_target_factor_size += factor_size
      if total_target_factor_size > 0:
          logger.info(
              "Decoder transformer-model-size adjusted to account for target factor embeddings: %d -> %d"
              % (
                  decoder_transformer_model_size,
                  num_embed_target + total_target_factor_size,
              )
          )
          decoder_transformer_model_size = (
              num_embed_target + total_target_factor_size
          )
  
      config_decoder = transformer.TransformerConfig(
          model_size=decoder_transformer_model_size,
          attention_heads=args.transformer_attention_heads[1],
          feed_forward_num_hidden=args.transformer_feed_forward_num_hidden[
              1
          ],
          act_type=args.transformer_activation_type[1],
          num_layers=decoder_num_layers,
          dropout_attention=args.transformer_dropout_attention[1],
          dropout_act=args.transformer_dropout_act[1],
          dropout_prepost=args.transformer_dropout_prepost[1],
          positional_embedding_type=args.transformer_positional_embedding_type,
          block_prepended_cross_attention=args.transformer_block_prepended_cross_attention,
          preprocess_sequence=decoder_transformer_preprocess,
          postprocess_sequence=decoder_transformer_postprocess,
          max_seq_len_source=max_seq_len_source,
          max_seq_len_target=max_seq_len_target,
          use_lhuc=args.lhuc is not None
          and (C.LHUC_DECODER in args.lhuc or C.LHUC_ALL in args.lhuc),
          depth_key_value=encoder_num_hidden,
          decoder_type=args.decoder,
          use_glu=args.transformer_feed_forward_use_glu,
      )
  
      return config_decoder
  
imports: from .None import initial_setup
  import argparse
  import gc
  import logging
  import os
  import shutil
  import sys
  import tempfile
  from typing import Any, cast, Callable, Optional, Dict, List, Tuple, Type
  import torch
  import torch.distributed
  import torch.distributed.elastic.multiprocessing.errors
  from .None import arguments
  from .None import checkpoint_decoder
  from .None import constants
  from .None import convert_deepspeed
  from .None import data_io
  from .None import encoder
  from .None import layers
  from .None import loss
  from .None import lr_scheduler
  from .None import model
  from .None import optimizers
  from .None import training
  from .None import transformer
  from .None import utils
  from .None import vocab
  from .config import Config
  from .log import setup_main_logger
  from .utils import check_condition
label_desc: Use image node_id 10 for calling a global function with example usage: create_decoder_config(args, encoder_num_hidden, max_seq_len_source, max_seq_len_target, num_embed_target) and returns: config_decoder