code: def register(op_name, imperative=True, symbolic=True):
      """Register operators that fallback to NumPy in modules
      ``mxnet.ndarray.numpy._internal`` and ``mxnet.symbol.numpy._internal``.
      """
  
      def _save_op(mod):
          if hasattr(mod, op_name):
              raise ValueError(
                  "Duplicate name {} found in module {}".format(
                      op_name, str(mod)
                  )
              )
          op = functools.partial(mod.Custom, op_type=op_name)
          setattr(mod, op_name, op)
  
      def _register_helper(prop_cls):
          with np_array():
              prop_cls = operator.register(op_name)(prop_cls)
          if imperative:
              _save_op(_nd_npi)
          if symbolic:
              _save_op(_sym_npi)
          return prop_cls
  
      return _register_helper
  
imports: from distutils.version import StrictVersion
  import functools
  import ast
  import numpy
  from .None import operator
  from .None import numpy
  from .util import np_array, use_np
  from .numpy.utils import _STR_2_DTYPE_
  from .ndarray.numpy import _internal
  from .symbol.numpy import _internal
label_desc: Use image node_id 1 for calling a global function with example usage: register(op_name, imperative, symbolic) and returns: _register_helper, prop_cls