code: def cho_solve(c_and_lower, b, overwrite_b=False, check_finite=True):
      """Solve the linear equations A x = b, given the Cholesky factorization of A.
  
      Parameters
      ----------
      (c, lower) : tuple, (array, bool)
          Cholesky factorization of a, as given by cho_factor
      b : array
          Right-hand side
      overwrite_b : bool, optional
          Whether to overwrite data in b (may improve performance)
      check_finite : bool, optional
          Whether to check that the input matrices contain only finite numbers.
          Disabling may give a performance gain, but may result in problems
          (crashes, non-termination) if the inputs do contain infinities or NaNs.
  
      Returns
      -------
      x : array
          The solution to the system A x = b
  
      See also
      --------
      cho_factor : Cholesky factorization of a matrix
  
      Examples
      --------
      >>> from scipy.linalg import cho_factor, cho_solve
      >>> A = np.array([[9, 3, 1, 5], [3, 7, 5, 1], [1, 5, 9, 2], [5, 1, 2, 6]])
      >>> c, low = cho_factor(A)
      >>> x = cho_solve((c, low), [1, 1, 1, 1])
      >>> np.allclose(A @ x - [1, 1, 1, 1], np.zeros(4))
      True
  
      """
      (c, lower) = c_and_lower
      if check_finite:
          b1 = asarray_chkfinite(b)
          c = asarray_chkfinite(c)
      else:
          b1 = asarray(b)
          c = asarray(c)
      if c.ndim != 2 or c.shape[0] != c.shape[1]:
          raise ValueError("The factored matrix c is not square.")
      if c.shape[1] != b1.shape[0]:
          raise ValueError("incompatible dimensions.")
  
      overwrite_b = overwrite_b or _datacopied(b1, b)
  
      (potrs,) = get_lapack_funcs(("potrs",), (c, b1))
      x, info = potrs(c, b1, lower=lower, overwrite_b=overwrite_b)
      if info != 0:
          raise ValueError(
              "illegal value in %d-th argument of internal potrs"
              % -info
          )
      return x
  
file_path: catboost/contrib/python/scipy/py2/scipy/linalg/decomp_cholesky.py
imports: from __future__ import division, print_function, absolute_import
  from numpy import asarray_chkfinite, asarray, atleast_2d
  from .misc import LinAlgError, _datacopied
  from .lapack import get_lapack_funcs
label_desc: Use image node_id 4 for calling a global function with example usage: cho_solve(c_and_lower, b, overwrite_b, check_finite) and returns: x