code: def initalize_heap_from_graph_indices(
      heap, graph_indices, data, metric
  ):
      for i in range(graph_indices.shape[0]):
          for idx in range(graph_indices.shape[1]):
              j = graph_indices[i, idx]
              if j >= 0:
                  d = metric(data[i], data[j])
                  checked_flagged_heap_push(
                      heap[1][i], heap[0][i], heap[2][i], d, j, 1
                  )
  
      return heap
  
imports: import time
  import numba
  from numba.core import types
  import numba.experimental.structref
  import numpy
label_desc: Use image node_id 20 for calling a global function with example usage: initalize_heap_from_graph_indices(heap, graph_indices, data, metric) and returns: heap