code: def get_hydra_sweeps(path_overrides):
      from hydra._internal.core_plugins.basic_sweeper import (
          BasicSweeper,
      )
      from hydra.core.override_parser.types import ValueType
  
      path_sweeps = {}
      for path, overrides in path_overrides.items():
          overrides = to_hydra_overrides(overrides)
          for override in overrides:
              if override.value_type == ValueType.GLOB_CHOICE_SWEEP:
                  raise InvalidArgumentError(
                      f"Glob override '{override.input_line}' is not supported."
                  )
          path_sweeps[path] = BasicSweeper.split_arguments(
              overrides, None
          )[0]
      return dict_product(path_sweeps)
  
file_path: dvc/dvc/utils/hydra.py
imports: from pathlib import Path
  from typing import TYPE_CHECKING, List, Optional
  from dvc.exceptions import InvalidArgumentError
  from dvc.log import logger
  from .collections import merge_dicts, remove_missing_keys, to_omegaconf
label_desc: Use image node_id 5 for calling a global function with example usage: get_hydra_sweeps(path_overrides) and returns: dict_product