class_docstr: A data module which provides a frequency-category split of the M4 dataset as a standalone dataset.
class_docstr_tok: ["A","data","module","which","provides","a","frequency-category","split","of","the","M4","dataset","as","a","standalone","dataset","."]
code: def _materialize(self, directory: Path) -> None:
      generate_m4_dataset(
          dataset_path=directory / self.dataset_name,
          m4_freq=self.freq,
          pandas_freq=self.freq[0],
          prediction_length=M4_PREDICTION_LENGTHS[self.freq],
          category=self.category,
      )
  
file_path: gluonts/src/gluonts/nursery/few_shot_prediction/src/meta/datasets/m4.py
imports: import json
  import os
  from pathlib import Path
  import numpy
  import pandas
  from gluonts.dataset.repository._util import metadata, save_to_file, to_dict
  from meta.datasets.gluonts import GluonTSDataModule
  from meta.datasets.registry import register_data_module
label_desc: Use image node_id 2 for calling the M4DataModule obj's underlying member method code with example usage: obj._materialize(directory) without return types