code: def _pinv2_old(a):
      # Used previous scipy pinv2 that was updated in:
      # https://github.com/scipy/scipy/pull/10067
      # We can not set `cond` or `rcond` for pinv2 in scipy >= 1.3 to keep the
      # same behavior of pinv2 for scipy < 1.3, because the condition used to
      # determine the rank is dependent on the output of svd.
      u, s, vh = svd(a, full_matrices=False, check_finite=False)
  
      t = u.dtype.char.lower()
      factor = {"f": 1e3, "d": 1e6}
      cond = np.max(s) * factor[t] * np.finfo(t).eps
      rank = np.sum(s > cond)
  
      u = u[:, :rank]
      u /= s[:rank]
      return np.transpose(np.conjugate(np.dot(u, vh[:rank])))
  
imports: import warnings
  from abc import ABCMeta, abstractmethod
  from numbers import Integral, Real
  import numpy
  from scipy.linalg import svd
  from ..base import BaseEstimator, ClassNamePrefixFeaturesOutMixin, MultiOutputMixin, RegressorMixin, TransformerMixin, _fit_context
  from ..exceptions import ConvergenceWarning
  from ..utils import check_array, check_consistent_length
  from ..utils._param_validation import Interval, StrOptions
  from ..utils.extmath import svd_flip
  from ..utils.fixes import parse_version, sp_version
  from ..utils.validation import FLOAT_DTYPES, check_is_fitted
label_desc: Use image node_id 1 for calling a global function with example usage: _pinv2_old(a) and returns: np