code: def run_h2oai(benchmark: Benchmark):
      """This benchmark is originally from https://github.com/h2oai/db-benchmark
  
      Here we run all group-by queries from the benchmark on Ray Datasets.
      The input files are pre-generated and stored in AWS S3 beforehand.
      """
  
      # Test input file schema={
      #   id1: string, id2: string, id3: string, id4: int64, id5: int64, id6: int64,
      #   v1: int64, v2: int64, v3: double
      # })
      test_input = [
          (
              "s3://air-example-data/h2oai_benchmark/G1_1e7_1e2_0_0.csv",
              "h2oai-500M",
          )
      ]
      for path, test_name in test_input:
          input_ds = ray.data.read_csv(path)
          # Number of blocks (parallelism) should be set as number of available CPUs
          # to get best performance.
          num_blocks = int(ray.cluster_resources().get("CPU", 1))
          input_ds = input_ds.repartition(num_blocks).materialize()
  
          q_list = [
              (h2oai_q1, "q1"),
              (h2oai_q3, "q3"),
              (h2oai_q4, "q4"),
              (h2oai_q5, "q5"),
              (h2oai_q7, "q7"),
              (h2oai_q8, "q8"),
          ]
  
          for q, name in q_list:
              benchmark.run_materialize_ds(
                  f"{test_name}-{name}", q, ds=input_ds
              )
  
file_path: ray/release/nightly_tests/dataset/aggregate_benchmark.py
imports: from typing import Tuple
  import ray
  from ray.data.aggregate import Max, Mean, Min, Sum
  from ray.data.aggregate._aggregate import _AggregateOnKeyBase
  from ray.data.block import Block
  from ray.data.dataset import Dataset
  import pyarrow.compute
  from benchmark import Benchmark
label_desc: Use image node_id 1 for calling a global function with example usage: run_h2oai(benchmark) without return types