Some changes to the graph stuff