code: def softmax(x):
      # clip to shiftx, otherwise, when calc loss with
      # log(exp(shiftx)), may get log(0)=INF
      shiftx = (x - np.max(x)).clip(-64.0)
      exps = np.exp(shiftx)
      return exps / np.sum(exps)
  
imports: from __future__ import print_function
  import os, sys
  import unittest
  import numpy
  import paddle
  import ppdet.modeling.ops
  from ppdet.modeling.tests.test_base import LayerTest
label_desc: Use image node_id 2 for calling a global function with example usage: softmax(x) and returns: unknown