code: def train_args(parser: argparse.ArgumentParser, models_family=None):
      """Add training specific arguments for Transformer based models"""
      parser.add_argument(
          "--model_name_or_path",
          default=None,
          type=str,
          required=True,
          help="Path to pre-trained model or shortcut name selected in the list: "
          + ", ".join(get_models(models_family)),
      )
      parser.add_argument(
          "--config_name",
          default="",
          type=str,
          help="Pretrained config name or path if not the same as model_name",
      )
      parser.add_argument(
          "--evaluate_during_training",
          action="store_true",
          help="Run evaluation during training at each logging step.",
      )
      parser.add_argument(
          "--per_gpu_train_batch_size",
          default=8,
          type=int,
          help="Batch size per GPU/CPU for training.",
      )
      parser.add_argument(
          "--gradient_accumulation_steps",
          type=int,
          default=1,
          help="Number of updates steps to accumulate before performing a "
          "backward/update pass.",
      )
      parser.add_argument(
          "--learning_rate",
          default=5e-5,
          type=float,
          help="The initial learning rate for Adam.",
      )
      parser.add_argument(
          "--weight_decay",
          default=0.0,
          type=float,
          help="Weight deay if we apply some.",
      )
      parser.add_argument(
          "--adam_epsilon",
          default=1e-8,
          type=float,
          help="Epsilon for Adam optimizer.",
      )
      parser.add_argument(
          "--max_grad_norm",
          default=1.0,
          type=float,
          help="Max gradient norm.",
      )
      parser.add_argument(
          "--num_train_epochs",
          default=3,
          type=int,
          help="Total number of training epochs to perform.",
      )
      parser.add_argument(
          "--max_steps",
          default=-1,
          type=int,
          help="If > 0: set total number of training steps to perform. "
          "Override num_train_epochs.",
      )
      parser.add_argument(
          "--warmup_steps",
          default=0,
          type=int,
          help="Linear warmup over warmup_steps.",
      )
      parser.add_argument(
          "--logging_steps",
          type=int,
          default=50,
          help="Log every X updates steps.",
      )
      parser.add_argument(
          "--save_steps",
          type=int,
          default=500,
          help="Save checkpoint every X updates steps.",
      )
      parser.add_argument(
          "--eval_all_checkpoints",
          action="store_true",
          help="Evaluate all checkpoints starting with the same prefix as "
          + "model_name ending and ending with step number",
      )
      parser.add_argument(
          "--seed",
          type=int,
          default=42,
          help="random seed for initialization",
      )
  
imports: import argparse
  from nlp_architect.models.transformers.base_model import get_models
label_desc: Use image node_id 3 for calling a global function with example usage: train_args(parser, models_family) without return types