code: def pinvh(a, cond=None, rcond=None, lower=True):
      """Compute the (Moore-Penrose) pseudo-inverse of a hermetian matrix.
  
      Calculate a generalized inverse of a symmetric matrix using its
      eigenvalue decomposition and including all 'large' eigenvalues.
  
      Parameters
      ----------
      a : array, shape (N, N)
          Real symmetric or complex hermetian matrix to be pseudo-inverted
  
      cond : float or None, default None
          Cutoff for 'small' eigenvalues.
          Singular values smaller than rcond * largest_eigenvalue are considered
          zero.
  
          If None or -1, suitable machine precision is used.
  
      rcond : float or None, default None (deprecated)
          Cutoff for 'small' eigenvalues.
          Singular values smaller than rcond * largest_eigenvalue are considered
          zero.
  
          If None or -1, suitable machine precision is used.
  
      lower : boolean
          Whether the pertinent array data is taken from the lower or upper
          triangle of a. (Default: lower)
  
      Returns
      -------
      B : array, shape (N, N)
  
      Raises
      ------
      LinAlgError
          If eigenvalue does not converge
  
      Examples
      --------
      >>> import numpy as np
      >>> a = np.random.randn(9, 6)
      >>> a = np.dot(a, a.T)
      >>> B = pinvh(a)
      >>> np.allclose(a, np.dot(a, np.dot(B, a)))
      True
      >>> np.allclose(B, np.dot(B, np.dot(a, B)))
      True
  
      """
      a = np.asarray_chkfinite(a)
      s, u = linalg.eigh(a, lower=lower)
  
      if rcond is not None:
          cond = rcond
      if cond in [None, -1]:
          t = u.dtype.char.lower()
          factor = {"f": 1e3, "d": 1e6}
          cond = factor[t] * np.finfo(t).eps
  
      # unlike svd case, eigh can lead to negative eigenvalues
      above_cutoff = abs(s) > cond * np.max(abs(s))
      psigma_diag = np.zeros_like(s)
      psigma_diag[above_cutoff] = 1.0 / s[above_cutoff]
  
      return np.dot(u * psigma_diag, np.conjugate(u).T)
  
imports: from __future__ import division
  from functools import partial
  import warnings
  import numpy
  from scipy import linalg
  from scipy.sparse import issparse, csr_matrix
  from .None import check_random_state
  from .fixes import np_version
  from ._logistic_sigmoid import _log_logistic_sigmoid
  from ..externals.six.moves import xrange
  from .sparsefuncs_fast import csr_row_norms
  from .validation import check_array
  from ..exceptions import NonBLASDotWarning
label_desc: Use image node_id 14 for calling a global function with example usage: pinvh(a, cond, rcond, lower) and returns: np