code: def get_step_metric_dict(ml):
      """Get mapping from metric to preferred x-axis."""
      nl = [m["1"] for m in ml]
      md = {m["1"]: nl[m["5"] - 1] for m in ml if m.get("5")}
      return md
  
label_desc: Use image node_id 1 for calling a global function with example usage: get_step_metric_dict(ml) and returns: md