code: def cholesky(a, lower=False):
      """
      Returns the Cholesky decomposition, :math:`A = L L^*` or
      :math:`A = U^* U` of a Hermitian positive-definite matrix A.
  
      Parameters
      ----------
      a : (M, M) array_like
          Matrix to be decomposed
      lower : bool, optional
          Whether to compute the upper or lower triangular Cholesky
          factorization.  Default is upper-triangular.
  
      Returns
      -------
      c : (M, M) Array
          Upper- or lower-triangular Cholesky factor of `a`.
      """
  
      l, u = _cholesky(a)
      if lower:
          return l
      else:
          return u
  
imports: from __future__ import annotations
  import operator
  import warnings
  from functools import partial
  from numbers import Number
  import numpy
  import tlz
  from dask.array.core import Array, concatenate, dotmany, from_delayed
  from dask.array.creation import eye
  from dask.array.random import RandomState, default_rng
  from dask.array.utils import array_safe, meta_from_array, solve_triangular_safe, svd_flip
  from dask.base import tokenize, wait
  from dask.blockwise import blockwise
  from dask.delayed import delayed
  from dask.highlevelgraph import HighLevelGraph
  from dask.utils import apply, derived_from
label_desc: Use image node_id 18 for calling a global function with example usage: cholesky(a, lower) and returns: l, u