class_docstr: MATH is a dataset of 12,500 challenging competition mathematics problems.
code: def _generate_examples(self, basepath, split):
      key = 0
      for file in sorted(pathlib.Path(basepath).iterdir()):
          with open(file, "r", encoding="utf-8") as f:
              data = json.load(f)
              yield key, {
                  "problem": data["problem"],
                  "level": data["level"],
                  "type": data["type"],
                  "solution": data["solution"],
              }
              key += 1
  
file_path: lm-evaluation-harness/lm_eval/datasets/hendrycks_math/hendrycks_math.py
imports: import json
  import os
  import pathlib
  import datasets
label_desc: Use image node_id 3 for calling the HendrycksMath obj's underlying member method code with example usage: obj._generate_examples(basepath, split) without return types