code: def tril_indices(n, k=0, m=None):
      """
      Return the indices for the lower-triangle of an (n, m) array.
  
      Parameters
      ----------
      n : int
          The row dimension of the arrays for which the returned
          indices will be valid.
      k : int, optional
          Diagonal offset (see `tril` for details).
      m : int, optional
          .. versionadded:: 1.9.0
  
          The column dimension of the arrays for which the returned
          arrays will be valid.
          By default `m` is taken equal to `n`.
  
  
      Returns
      -------
      inds : tuple of arrays
          The indices for the triangle. The returned tuple contains two arrays,
          each with the indices along one dimension of the array.
  
      See also
      --------
      triu_indices : similar function, for upper-triangular.
      mask_indices : generic function accepting an arbitrary mask function.
      tril, triu
  
      Notes
      -----
      .. versionadded:: 1.4.0
  
      Examples
      --------
      Compute two different sets of indices to access 4x4 arrays, one for the
      lower triangular part starting at the main diagonal, and one starting two
      diagonals further right:
  
      >>> il1 = np.tril_indices(4)
      >>> il2 = np.tril_indices(4, 2)
  
      Here is how they can be used with a sample array:
  
      >>> a = np.arange(16).reshape(4, 4)
      >>> a
      array([[ 0,  1,  2,  3],
             [ 4,  5,  6,  7],
             [ 8,  9, 10, 11],
             [12, 13, 14, 15]])
  
      Both for indexing:
  
      >>> a[il1]
      array([ 0,  4,  5, ..., 13, 14, 15])
  
      And for assigning values:
  
      >>> a[il1] = -1
      >>> a
      array([[-1,  1,  2,  3],
             [-1, -1,  6,  7],
             [-1, -1, -1, 11],
             [-1, -1, -1, -1]])
  
      These cover almost the whole array (two diagonals right of the main one):
  
      >>> a[il2] = -10
      >>> a
      array([[-10, -10, -10,   3],
             [-10, -10, -10, -10],
             [-10, -10, -10, -10],
             [-10, -10, -10, -10]])
  
      """
      tri_ = tri(n, m, k=k, dtype=bool)
  
      return tuple(
          broadcast_to(inds, tri_.shape)[tri_]
          for inds in indices(tri_.shape, sparse=True)
      )
  
imports: import functools
  import operator
  from numpy.core.numeric import asanyarray, arange, zeros, greater_equal, multiply, ones, asarray, where, int8, int16, int32, int64, intp, empty, promote_types, diagonal, nonzero, indices
  from numpy.core.overrides import set_array_function_like_doc, set_module
  from numpy.core import overrides
  from numpy.core import iinfo
  from numpy.lib.stride_tricks import broadcast_to
label_desc: Use image node_id 18 for calling a global function with example usage: tril_indices(n, k, m) and returns: tuple