Common labels replaced. Subgraphs written to files