block_synthesis#
- tqec.interop.block_synthesis(zx_graph, strategy=SynthesisStrategy.POSITIONED, *, positions=None, **_kwargs)[source]#
Perform block synthesis translating an instance of
pyzx.GraphS
to aBlockGraph
.- Parameters:
zx_graph (GraphS) – a ZX graph to transform into a
BlockGraph
.strategy (SynthesisStrategy) – strategy used to perform the translation.
positions (Mapping[int, Position3D] | None) – explicit block positioning for each node in the provided
zx_graph
. Only used whenstrategy == SynthesisStrategy.POSITIONED
._kwargs (dict[str, Any])
- Raises:
ValueError – if
strategy == SynthesisStrategy.POSITIONED
andpositions
is not provided.- Returns:
an instance of
BlockGraph
representing the providedzx_graph
.- Return type:
BlockGraph