tsim.compile.stabrank.find_stab
← Module overview
function
source
functionfind_stab¶source
tsim.compile.stabrank.find_stab
Signature
def find_stab(graph: BaseGraph, strategy: DecompositionStrategy) -> list[BaseGraph]Decompose a ZX-graph into a sum of stabilizer components.
This is the main entry point for stabilizer rank decomposition. It first removes U3 phases, then decomposes T gates via BSS decompositions, producing a sum of scalar graphs.
Parameters
| Name | Type | Description |
|---|---|---|
graph | BaseGraph | The ZX graph to decompose. |
strategy | DecompositionStrategy | Decomposition strategy. Must be one of "cat5", "bss", "cutting". |
Returns
list[BaseGraph]A list of scalar graphs whose sum equals the original graph.