code: def show(
      repo: "Repo",
      targets: Optional[List[str]] = None,
      stages: Optional[List[str]] = None,
      deps_only: bool = False,
      all_branches: bool = False,
      all_tags: bool = False,
      revs: Optional[List[str]] = None,
      all_commits: bool = False,
      hide_workspace: bool = True,
      on_error: str = "return",
  ) -> Dict[str, Result]:
      assert on_error in ("raise", "return", "ignore")
      res = {}
  
      targets = ensure_list(targets)
      targets = [repo.dvcfs.from_os_path(target) for target in targets]
  
      for rev in repo.brancher(
          revs=revs,
          all_branches=all_branches,
          all_tags=all_tags,
          all_commits=all_commits,
      ):
          try:
              params = _gather_params(
                  repo=repo,
                  targets=targets,
                  stages=stages,
                  deps_only=deps_only,
                  on_error=on_error,
              )
              res[rev] = Result(data=params)
          except Exception as exc:  # noqa: BLE001
              if on_error == "raise":
                  raise
              logger.warning(
                  "failed to load params in revision %r, %s",
                  rev,
                  str(exc),
              )
              if on_error == "return":
                  res[rev] = Result(error=exc)
  
      if hide_workspace:
          from dvc.repo.metrics.show import _hide_workspace
  
          _hide_workspace(repo.scm, res)
      return res
  
file_path: dvc/dvc/repo/params/show.py
imports: import os
  from collections import defaultdict
  from itertools import chain
  from typing import TYPE_CHECKING, Any, Dict, Iterator, List, Optional, Tuple, Union
  from dvc.dependency.param import ParamsDependency, read_param_file
  from dvc.log import logger
  from dvc.repo.metrics.show import FileResult, Result
  from dvc.stage import PipelineStage
  from dvc.utils import as_posix, expand_paths
  from dvc.utils.collections import ensure_list
label_desc: Use image node_id 7 for calling a global function with example usage: show(repo, targets, stages, deps_only, all_branches, all_tags, revs, all_commits, hide_workspace, on_error) and returns: res