Assign topologically stable unique ids to self
Following the call, all nodes in the tree will have their id attribute set