code: def parse_args():
      parser = argparse.ArgumentParser()
      parser.add_argument(
          "--reset_output_dir",
          type=distutils.util.strtobool,
          default=True,
          help="Whether to clean the output dir if existed. (default: %(default)s)",
      )
      parser.add_argument(
          "--child_fixed_arc",
          type=str,
          required=True,
          help="Architecture json file. (default: %(default)s)",
      )
      parser.add_argument(
          "--data_path",
          type=str,
          default="data",
          help="Directory containing the dataset and embedding file. (default: %(default)s)",
      )
      parser.add_argument(
          "--output_dir",
          type=str,
          default="output",
          help="The output directory. (default: %(default)s)",
      )
      parser.add_argument(
          "--child_lr_decay_scheme",
          type=str,
          default="cosine",
          help="Learning rate annealing strategy, only 'cosine' supported. (default: %(default)s)",
      )
      parser.add_argument(
          "--batch_size",
          type=int,
          default=128,
          help="Number of samples each batch for training. (default: %(default)s)",
      )
      parser.add_argument(
          "--eval_batch_size",
          type=int,
          default=128,
          help="Number of samples each batch for evaluation. (default: %(default)s)",
      )
      parser.add_argument(
          "--class_num",
          type=int,
          default=5,
          help="The number of categories. (default: %(default)s)",
      )
      parser.add_argument(
          "--global_seed",
          type=int,
          default=1234,
          help="Seed for reproduction. (default: %(default)s)",
      )
      parser.add_argument(
          "--max_input_length",
          type=int,
          default=64,
          help="The maximum length of the sentence. (default: %(default)s)",
      )
      parser.add_argument(
          "--num_epochs",
          type=int,
          default=10,
          help="The number of training epochs. (default: %(default)s)",
      )
      parser.add_argument(
          "--child_num_layers",
          type=int,
          default=24,
          help="The layer number of the architecture. (default: %(default)s)",
      )
      parser.add_argument(
          "--child_out_filters",
          type=int,
          default=256,
          help="The dimension of hidden states. (default: %(default)s)",
      )
      parser.add_argument(
          "--child_out_filters_scale",
          type=int,
          default=1,
          help="The scale of hidden state dimension. (default: %(default)s)",
      )
      parser.add_argument(
          "--child_lr_T_0",
          type=int,
          default=10,
          help="The length of one cycle. (default: %(default)s)",
      )
      parser.add_argument(
          "--child_lr_T_mul",
          type=int,
          default=2,
          help="The multiplication factor per cycle. (default: %(default)s)",
      )
      parser.add_argument(
          "--min_count",
          type=int,
          default=1,
          help="The threshold to cut off low frequent words. (default: %(default)s)",
      )
      parser.add_argument(
          "--train_ratio",
          type=float,
          default=1.0,
          help="The sample ratio for the training set. (default: %(default)s)",
      )
      parser.add_argument(
          "--valid_ratio",
          type=float,
          default=1.0,
          help="The sample ratio for the dev set. (default: %(default)s)",
      )
      parser.add_argument(
          "--child_grad_bound",
          type=float,
          default=5.0,
          help="The threshold for gradient clipping. (default: %(default)s)",
      )
      parser.add_argument(
          "--child_lr",
          type=float,
          default=0.02,
          help="The initial learning rate. (default: %(default)s)",
      )
      parser.add_argument(
          "--cnn_keep_prob",
          type=float,
          default=0.8,
          help="Keep prob for cnn layer. (default: %(default)s)",
      )
      parser.add_argument(
          "--final_output_keep_prob",
          type=float,
          default=1.0,
          help="Keep prob for the last output layer. (default: %(default)s)",
      )
      parser.add_argument(
          "--lstm_out_keep_prob",
          type=float,
          default=0.8,
          help="Keep prob for the RNN layer. (default: %(default)s)",
      )
      parser.add_argument(
          "--embed_keep_prob",
          type=float,
          default=0.8,
          help="Keep prob for the embedding layer. (default: %(default)s)",
      )
      parser.add_argument(
          "--attention_keep_prob",
          type=float,
          default=0.8,
          help="Keep prob for the self-attention layer. (default: %(default)s)",
      )
      parser.add_argument(
          "--child_l2_reg",
          type=float,
          default=3e-6,
          help="Weight decay factor. (default: %(default)s)",
      )
      parser.add_argument(
          "--child_lr_max",
          type=float,
          default=0.002,
          help="The max learning rate. (default: %(default)s)",
      )
      parser.add_argument(
          "--child_lr_min",
          type=float,
          default=0.001,
          help="The min learning rate. (default: %(default)s)",
      )
      parser.add_argument(
          "--child_optim_algo",
          type=str,
          default="adam",
          help="Optimization algorithm. (default: %(default)s)",
      )
      parser.add_argument(
          "--checkpoint_dir",
          type=str,
          default="best_checkpoint",
          help="Path for saved checkpoints. (default: %(default)s)",
      )
      parser.add_argument(
          "--output_type",
          type=str,
          default="avg",
          help="Opertor type for the time steps reduction. (default: %(default)s)",
      )
      parser.add_argument(
          "--multi_path",
          type=distutils.util.strtobool,
          default=False,
          help="Search for multiple path in the architecture. (default: %(default)s)",
      )
      parser.add_argument(
          "--is_binary",
          type=distutils.util.strtobool,
          default=False,
          help="Binary label for sst dataset. (default: %(default)s)",
      )
      parser.add_argument(
          "--is_cuda",
          type=distutils.util.strtobool,
          default=True,
          help="Specify the device type. (default: %(default)s)",
      )
      parser.add_argument(
          "--is_mask",
          type=distutils.util.strtobool,
          default=True,
          help="Apply mask. (default: %(default)s)",
      )
      parser.add_argument(
          "--fixed_seed",
          type=distutils.util.strtobool,
          default=True,
          help="Fix the seed. (default: %(default)s)",
      )
      parser.add_argument(
          "--load_checkpoint",
          type=distutils.util.strtobool,
          default=False,
          help="Wether to load checkpoint. (default: %(default)s)",
      )
      parser.add_argument(
          "--log_every",
          type=int,
          default=50,
          help="How many steps to log. (default: %(default)s)",
      )
      parser.add_argument(
          "--eval_every_epochs",
          type=int,
          default=1,
          help="How many epochs to eval. (default: %(default)s)",
      )
  
      global FLAGS
  
      FLAGS = parser.parse_args()
  
imports: import sys
  import os
  import logging
  import pickle
  import shutil
  import random
  import math
  import time
  import datetime
  import argparse
  import distutils.util
  import numpy
  import torch
  from torch import nn
  from torch import optim
  from torch.utils.data import DataLoader
  import torch.nn.functional
  from model import Model
  from nni.nas.pytorch.fixed import apply_fixed_architecture
  from dataloader import read_data_sst
label_desc: Use image node_id 1 for calling a global function with example usage: parse_args() without return types