code: def log_warning_if_all_grid_type_parameters(
      hyperopt_config: HyperoptConfigDict,
  ) -> None:
      """Logs warning if all parameters have a grid type search space and num_samples > 1 since this will result in
      duplicate trials being created."""
      num_duplicate_trials = get_num_duplicate_trials(hyperopt_config)
      if num_duplicate_trials == 0:
          return
  
      num_samples = hyperopt_config[EXECUTOR].get(NUM_SAMPLES, 1)
      warnings.warn(
          "All hyperopt parameters in Ludwig config are using grid_search space, but number of samples "
          f"({num_samples}) is greater than 1. This will result in {num_duplicate_trials} duplicate trials being "
          "created. Consider setting `num_samples` to 1 in the hyperopt executor to prevent trial duplication.",
          RuntimeWarning,
      )
  
imports: import copy
  import dataclasses
  import json
  import logging
  import os
  import warnings
  from typing import Any, Dict
  from ludwig.api_annotations import DeveloperAPI
  from ludwig.constants import AUTO, COMBINED, EXECUTOR, GOAL, GRID_SEARCH, HYPEROPT, INPUT_FEATURES, LOSS, MAX_CONCURRENT_TRIALS, METRIC, MINIMIZE, NAME, NUM_SAMPLES, OUTPUT_FEATURES, PARAMETERS, PREPROCESSING, RAY, SPACE, SPLIT, TYPE, VALIDATION
  from ludwig.globals import HYPEROPT_STATISTICS_FILE_NAME
  from ludwig.hyperopt.results import HyperoptResults, TrialResults
  from ludwig.types import HyperoptConfigDict, ModelConfigDict
  from ludwig.utils.data_utils import save_json
  from ludwig.utils.misc_utils import get_class_attributes, get_from_registry, merge_dict, set_default_value, set_default_values
  from ludwig.utils.print_utils import print_boxed
label_desc: Use image node_id 11 for calling a global function with example usage: log_warning_if_all_grid_type_parameters(hyperopt_config) without return types