Draw a visualization of placements from small_graph onto big_graph using Matplotlib.
cirq.draw_placements(
big_graph: nx.Graph,
small_graph: nx.Graph,
small_to_big_mappings: Sequence[Dict],
max_plots: int = 20,
axes: Sequence[plt.Axes] = None,
tilted=True
)
Used in the notebooks
The entire big_graph
will be drawn with default blue colored nodes. small_graph
nodes
and edges will be highlighted with a red color.
Args |
big_graph
|
A larger graph to draw with blue colored nodes.
|
small_graph
|
A smaller, sub-graph to highlight with red nodes and edges.
|
small_to_big_mappings
|
A sequence of mappings from small_graph nodes to big_graph
nodes.
|
max_plots
|
To prevent an explosion of open Matplotlib figures, we only show the first
max_plots plots.
|
axes
|
Optional list of matplotlib Axes to contain the drawings.
|
tilted
|
Whether to draw gridlike graphs in the ordinary cartesian or tilted plane.
|