code: def shuffle(random_state, x, axis=0):
      r"""
      Modify a sequence in-place by shuffling its contents.
      The order of sub-arrays is changed but their contents remains the same.
  
      Parameters
      ----------
      x : array_like
          The array or list to be shuffled.
      axis : int, optional
          The axis which `x` is shuffled along. Default is 0.
  
      Returns
      -------
      None
  
      Examples
      --------
      >>> import mars.tensor as mt
      >>> rng = mt.random.RandomState()
      >>> arr = mt.arange(10)
      >>> rng.shuffle(arr)
      >>> arr.execute()
      array([0, 1, 4, 2, 8, 6, 5, 9, 3, 7]) # random
  
      >>> arr = mt.arange(9).reshape((3, 3))
      >>> rng.shuffle(arr)
      >>> arr.execute()
      array([[6, 7, 8], # random
             [0, 1, 2],
             [3, 4, 5]])
      """
      from .permutation import permutation
  
      if isinstance(x, (list, np.ndarray, TENSOR_TYPE)):
          x = astensor(x)
      else:
          raise TypeError("x should be list, numpy ndarray or tensor")
  
      ret = permutation(random_state, x, axis=axis)
      x.data = ret.data
  
imports: import numpy
  from ..datasource import tensor
  from ..core import TENSOR_TYPE
label_desc: Use image node_id 1 for calling a global function with example usage: shuffle(random_state, x, axis) without return types