code: def restore_runs(ctx, hashes, yes):
      """Rollback Runs data for given run hashes to the previous metric format."""
      if len(hashes) == 0:
          click.echo("Please specify at least one Run to delete.")
          exit(1)
      repo_path = ctx.obj["repo"]
      repo = Repo.from_path(repo_path)
  
      matched_hashes = match_runs(repo, hashes, lookup_dir="bcp")
      if yes:
          confirmed = True
      else:
          confirmed = click.confirm(
              f"This command will restore {len(matched_hashes)} runs from aim repo "
              f"located at '{repo_path}'. Do you want to proceed?"
          )
      if not confirmed:
          return
  
      remaining_runs = []
      index_manager = RepoIndexManager.get_index_manager(repo)
      for run_hash in tqdm(matched_hashes):
          try:
              restore_run_backup(repo, run_hash)
              index_manager.index(run_hash)
          except Exception as e:
              click.echo(
                  f"Error while trying to restore run '{run_hash}'. {str(e)}.",
                  err=True,
              )
              remaining_runs.append(run_hash)
  
      if not remaining_runs:
          click.echo(
              f"Successfully restored {len(matched_hashes)} runs."
          )
      else:
          click.echo(
              "Something went wrong while restoring runs. Remaining runs are:",
              err=True,
          )
          click.secho("\t".join(remaining_runs), fg="yellow")
  
file_path: aim/aim/cli/storage/commands.py
imports: import click
  import os
  from tqdm import tqdm
  from aim.cli.runs.utils import match_runs
  from aim.cli.upgrade.utils import convert_2to3
  from aim.sdk.maintenance_run import MaintenanceRun
  from aim.sdk.utils import backup_run, restore_run_backup
  from aim.sdk.repo import Repo
  from aim.sdk.index_manager import RepoIndexManager
label_desc: Use image node_id 5 for calling a global function with example usage: restore_runs(ctx, hashes, yes) without return types