def METHOD_NAME(data, order):
  if order is None or (not isinstance(data, np.ndarray)):
    return data
  if len(order) != data.ndim:
    raise RuntimeError("The data dimensions should consistent with length of order")
  return np.transpose(data, order)