After #582, we'll want to apply the same relabeling technique to utility functions embed_bqm and unembed_sampleset.
Currently, embed_bqm creates EmbeddedStructure on the fly, but that's not strictly necessary if the embedding can be reduced to 1-1 relabeling. After the structure is created (~200ms on my laptop), relabeling shortcircuit is applied, but we can still reduce total time by: (1) avoiding EmbeddedStructure creation, or (2) deferring the slow construction bits until they're actually needed.
Similarly for unembed_sampleset; if a dict embedding is passed, relabeling optimization is not applied.
This should bring speed-ups from #582 to composites that use utility functions for embedding, like TilingComposite and ParallelEmbeddingComposite.
After #582, we'll want to apply the same relabeling technique to utility functions
embed_bqmandunembed_sampleset.Currently,
embed_bqmcreatesEmbeddedStructureon the fly, but that's not strictly necessary if the embedding can be reduced to 1-1 relabeling. After the structure is created (~200ms on my laptop), relabeling shortcircuit is applied, but we can still reduce total time by: (1) avoidingEmbeddedStructurecreation, or (2) deferring the slow construction bits until they're actually needed.Similarly for
unembed_sampleset; if a dict embedding is passed, relabeling optimization is not applied.This should bring speed-ups from #582 to composites that use utility functions for embedding, like
TilingCompositeandParallelEmbeddingComposite.