plots graph with pydot