Expand description
Stim circuit format parser
This module provides parsing capabilities for Stim circuit files (.stim). Stim is a fast Clifford circuit simulator with a simple text-based circuit format.
§Supported Instructions
§Single-Qubit Clifford Gates
H q: Hadamard gateS q: S gate (√Z)S_DAG q: S† gateSQRT_X q: √X gateSQRT_X_DAG q: √X† gateSQRT_Y q: √Y gateSQRT_Y_DAG q: √Y† gateX q,Y q,Z q: Pauli gates
§Two-Qubit Clifford Gates
CNOT q1 q2: Controlled-NOTCZ q1 q2: Controlled-ZCY q1 q2: Controlled-YSWAP q1 q2: SWAP gate
§Measurements
M q1 q2 ...: Z-basis measurementMX q1 q2 ...: X-basis measurementMY q1 q2 ...: Y-basis measurement
§Reset
R q1 q2 ...: Reset to |0⟩
§Example
# Bell state preparation
H 0
CNOT 0 1
M 0 1Structs§
- Circuit
Statistics - Circuit statistics
- Pauli
Target - Pauli target for correlated errors
- Stim
Circuit - Stim circuit representation
Enums§
- Measurement
Basis - Measurement basis
- Pauli
Type - Pauli operator type
- Single
Qubit Gate Type - Single-qubit Clifford gate types
- Stim
Instruction - Stim instruction type
- TwoQubit
Gate Type - Two-qubit Clifford gate types