code: def get_unary_func_kernel(func_name, in_dtype, out_dtype=None):
      if out_dtype is None:
          out_dtype = in_dtype
  
      return get_elwise_kernel(
          "%(tp_in)s *y, %(tp_out)s *z"
          % {
              "tp_in": dtype_to_ctype(in_dtype),
              "tp_out": dtype_to_ctype(out_dtype),
          },
          "z[i] = %s(y[i])" % func_name,
          "%s_kernel" % func_name,
      )
  
imports: from pycuda.tools import context_dependent_memoize
  from typing import Any
  import numpy
  from pycuda.tools import dtype_to_ctype, VectorArg, ScalarArg
  from pytools import memoize_method
label_desc: Use image node_id 29 for calling a global function with example usage: get_unary_func_kernel(func_name, in_dtype, out_dtype) and returns: get_elwise_kernel