code: def argwhere(a):
      """
      Find the indices of tensor elements that are non-zero, grouped by element.
  
      Parameters
      ----------
      a : array_like
          Input data.
  
      Returns
      -------
      index_tensor : Tensor
          Indices of elements that are non-zero. Indices are grouped by element.
  
      See Also
      --------
      where, nonzero
  
      Notes
      -----
      ``mt.argwhere(a)`` is the same as ``mt.transpose(mt.nonzero(a))``.
  
      The output of ``argwhere`` is not suitable for indexing tensors.
      For this purpose use ``nonzero(a)`` instead.
  
      Examples
      --------
      >>> import mars.tensor as mt
  
      >>> x = mt.arange(6).reshape(2,3)
      >>> x.execute()
      array([[0, 1, 2],
             [3, 4, 5]])
      >>> mt.argwhere(x>1).execute()
      array([[0, 2],
             [1, 0],
             [1, 1],
             [1, 2]])
  
      """
      a = astensor(a).astype(bool, order="A")
      op = TensorArgwhere(dtype=np.dtype(np.intp))
      return op(a)
  
file_path: mars/mars/tensor/base/argwhere.py
imports: import itertools
  import numpy
  from ...None import opcodes
  from ...core import recursive_tile
  from ...serialization.serializables import KeyField
  from ...utils import has_unknown_shape
  from ..operands import TensorHasInput, TensorOperandMixin
  from ..datasource import tensor
  from .ravel import ravel
label_desc: Use image node_id 1 for calling a global function with example usage: argwhere(a) and returns: op