class_docstr: Really simple unweighted directed graph data structure to track dependencies.
  
  The API is pretty much the same as networkx so if you add something just
  copy their API.
class_docstr_tok: ["Really","simple","unweighted","directed","graph","data","structure","to","track","dependencies",".","The","API","is","pretty","much","the","same","as","networkx","so","if","you","add","something","just","copy","their","API","."]
code: def __init__(self):
      # Dict of node -> dict of arbitrary attributes
      self._node = {}
      # Nested dict of node -> successor node -> nothing.
      # (didn't implement edge data)
      self._succ = {}
      # Nested dict of node -> predecessor node -> nothing.
      self._pred = {}
  
      # Keep track of the order in which nodes are added to
      # the graph.
      self._node_order = {}
      self._insertion_idx = 0
  
file_path: pytorch/torch/package/_digraph.py
imports: from collections import deque
  from typing import List, Set
label_desc: Use image node_id 1 to create a new DiGraph object  with example: obj = DiGraph()