code: def check_test_cases(
      test_cases: List[TestCase],
      dist_func: Callable[[List[int], str], float],
  ):
      for test_case in test_cases:
          dist = dist_func(test_case.point, test_case.rel_str)
          dist_gt = test_case.dist
          assert (
              abs(dist - dist_gt) < TOL
          ), f"{test_case.rel_str} {test_case.point}"
  
file_path: H2O/h2o_hf/helm/src/helm/benchmark/metrics/test_numeracy_metrics.py
imports: from dataclasses import dataclass
  from typing import List, Callable
  from helm.benchmark.scenarios.numeracy_scenario import distance_linear, distance_parabola, distance_plane, distance_paraboloid
label_desc: Use image node_id 1 for calling a global function with example usage: check_test_cases(test_cases, dist_func) without return types