0
$\begingroup$

I have done a quantum process tomography experiment on a two qubit system.

# Set up the QPT experiment
qpt = ProcessTomography(qc_h)

#Run
qstdata1 = qpt.run(backend, shots=(1024*2)).block_for_results()

#Result
for result in qstdata1.analysis_results():
    print(result)

The output contains a Choi matrix:

AnalysisResult
- name: state
- value: Choi([[ 0.52176658+0.00000000e+00j,  0.46669301-3.60389531e-03j,
        0.45464147-2.22373925e-02j, -0.45936069+1.54147696e-02j],
      [ 0.46669301+3.60389531e-03j,  0.47843409+1.30104261e-18j,
        0.47397839+1.01701620e-02j, -0.45466925+2.23604672e-02j],
      [ 0.45464147+2.22373925e-02j,  0.47397839-1.01701620e-02j,
        0.49722515+0.00000000e+00j, -0.47223203+1.56516697e-02j],
      [-0.45936069-1.54147696e-02j, -0.45466925-2.23604672e-02j,
       -0.47223203-1.56516697e-02j,  0.50257418+0.00000000e+00j]],
     input_dims=(2,), output_dims=(2,))

However, I would like it to be a Chi ($\chi$) matrix so I can plot it.

How do I go about turning that data above, from a Choi matrix, to a Chi matrix?

Cheers

$\endgroup$
1

1 Answer 1

1
$\begingroup$

The constructor of Chi class accepts an instance of Choi. So, if _choi is your Choi matrix, you can get Chi matrix by simply calling Chi(_choi)

from qiskit.quantum_info import Chi

_chi = Chi(_choi)
$\endgroup$
1
  • $\begingroup$ I did it a slightly different way using choi2chi(choi_matrix) from forest.benchmarking but that method also worked for me too to verify I'd done things correctly. Cheers :) $\endgroup$ Commented Jun 27 at 15:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.