code: def _make_histogram_edges(
      min_feature_val, max_feature_val, histogram_weights
  ):
      native = Native.get_native_singleton()
  
      # the EBM model spec disallows subnormal values since they can be problems in computation
      # and serialization. We only use the min_feature_value and max_feature_value in the histogram edges as information
      # so this won't affect binning or reporting other than potentially visualization where subnormals can be ignored
  
      min_feature_val = native.clean_float(min_feature_val)
      max_feature_val = native.clean_float(max_feature_val)
  
      n_cuts = len(histogram_weights) - 3
      cuts = native.cut_uniform(
          np.array([min_feature_val, max_feature_val], np.float64),
          n_cuts,
      )
      if len(cuts) != n_cuts:
          raise Exception(
              f"There are insufficient floating point values between min_feature_val={min_feature_val} to max_feature_val={max_feature_val} to make {n_cuts} cuts"
          )
  
      return np.concatenate(
          ([min_feature_val], cuts, [max_feature_val])
      )
  
imports: from math import isnan
  import logging
  import numpy
  from ._native import Native
label_desc: Use image node_id 1 for calling a global function with example usage: _make_histogram_edges(min_feature_val, max_feature_val, histogram_weights) and returns: np