4
$\begingroup$

I am having trouble retrieving data using Qiskit from jobs I ran on a currently retired system. However, I can still retrieve the same data from the dashboard (GUI), so I think the data are still there. For instance, the following code works just fine for retrieving counts data from an old job I ran on Melbourne (currently in service):

BACKEND='ibmq_16_melbourne'
JOB_ID='6009735f4ae4e567f432feca'
my_backend = provider.get_backend(BACKEND)
my_job = my_backend.retrieve_job(JOB_ID)
COUNTS = my_job.result().get_counts()

However, the same code but trying to retrieve data from a job that ran on Vigo fails:

BACKEND='ibmq_vigo'
JOB_ID='60037fbf2159c338e734e663'
my_backend = provider.get_backend(BACKEND)
my_job = my_backend.retrieve_job(JOB_ID)
COUNTS = my_job.result().get_counts()

The error message I get is

QiskitBackendNotFoundError: 'No backend matches the criteria'

Is there an alternative way to do this?

Thank you!

Jorge

$\endgroup$

1 Answer 1

3
$\begingroup$

You can use provider.backend.retrieve_job(JOB_ID) to retrieve jobs from retired backends.

$\endgroup$
1
  • $\begingroup$ Thank you, that answers my question. In particular, my_job=provider.backend.retrieve_job('60037fbf2159c338e734e663') followed by COUNTS = my_job.result().get_counts() does what I wanted - and it works for non-retired backends as well. Thanks! $\endgroup$ Jun 25, 2021 at 9:47

Your Answer

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

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