code: def np_expm(x):  # pylint: disable=invalid-name
      """Slow but accurate Taylor series matrix exponential."""
      y = np.zeros(x.shape, dtype=x.dtype)
      xn = np.eye(x.shape[0], dtype=x.dtype)
      for n in range(40):
          if n > 0:
              xn /= float(n)
          y += xn
          xn = np.dot(xn, x)
      return y
  
imports: import itertools
  import numpy
  from tensorflow.python.client import session
  from tensorflow.python.framework import constant_op
  from tensorflow.python.framework import ops
  from tensorflow.python.framework import test_util
  from tensorflow.python.ops import array_ops
  from tensorflow.python.ops import control_flow_ops
  from tensorflow.python.ops import random_ops
  from tensorflow.python.ops import variables
  from tensorflow.python.ops.linalg import linalg_impl
  from tensorflow.python.platform import benchmark
  from tensorflow.python.platform import test
label_desc: Use image node_id 1 for calling a global function with example usage: np_expm(x) and returns: y