Update Directedgraph.py