Get 'placements' mapping small_graph nodes onto those of
big_graph: nx.Graph, small_graph: nx.Graph, max_placements=100000
) -> List[Dict]
Used in the notebooks
This function considers monomorphisms with a restriction: we restrict only to unique set
big_graph qubits. Some monomorphisms may be basically
the same mapping just rotated/flipped which we purposefully exclude. This could
exclude meaningful differences like using the same qubits but having the edges assigned
differently, but it prevents the number of placements from blowing up.
The parent, super-graph. We often consider the case where this is a
nx.Graph representation of a Device whose nodes are
The subgraph. We often consider the case where this is a NamedTopology
Raise a value error if there are more than this many placement
possibilities. It is possible to use
that result in an intractable number of placements.
if the number of placements exceeds
A list of placement dictionaries. Each dictionary maps the nodes in
big_graph with a monomorphic relationship. That's to say: if an edge exists
small_graph between two nodes, it will exist in
big_graph between the mapped nodes.