I have a version of the following circuit set up.
from qiskit import QuantumCircuit
circuit=QuantumCircuit(2)
initial_state0=[1/np.sqrt(2),1/np.sqrt(2)]
circuit.initialize(initial_state0, 0)
initial_state1=[1, 0]
circuit.initialize(initial_state1,1)
circuit.cx(0,1)
I have seen that I can use StateTomography by coding the following
from qiskit_experiments.library import StateTomography
from qiskit.providers.aer import Aer
backend = Aer.get_backend('qasm_simulator')
# QST Experiment
qstexp1 = StateTomography(circuit)
qstdata1 = qstexp1.run(backend, seed_simulation=1000).block_for_results()
# Print results
for result in qstdata1.analysis_results():
print(result)
By using the coding above I am able to see how this tomography can be used to approximate the state of the entire system with fidelity being a comparison to the state of the circuit, but my goal is to use Quantum State Tomography (QST) on only $q_1$ and use the fidelity to compare this to $q_0$.
I have seen in the tutorial on Qiskit that I can run the tomography on parallel subsystems, but I'm not sure how to extend this to my goal described above. Any help would be greatly appreciated!
(Previous edit removed as I resolved that issue independently)