Improve efficiency by making DependencyGraph a simple hash of sets rather than a hash of nodes with outgoing sets