code: def _array_to_cpu(array):
      if array is None:
          return None
      if isinstance(array, numpy.ndarray):
          return array
      if isinstance(array, chainer.backends.intel64.mdarray):
          return numpy.asarray(array)
      if isinstance(array, chainerx.ndarray):
          return chainerx.to_numpy(array, copy=False)
      if isinstance(array, chainer.backends.cuda.ndarray):
          with chainer.backends.cuda.get_device_from_array(array):
              return array.get()
      if numpy.isscalar(array):
          return numpy.asarray(array)
      raise TypeError(
          "Array cannot be converted into an numpy.ndarray"
          "\nActual type: {0}.".format(type(array))
      )
  
file_path: chainer/chainer/backends/_cpu.py
imports: import numpy
  from chainer import _backend
  import chainer.backends
  import chainerx
label_desc: Use image node_id 2 for calling a global function with example usage: _array_to_cpu(array) and returns: None, array, numpy, chainerx, numpy, array