2
$\begingroup$

I performed an experiment on a real Ibmq backend, and the results were satisfactory. I now require the simulation of that experiment. The simulation is not sufficiently consistent with the old experiment due to the new noise model, so I need to find the noise model of the backend at that specific date to perform the simulation!

$\endgroup$

1 Answer 1

2
$\begingroup$

If the device you were simulating is still on line, you can get properties (which is where the noise model lives) from part calibrations.

For getting calibration from, say, first day of 2022:

from qiskit_ibm_provider import IBMProvider
provider = IBMProvider()

backend = provider.get_backend('ibmq_lima')

from datetime import datetime
dt = datetime.fromisoformat('2022-01-01')
prop_2022 = backend.properties(datetime=dt)
prop_2022.last_update_date
datetime.datetime(2021, 12, 31, 8, 48, 43, tzinfo=tzlocal())

In this case, the calibration at the first day of 2022 was done the last day of 2021.

To create an Aer noise model with these properties:

from qiskit_aer.noise import NoiseModel

backend_noise_model_2022 = NoiseModel.from_backend_properties(prop_2022)
$\endgroup$
6
  • $\begingroup$ Thank you very much for quick response! So you mean I do this in my code and then I use the command backend_noise_model = NoiseModel.from_backend(noisy_backend), In this way I will gain the noise model of the specific date I want right? $\endgroup$
    – Shil S
    Commented Apr 18, 2023 at 9:26
  • $\begingroup$ I extended the answer with the creation of the noise model. Feel free to accept it if that would make it. Let me know otherwise. $\endgroup$
    – luciano
    Commented Apr 18, 2023 at 9:41
  • $\begingroup$ I got the error below! type object 'NoiseModel' has no attribute 'from_backend_properties' $\endgroup$
    – Shil S
    Commented Apr 18, 2023 at 10:13
  • $\begingroup$ What about if I use backend_noise_model_2022 =NoiseModel.from_backend(prop_2022)? $\endgroup$
    – Shil S
    Commented Apr 18, 2023 at 10:20
  • $\begingroup$ Thank you, It looks its working, looks similar to my experiment result now! $\endgroup$
    – Shil S
    Commented Apr 18, 2023 at 10:50

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.