File tree Expand file tree Collapse file tree 2 files changed +2
-3
lines changed
src/qrisp/interface/converter Expand file tree Collapse file tree 2 files changed +2
-3
lines changed Original file line number Diff line number Diff line change 11from cirq import Circuit , LineQubit
22from qrisp .circuit import ControlledOperation
3+ import numpy as np
34
45from cirq import (
56 CNOT ,
@@ -144,7 +145,7 @@ def convert_to_cirq(qrisp_circuit):
144145 # the ZPowGate has a global phase in addition to the
145146 # phase exponent. The default is to assume global_shift = 0 in cirq
146147 exp_param = params [0 ]
147- cirq_circuit .append (ZPowGate (exponent = exp_param )(* cirq_op_qubits ))
148+ cirq_circuit .append (ZPowGate (exponent = exp_param / np . pi )(* cirq_op_qubits ))
148149
149150 # elif op_i == 'gphase':
150151 # global phase gate in Cirq cannot be applied to specific qubits
Original file line number Diff line number Diff line change @@ -28,8 +28,6 @@ def test_n_qubit_gate_circuit():
2828 qc_single_qubit_gates .t (1 )
2929 qc_single_qubit_gates .t_dg (3 )
3030 qc_single_qubit_gates .s_dg (2 )
31- qc_single_qubit_gates .measure (0 )
32- qc_single_qubit_gates .reset (0 )
3331
3432 expected_cirq_qc_single_qubit_gates_ops = [
3533 H (LineQubit (0 )),
You can’t perform that action at this time.
0 commit comments