code: def get_bin_centers(hist):
      """Get bin centers or labels of histogram"""
      if isinstance(hist, histogrammar.Bin):  # Bin
          centers, values = hist.bin_centers(), hist.values
      elif isinstance(hist, histogrammar.SparselyBin):
          centers, values = sparse_bin_centers_x(hist)
      else:  # categorize
          centers, values = hist.bin_labels(), hist.values
      return centers, values
  
file_path: popmon/popmon/hist/hist_utils.py
imports: import histogrammar
  import histogrammar.specialized
  import numpy
  import pandas
  from histogrammar.specialized import CategorizeHistogramMethods, HistogramMethods, SparselyHistogramMethods, SparselyTwoDimensionallyHistogramMethods, TwoDimensionallyHistogramMethods
  from histogrammar.util import get_hist_props
label_desc: Use image node_id 9 for calling a global function with example usage: get_bin_centers(hist) and returns: centers,  values