Closed ashsaki closed 5 years ago
A way around could be using a single qubit register for ideal unitary preparation and a larger register for the generate quantum process tomography circuit with reduced Hilbert space for a gate on a qubit other than 0. My code snippet: #####################################################
q = QuantumRegister(1) circ = QuantumCircuit(q) circ.h(q[0])
job = qiskit.execute(circ, Aer.get_backend('unitary_simulator')) ideal_unitary = job.result().get_unitary(circ)
choi_ideal = outer(ideal_unitary.ravel(order='F')) print("Ideal Unitary Done")
q2 = QuantumRegister(5) circ2 = QuantumCircuit(q2) circ2.h(q2[4])
qpt_circs = process_tomography_circuits(circ2, [q2[4]]) #####################################################
Can you please post this issue on the Ignis repo: https://github.com/Qiskit/qiskit-ignis
(The issue still persists if anyone wants to use a larger number of qubit instead of just 1) If I re-create the quantum process tomography tutorial in https://github.com/Qiskit/qiskit-tutorials/blob/master/qiskit/ignis/process_tomography.ipynb with a QuantumRegister() of size greater than 2 (e.g., QuantumRegister(3) or QuantumRegister(5)), the memory runs out (i.e., the program consumes too much RAM and RAM usage keeps increasing with time) quickly and the process (python) gets killed.
With QuantumRegister(1) or QuantumRegister(2) the program runs okay.
FYI, I want to run a process tomography of Hadamard gate on q[4].