code: def generate_bench(name, codes):
      tab = " " * 4
      top, middle, end = [], [], []
  
      tmp = codes.split("*")
      if len(tmp) > 1:
          incodes = tmp[0]
          outcodes = tmp[1]
      else:
          incodes = tmp[0]
          outcodes = ""
  
      inargs, inargs_and_types = [], []
      for n, code in enumerate(incodes):
          arg = f"x{n}"
          inargs.append(arg)
          inargs_and_types.append(f"{CY_TYPES[code]} {arg}")
      line = "def {{}}(int N, {}):".format(", ".join(inargs_and_types))
      top.append(line)
      top.append(tab + "cdef int n")
  
      outargs = []
      for n, code in enumerate(outcodes):
          arg = f"y{n}"
          outargs.append(f"&{arg}")
          line = f"cdef {CY_TYPES[code]} {arg}"
          middle.append(tab + line)
  
      end.append(tab + "for n in range(N):")
      end.append(2 * tab + "{}({})")
      pyfunc = "_bench_{}_{}_{}".format(name, incodes, "py")
      cyfunc = "_bench_{}_{}_{}".format(name, incodes, "cy")
      pytemplate = "\n".join(top + end)
      cytemplate = "\n".join(top + middle + end)
      pybench = pytemplate.format(
          pyfunc, "_ufuncs." + name, ", ".join(inargs)
      )
      cybench = cytemplate.format(
          cyfunc, name, ", ".join(inargs + outargs)
      )
      return pybench, cybench
  
imports: import itertools
  import json
  import os
  from stat import ST_MTIME
  import argparse
  import re
  import textwrap
  import numpy
label_desc: Use image node_id 5 for calling a global function with example usage: generate_bench(name, codes) and returns: pybench,  cybench