code: def _onenorm(A):
      # A compatibility function which should eventually disappear.
      # This is copypasted from expm_action.
      if scipy.sparse.isspmatrix(A):
          return max(abs(A).sum(axis=0).flat)
      else:
          return np.linalg.norm(A, 1)
  
imports: from __future__ import division, print_function, absolute_import
  import math
  import numpy
  import scipy.special
  from scipy.linalg.basic import solve, solve_triangular
  from scipy.sparse.base import isspmatrix
  from scipy.sparse.construct import eye
  from scipy.sparse.linalg import spsolve
  import scipy.sparse
  import scipy.sparse.linalg
  from scipy.sparse.linalg.interface import LinearOperator
label_desc: Use image node_id 3 for calling a global function with example usage: _onenorm(A) and returns: max, np