Fix error in graph.py