code: def copy_trials(
      suffix: str = "", exclude_single_searcher: bool = True
  ) -> dict:
      """
      Duplicate trials and associated metrics for multi trial experiments.
      """
      with db_cursor() as cur:
          with _copy_trials(
              cur, suffix, exclude_single_searcher
          ) as affected_rows:
              return affected_rows
  
file_path: determined/tools/scripts/replicate-metrics.py
imports: import concurrent.futures
  import contextlib
  import os
  import time
  from typing import Any, Dict, Generator, List, Set, Tuple, Union
  import psycopg
  from psycopg import sql
label_desc: Use image node_id 8 for calling a global function with example usage: copy_trials(suffix, exclude_single_searcher) and returns: affected_rows