code: def getParser():
      "Creates and returns the argparse parser object."
      parser = argparse.ArgumentParser(
          description=__description__,
          formatter_class=RawTextHelpFormatter,
      )
  
      parser.add_argument(
          "image",
          help="An image of arbitrary dimensions that should be split.",
      )
      parser.add_argument(
          "output",
          help='Output volumes. Has to include the sequence "{}" in the place where the volume number should be placed.',
      )
      parser.add_argument(
          "dimension",
          type=int,
          help="The dimension in which direction to split (starting from 0:x).",
      )
      parser.add_argument(
          "maxsize",
          type=int,
          help="The produced volumes will always be smaller than this size (in terms of slices in the cut-dimension).",
      )
      parser.add_argument(
          "-f",
          dest="force",
          action="store_true",
          help="Set this flag to silently override files that exist.",
      )
      parser.add_argument(
          "-v",
          dest="verbose",
          action="store_true",
          help="Display more information.",
      )
      parser.add_argument(
          "-d",
          dest="debug",
          action="store_true",
          help="Display debug information.",
      )
  
      return parser
  
file_path: medpy/bin/medpy_extract_sub_volume_auto.py
imports: from argparse import RawTextHelpFormatter
  import argparse
  import logging
  import os
  from medpy.core import ArgumentError, Logger
  from medpy.io import load, save
label_desc: Use image node_id 3 for calling a global function with example usage: getParser() and returns: parser