code: def array_from_scalar_or_array_gradmaker(
      ans, array_args, array_kwargs, scarray
  ):
      ndmin = array_kwargs.get("ndmin", 0)
      scarray_ndim = anp.ndim(scarray)
      if ndmin > scarray_ndim:
          return lambda g: anp.squeeze(
              g, axis=tuple(range(ndmin - scarray_ndim))
          )
      else:
          return lambda g: g
  
imports: from __future__ import absolute_import
  from six import string_types
  from functools import partial
  import numpy
  from ..util import func
  from .None import numpy_wrapper
  from .numpy_boxes import ArrayBox
  from autograd.extend import primitive, vspace, defvjp, defvjp_argnum, SparseObject, VJPNode, register_notrace
label_desc: Use image node_id 45 for calling a global function with example usage: array_from_scalar_or_array_gradmaker(ans, array_args, array_kwargs, scarray) and returns: function, function