7 from pygraph.classes.graph import graph
8 from pygraph.classes.digraph import digraph
9 from pygraph.algorithms.searching import breadth_first_search
10 from pygraph.readwrite.dot import write
16 def make_graph(Self,parents,children,otherparents):
27 for i in range(len(children)):
28 gr.add_nodes([children[i]])
29 gr.add_edge((Self,children[i]))
30 if not gr.has_node(otherparents[i]):
31 gr.add_nodes([otherparents[i]])
32 gr.add_edge((otherparents[i],children[i]))
39 # gvv = gv.readstring(dot)
40 # gv.layout(gvv,'dot')
42 # print "Content-type: image/png\n"
43 # print gv.render(gvv,'png')
45 form = cgi.FieldStorage()
52 make_graph(Self,p,c,op)