class_docstr: Base class for min-heaps.
  
  A MinHeap stores a collection of key-value pairs ordered by their values.
  It supports querying the minimum pair, inserting a new pair, decreasing the
  value in an existing pair and deleting the minimum pair.
class_docstr_tok: ["Base","class","for","min-heaps",".","A","MinHeap","stores","a","collection","of","key-value","pairs","ordered","by","their","values",".","It","supports","querying","the","minimum","pair",",","inserting","a","new","pair",",","decreasing","the","value","in","an","existing","pair","and","deleting","the","minimum","pair","."]
docstr: Query the minimum key-value pair.
  
  Returns
  -------
  key, value : tuple
      The key-value pair with the minimum value in the heap.
  
  Raises
  ------
  NetworkXError
      If the heap is empty.
docstr_tok: ["Query","the","minimum","key-value","pair",".","Returns","--","--","--","-","key",",","value",":","tuple","The","key-value","pair","with","the","minimum","value","in","the","heap",".","Raises","--","--","--","NetworkXError","If","the","heap","is","empty","."]
code: def min(self):
      """Query the minimum key-value pair.
  
      Returns
      -------
      key, value : tuple
          The key-value pair with the minimum value in the heap.
  
      Raises
      ------
      NetworkXError
          If the heap is empty.
      """
      raise NotImplementedError
  
imports: from heapq import heappop, heappush
  from itertools import count
  import networkx
label_desc: Use image node_id 2 for calling the MinHeap obj's underlying member method code with example usage: obj.min() without return types