edu.stanford.nlp.semgraph.SemanticGraph.resetRoots()
This method should not be used if possible. TODO: delete it Recomputes the roots, based of actual candidates. This is done to ensure a rooted tree after a sequence of edits. If the none of the vertices can act as a root (due to a cycle), keep old rootset, retaining only the existing vertices on that list. TODO: this cannot deal with "Hamburg is a city which everyone likes", as the intended root node,'Hamburg, is also the dobj of the relative clause. A possible solution would be to create edgeset routines that allow filtering over a predicate, and specifically filter out dobj relations for choosing next best candidate. This could also be useful for dealing with non-syntactic arcs in the future. TODO: There is also the possibility the roots could be empty at the end, and will need to be resolved. TODO: determine if this is a reasonably correct solution.