code: def test_dictionary_values_to_lists():
      """Tests dictionary_values_to_lists"""
      exponential_distribution = scipy.stats.expon(scale=0.1)
      hyperparameter_grid = {
          "param1": [],
          "param2": [None],
          "param3": ["value1", "value2"],
          "param4": [[1, 2], [3, 4]],
          "param5": [1],
          "param6": [[1], 2, [3]],
          "param7": [[1], None, [3]],
          "param8": (1, 2, 3),
          "param9": None,
          "param10": [None, ["US", "UK"]],
          "param11": [None, "auto", "special_value"],
          "param12": [None, "auto", ["US", "UK"]],
          "param13": 1.5,
          "param14": exponential_distribution,
          "param15": {"k": "v"},
          "param16": np.array([1, 2, 3]),
          "param17": pd.DataFrame([1, 2, 3]),
      }
      original_grid = hyperparameter_grid.copy()
  
      # 1) None for `hyperparameters_list_type`
      result = dictionary_values_to_lists(hyperparameter_grid)
      expected_grid = {
          "param1": [],
          "param2": [None],
          "param3": ["value1", "value2"],
          "param4": [[1, 2], [3, 4]],
          "param5": [1],
          "param6": [[1], 2, [3]],
          "param7": [[1], None, [3]],
          "param8": (1, 2, 3),
          "param9": [None],
          "param10": [None, ["US", "UK"]],
          "param11": [None, "auto", "special_value"],
          "param12": [None, "auto", ["US", "UK"]],
          "param13": [1.5],
          "param14": exponential_distribution,
          "param15": [{"k": "v"}],
          "param16": [np.array([1, 2, 3])],
          "param17": [pd.DataFrame([1, 2, 3])],
      }
      assert_equal(result, expected_grid)
      # Original dictionary is not modified
      assert_equal(hyperparameter_grid, original_grid)
  
      # 2) Set for `hyperparameters_list_type` (param1 to param12)
      hyperparameters_list_type = set(
          {f"param{i+1}" for i in range(12)}
      )
      result = dictionary_values_to_lists(
          hyperparameter_grid,
          hyperparameters_list_type=hyperparameters_list_type,
      )
      # Param 4, 9, 11 are already in the proper format
      expected_grid = {
          "param1": [[]],
          "param2": [None],
          "param3": [["value1", "value2"]],
          "param4": [[1, 2], [3, 4]],
          "param5": [[1]],
          "param6": [[[1], 2, [3]]],
          "param7": [[1], None, [3]],
          "param8": [(1, 2, 3)],
          "param9": [None],
          "param10": [None, ["US", "UK"]],
          "param11": [
              [None, "auto", "special_value"]
          ],  # converted to list
          "param12": [
              [None, "auto", ["US", "UK"]]
          ],  # converted to list
          "param13": [1.5],
          "param14": exponential_distribution,
          "param15": [{"k": "v"}],
          "param16": [np.array([1, 2, 3])],
          "param17": [pd.DataFrame([1, 2, 3])],
      }
      assert_equal(result, expected_grid)
      # Original dictionary is not modified
      assert_equal(hyperparameter_grid, original_grid)
  
      # 3) Dict for `hyperparameters_list_type`
      hyperparameters_list_type = {
          k: [None] for k in hyperparameters_list_type
      }
      hyperparameters_list_type["param11"] = [
          None,
          "auto",
          "special_value",
      ]
      hyperparameters_list_type["param12"] = [
          None,
          "auto",
          "special_value",
      ]
      result = dictionary_values_to_lists(
          hyperparameter_grid,
          hyperparameters_list_type=hyperparameters_list_type,
      )
      expected_grid = {
          "param1": [[]],
          "param2": [None],
          "param3": [["value1", "value2"]],
          "param4": [[1, 2], [3, 4]],
          "param5": [[1]],
          "param6": [[[1], 2, [3]]],
          "param7": [[1], None, [3]],
          "param8": [(1, 2, 3)],
          "param9": [None],
          "param10": [None, ["US", "UK"]],
          "param11": [None, "auto", "special_value"],
          "param12": [None, "auto", ["US", "UK"]],
          "param13": [1.5],
          "param14": exponential_distribution,
          "param15": [{"k": "v"}],
          "param16": [np.array([1, 2, 3])],
          "param17": [pd.DataFrame([1, 2, 3])],
      }
      assert_equal(result, expected_grid)
      # Original dictionary is not modified
      assert_equal(hyperparameter_grid, original_grid)
  
      # Checks exception
      with pytest.raises(
          ValueError,
          match=r"The value for param1 must be a list, tuple, or one of \[None\], found {'k': 'v'}.",
      ):
          hyperparameter_grid = {"param1": {"k": "v"}}
          dictionary_values_to_lists(
              hyperparameter_grid, hyperparameters_list_type={"param1"}
          )
  
imports: import warnings
  from dataclasses import dataclass
  from typing import List
  import numpy
  import pandas
  import pytest
  import scipy
  from greykite.common import constants
  from greykite.common.evaluation import ElementwiseEvaluationMetricEnum
  from greykite.common.python_utils import apply_func_to_columns
  from greykite.common.python_utils import assert_equal
  from greykite.common.python_utils import dictionaries_values_to_lists
  from greykite.common.python_utils import dictionary_values_to_lists
  from greykite.common.python_utils import flatten_list
  from greykite.common.python_utils import get_integer
  from greykite.common.python_utils import get_pattern_cols
  from greykite.common.python_utils import group_strs_with_regex_patterns
  from greykite.common.python_utils import ignore_warnings
  from greykite.common.python_utils import mutable_field
  from greykite.common.python_utils import reorder_columns
  from greykite.common.python_utils import split_offset_str
  from greykite.common.python_utils import unique_dict_in_list
  from greykite.common.python_utils import unique_elements_in_list
  from greykite.common.python_utils import unique_in_list
  from greykite.common.python_utils import update_dictionaries
  from greykite.common.python_utils import update_dictionary
label_desc: Use image node_id 8 for calling a global function with example usage: test_dictionary_values_to_lists() without return types