qbraid.programs.CirqCircuit
- class CirqCircuit(program)[source]
Wrapper class for
cirq.Circuit
objects.- __init__(program)
Methods
__init__
(program)convert_to_contiguous
([expansion])Remove empty registers of circuit.
draw
([package, output])Draw circuit
is_measurement_gate
(op)Returns whether Cirq gate/operation is MeasurementGate.
reverse_qubit_order
()Rerverse qubit ordering of circuit.
transpile
(conversion_type)Transpile a qbraid quantum program wrapper object to quantum program object of type specified by
conversion_type
.unitary
()Calculate unitary of circuit.
unitary_little_endian
()Converts unitary calculated using big-endian system to its equivalent form in a little-endian system.
unitary_rev_qubits
()Peforms Kronecker (tensor) product factor permutation of given matrix.
Attributes
depth
Return the circuit depth (i.e., length of critical path).
num_clbits
Return the number of classical bits in the circuit.
num_qubits
Return the number of qubits in the circuit.
package
Return the original package of the wrapped circuit.
program
Return the wrapped quantum program object.
qubits
Return the qubits acted upon by the operations in this circuit