code: def spm_norm(A):
      """
      Returns normalization of Categorical distribution,
      stored in the columns of A.
      """
      A = A + EPS_VAL
      normed_A = np.divide(A, A.sum(axis=0))
      return normed_A
  
imports: import numpy
  from scipy import special
  from pymdp import utils
  from itertools import chain
label_desc: Use image node_id 8 for calling a global function with example usage: spm_norm(A) and returns: normed_A