Skip to content

Commit

Permalink
Merge branch 'main' into cpu-only
Browse files Browse the repository at this point in the history
  • Loading branch information
WrathfulSpatula committed Dec 6, 2024
2 parents 62d4d29 + 65bd996 commit 980d7e0
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pyqrack/qrack_circuit.py
Original file line number Diff line number Diff line change
Expand Up @@ -369,13 +369,13 @@ def string_to_qiskit_circuit(circ_string):

payloads[key] = op

identity = np.eye(2, dtype=complex)
gate_list=[]
control_pow = 1 << control_count
for j in range(control_pow):
for j in range(1 << control_count):
if j in payloads:
gate_list.append(payloads[j])
else:
gate_list.append(np.array([[1, 0],[0, 1]]))
gate_list.append(identity)
circ.append(UCGate(gate_list), controls + [target])

return circ
Expand Down

0 comments on commit 980d7e0

Please sign in to comment.