Closed BrunoLiegiBastonLiegi closed 1 year ago
Thanks. Yes, this is exactly what I suggested.
I changed one_prediction
to use frequencies $f$ instead of probabilities $p$. This way, the number of shots is taken into account and it is easier to compare with real data because $f$ = $p$ only when $\text{nshots} \rightarrow \infty$.
I added a depolarizing channel with $\lambda=0.25$ so that we can get results for all possibilities before running on hardware. I have used a training set with 10 circuits for CDR and it seems to work. In the following results, $\text{nshots}=1000$
Noisless (small differences due to shot noise):
Noisy without mitigation:
Noisy with mitigation while evaluating gradients:
Noisy with mitigation while calculating predictions:
Noisy with mitigation while evaluating gradients and while calculating predictions:
We have to play with the other mitigation methods and of course run it in hardware but it seems that using real-time error mitigation improves the results!
Excellent, good work @AlejandroSopena @MatteoRobbiati @BrunoLiegiBastonLiegi!
Awesome, thanks @AlejandroSopena !
Implementation of the prediction method mitigated with the CDR method. I added to the vqregressor initialization the
backend
andnoise_model
parameters that are needed for the CDR to run under simulated noise, but they can be useful in general to run the fit under simulated noise. Therefore, it might be worth analogously changing the one_prediction method to: