code: def check_arguements(args):
      if args.generation_method == "beam_search":
          if args.beam_size == None:
              raise Exception(
                  "set 'beam_size' value while using beam search method."
              )
      elif args.generation_method == "topk":
          if args.topk == None:
              raise Exception(
                  "set 'topk' value while using topk sample method."
              )
          ...
      elif args.generation_method == "topp":
          if args.topp == None:
              raise Exception(
                  "set 'topp' value while using topp sample method."
              )
  
      if args.eos_id == None:
          raise Exception("eos id should not be set as None")
  
      if args.padding_id == None:
          raise Exception("padding id shoud not be set as None")
  
      if args.beam_size == None:
          args.beam_size = 1
  
      if args.topp == None:
          args.topp = 1.0
  
      if args.topk == None:
          args.topk = 1
  
      return True
  
file_path: lightseq/lightseq/csrc/export/util.py
imports: import argparse
  from re import L
  import os
  import h5py
  import json
  import numpy
label_desc: Use image node_id 2 for calling a global function with example usage: check_arguements(args) and returns: True