code: def setup_dest(
      metadata: BenchmarkMetadata, dest: Path, no_subdir: bool
  ) -> Path:
      """
      Set up destination/output directory.
  
      :param metadata: Data about this run.
      :param dest: Root destination directory.
      :param no_subdir: Whether to NOT create a subdirectory of ``dest``.
      :return: Path to new destination directory.
      """
      if not no_subdir:
          root = dest
          root.mkdir(parents=True, exist_ok=True)
  
          relative_dest = Path(metadata.run_id)
          dest = root / relative_dest
          dest.mkdir()
  
          latest_dir = root / "latest"
          if latest_dir.is_symlink():
              latest_dir.unlink()
          latest_dir.symlink_to(relative_dest)
      else:
          dest.mkdir(parents=True)
      return dest
  
label_desc: Use image node_id 1 for calling a global function with example usage: setup_dest(metadata, dest, no_subdir) and returns: dest