class_docstr: An intermediate representation for DL graph.
code: def topologically_sorted(self):
      visited = set()
      sorted_nodes = []
  
      def topo_sort_dfs(node, visited, sorted_nodes):
          if node in visited:
              return
          visited.add(node)
          for n in self.get_input(node):
              topo_sort_dfs(n, visited, sorted_nodes)
          sorted_nodes.append(node)
  
      for node in self.node_dict.values():
          topo_sort_dfs(node, visited, sorted_nodes)
      return sorted_nodes
  
imports: import six
  from six import string_types
  from mmdnn.conversion.caffe.errors import ConversionError
  from mmdnn.conversion.common.IR.graph_pb2 import GraphDef, NodeDef, TensorShape
  from mmdnn.conversion.caffe.utils import get_real_name
label_desc: Use image node_id 2 for calling the Graph obj's underlying member method code with example usage: obj.topologically_sorted() and returns: sorted_nodes