code: def _stack(xp, xs, axis):
      try:
          return xp.stack(xs, axis)
      except AttributeError:
          # in case numpy<1.10, which does not have numpy.stack
          return xp.concatenate(
              [xp.expand_dims(x, axis) for x in xs], axis=axis
          )
  
imports: import chainer
  from chainer.backends import cuda
  from chainer import distribution
  from chainer.functions.math import exponential
  import chainer.functions.math.sum
  from chainer.utils import cache
label_desc: Use image node_id 1 for calling a global function with example usage: _stack(xp, xs, axis) and returns: xp, xp