rearranging
some graph transformation cleanup