code: def get_array_binop_kernel(
      context,
      operator,
      dtype_res,
      dtype_a,
      dtype_b,
      a_is_scalar=False,
      b_is_scalar=False,
  ):
      a = "a[0]" if a_is_scalar else "a[i]"
      b = "b[0]" if b_is_scalar else "b[i]"
      return get_elwise_kernel(
          context,
          [
              VectorArg(dtype_res, "out", with_offset=True),
              VectorArg(dtype_a, "a", with_offset=True),
              VectorArg(dtype_b, "b", with_offset=True),
          ],
          f"out[i] = {a} {operator} {b}",
          name="binop_kernel",
      )
  
imports: import enum
  from typing import Any, List, Optional, Tuple, Union
  import numpy
  import pyopencl
  from pyopencl.tools import context_dependent_memoize
  from pyopencl.tools import dtype_to_ctype, DtypedArgument, VectorArg, ScalarArg, KernelTemplateBase, dtype_to_c_struct
  from pytools import memoize_method
label_desc: Use image node_id 23 for calling a global function with example usage: get_array_binop_kernel(context, operator, dtype_res, dtype_a, dtype_b, a_is_scalar, b_is_scalar) and returns: get_elwise_kernel