code: def _test_distance_params(
      param_list: List[Dict], distance_func: Callable, distance_str: str
  ):
      x_univ = to_numba_timeseries(create_test_distance_numpy(10, 1))
      y_univ = to_numba_timeseries(
          create_test_distance_numpy(10, 1, random_state=2)
      )
  
      x_multi = create_test_distance_numpy(10, 10)
      y_multi = create_test_distance_numpy(10, 10, random_state=2)
  
      test_ts = [[x_univ, y_univ], [x_multi, y_multi]]
      results_to_fill = []
  
      i = 0
      for param_dict in param_list:
          j = 0
          curr_results = []
          for x, y in test_ts:
              results = []
              curr_dist_fact = distance_factory(
                  x, y, metric=distance_str, **param_dict
              )
              results.append(distance_func(x, y, **param_dict))
              results.append(
                  distance(x, y, metric=distance_str, **param_dict)
              )
              results.append(curr_dist_fact(x, y))
              if distance_str in _expected_distance_results_params:
                  if (
                      _expected_distance_results_params[distance_str][
                          i
                      ][j]
                      is not None
                  ):
                      for result in results:
                          assert result == pytest.approx(
                              _expected_distance_results_params[
                                  distance_str
                              ][i][j]
                          )
              curr_results.append(results[0])
              j += 1
          i += 1
          results_to_fill.append(curr_results)
  
file_path: sktime/sktime/distances/tests/test_numba_distance_parameters.py
imports: from typing import Callable, Dict, List
  import numpy
  import pytest
  from sktime.distances import distance, distance_factory
  from sktime.distances._distance import _METRIC_INFOS
  from sktime.distances._numba_utils import to_numba_timeseries
  from sktime.distances.base import MetricInfo
  from sktime.distances.tests._expected_results import _expected_distance_results_params
  from sktime.distances.tests._utils import create_test_distance_numpy
  from sktime.tests.test_switch import run_test_for_class
  from sktime.utils.numba.njit import njit
  from sktime.utils.validation._dependencies import _check_soft_dependencies
label_desc: Use image node_id 1 for calling a global function with example usage: _test_distance_params(param_list, distance_func, distance_str) without return types