code: def test_groupby_params():
      raw = pd.DataFrame({"a": [1, 2, 3]})
      df = DataFrame(raw)
      grouped = df.groupby("a")
      grouped = tile(grouped)
      c = grouped.chunks[0]
  
      c.params = c.get_params_from_data(wrapped_groupby(raw, by="a"))
      params = c.params.copy()
      params.pop("index", None)
      grouped.params = params
  
      raw = pd.Series([1, 2, 3], name="a")
      series = Series(raw)
      grouped = series.groupby(level=0)
      grouped = tile(grouped)
      c = grouped.chunks[0]
  
      c.params = c.get_params_from_data(wrapped_groupby(raw, level=0))
      params = c.params.copy()
      params.pop("index", None)
      grouped.params = params
      grouped.refresh_params()
  
file_path: mars/mars/dataframe/tests/test_core.py
imports: import numpy
  import pandas
  import pytest
  from ...core import tile
  from ...lib.groupby_wrapper import wrapped_groupby
  from ...utils import pd_release_version
  from ..None import cut
  from ..initializer import DataFrame, Series, Index
label_desc: Use image node_id 5 for calling a global function with example usage: test_groupby_params() without return types