qasm3#
Converter between QubitCircuit and QASM3
Classes
|
Gate definition in OpenQASM 3.0 |
Functions
|
Converts |
|
Converts a full-featured OpenQASM 3.0 string to |
- class GateDefinition(name: str, params: list[str], qubits: list[str], body: list[str])[source]#
Bases:
objectGate definition in OpenQASM 3.0
- cir_to_qasm3(circuit: QubitCircuit) str[source]#
Converts
QubitCircuitto an OpenQASM 3.0 string.- Parameters:
circuit (QubitCircuit) – The DeepQuantum circuit to convert.
- Returns:
A string containing the OpenQASM 3.0 representation of the circuit.
- Return type:
str
- qasm3_to_cir(qasm_string: str) QubitCircuit[source]#
Converts a full-featured OpenQASM 3.0 string to
QubitCircuit.Supports: def, inv @, ctrl @, and floating-point/negative pow() @.