code: def run_from_argv() -> None:
      """Collect data for a benchmark suite, based on command line arguments."""
      parser = argparse.ArgumentParser(
          description="Run a benchmark suite."
      )
      parser.add_argument(
          "--no_subdir",
          "--no-subdir",
          action="store_true",
          help="By default this script will create a subdirectory inside `dest` and write output to"
          " that. Setting this flag will suppress the subdirectory and use `dest` directly.",
      )
      parser.add_argument(
          "--no_plot",
          "--no-plot",
          action="store_true",
          help="By default this script will create plots of data."
          " Setting this flag will suppress plotting.",
      )
      parser.add_argument(
          "--cache_dir",
          "--cache-dir",
          type=Path,
          default=Path("/tmp/gpflow_benchmark_data"),
          help="Where to cache stuff, like datasets.",
      )
      parser.add_argument(
          "--shard",
          default=ShardingStrategy("no"),
          type=ShardingStrategy,
          help=(
              "Sharding strategy:"
              " If set to 'no' this script performs all necessary work."
              " If set to 'start' this script creates an output directory for the shards, and"
              " prints its path."
              " If set to the format '<i>/<n>', where 0 <= i < n then this script only runs"
              " benchmarks for shard 'i' out of 'n', and stores partial results in 'dest'."
              " This requires '--no_subdir'."
              " If set to 'collect' then this script assumes all benchmarks already have been"
              " computed, using the '<i>/<n>' commands, and merges their results into one file."
              " This requires '--no_subdir'."
          ),
      )
      parser.add_argument(
          "suite",
          type=str,
          choices=BENCHMARK_SUITES.names(),
          help="Which benchmark suite to run.",
      )
      parser.add_argument(
          "dest",
          type=Path,
          help="Directory to write results to.",
      )
  
      args = parser.parse_args()
      suite = BENCHMARK_SUITES.get(args.suite)
      run(
          args.shard,
          suite,
          args.dest,
          args.no_subdir,
          args.cache_dir,
          not args.no_plot,
      )
  
imports: import argparse
  import json
  import multiprocessing
  import traceback
  from datetime import timedelta
  from pathlib import Path
  from time import perf_counter
  from typing import Mapping, Optional
  import numpy
  import pandas
  from tabulate import tabulate
  import benchmark.benchmarks
  import benchmark.metrics
  import gpflow
  from benchmark.benchmark_api import BENCHMARK_SUITES, BenchmarkSuite, BenchmarkTask
  from benchmark.dataset_api import DATASET_FACTORIES
  from benchmark.metadata import BenchmarkMetadata
  from benchmark.metric_api import Metric
  from benchmark.model_api import MODEL_FACTORIES
  from benchmark.paths import setup_dest
  from benchmark.plot import plot
  from benchmark.sharding import ShardingStrategy
label_desc: Use image node_id 5 for calling a global function with example usage: run_from_argv() without return types