code: def get_discrete_params(data, metric):
      if metric == "ordinal":
          return {"support_size": float(data.max() - data.min()) / 2.0}
      elif metric == "count":
          min_count = scipy.stats.tmin(data)
          max_count = scipy.stats.tmax(data)
          lambda_ = scipy.stats.tmean(data)
          normalisation = count_distance(
              min_count, max_count, poisson_lambda=lambda_
          )
          return {
              "poisson_lambda": lambda_,
              "normalisation": normalisation / 2.0,  # heuristic
          }
      elif metric == "string":
          lengths = np.array([len(x) for x in data])
          max_length = scipy.stats.tmax(lengths)
          max_dist = max_length / 1.5  # heuristic
          normalisation = max_dist / 2.0  # heuristic
          return {
              "normalisation": normalisation,
              "max_dist": max_dist / 2.0,
          }  # heuristic
  
      else:
          return {}
  
imports: import numba
  import numpy
  import scipy.stats
  from sklearn.metrics import pairwise_distances
label_desc: Use image node_id 51 for calling a global function with example usage: get_discrete_params(data, metric) and returns: dict, dict, dict, dict