Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Integrate ZNE from Mitiq into OpenQAOA #207

Open
2 tasks
MaldoAlberto opened this issue Mar 15, 2023 · 4 comments · Fixed by #302
Open
2 tasks

Integrate ZNE from Mitiq into OpenQAOA #207

MaldoAlberto opened this issue Mar 15, 2023 · 4 comments · Fixed by #302

Comments

@MaldoAlberto
Copy link
Contributor

MaldoAlberto commented Mar 15, 2023

Prerequisites

Before raising this feature request, I have made sure:

  • It does not lead to duplication.
  • It has not already been requested.

Is your feature request related to a problem? Please describe.

Proposal a method into the object QAOA to indicate the parameters necessaries for Mitiq and try to mitigate the error for the problem.

Describe the solution you'd like

Add mitiq on OpenQAOA using ZNE mitigation error and implement in the QAOA class.

Describe alternatives you've considered

A clear and concise description of any alternative solutions or features you've considered.

Additional context

Add any other context or screenshots about the feature request here.

@MaldoAlberto MaldoAlberto changed the title Integrate Mitiq into OpenQAOA Integrate ZNE from Mitiq into OpenQAOA Mar 15, 2023
@victor-onofre
Copy link
Contributor

Hi @Q-lds and all OpenQAOA team! As part of the Quantum Open Source Foundation Mentorship program, we want to add this feature to OpenQAOA.

The project mentors are going to be @MaldoAlberto and me. The team is going to be @AdrianoLusso, @mar-ven and @Abhinaba925. We already have done a small example of integrating ZNE with Mitiq in a handmade QAOA (the code is here). We need to figure out the workflow to modify compile() in OpenQAOA. We expect to have a plan by the end of the week.

Also, Alberto has talked to the maintainers of Mitiq, and they said there is no issue with integrating the features of Mitiq with OpenQAOA.

Hope to finish this new feature soon!

Thanks!

@Q-lds
Copy link
Member

Q-lds commented Dec 7, 2023

Amazing! Let me tag the rest of the team too: @KilianPoirier @vishal-ph @shahidee44

I'm very excited about the prospect of bringing error mitigation to OpenQAOA :)

Let us know if we can be of help!

@victor-onofre
Copy link
Contributor

Hi @KilianPoirier, @vishal-ph and @shahidee44. The team has been working on the planning, and we have a couple of questions. Here are the important points:

  • We have decided to focus only on Qiskit.
  • For the integration of ZNE, we plan to add another wrapper in the same section as the SPAMTwirlingWrapper. Do you agree with this idea?
  • We plan to fork the main branch and start working from there. Is this okay? Or do we need to work with another branch?
  • @AdrianoLusso has made a diagram of our understanding of the code and where ZNE will be integrated. I attached it below.

Adriano_OpenQAOA

Thanks for the help!

@victor-onofre
Copy link
Contributor

Hi @KilianPoirier, @vishal-ph and @shahidee44. Here is an update on the project:

  1. We managed to create a wrapper for ZNE. You can check the current version here. At the moment the code is messy but we will improve it during the rest of the tests.

  2. We have some preliminary results with a random instance of the Max-Cut problem using noise models. These results are unoptimized, but they show the wrapper is working. Here, you can check the parameters of the simulation. Here is a cost history plot of the results:
    3 2qaoa_qaoanoise_qaoazne_maxcut_cost

  3. We are currently working on benchmarking with the Max cut and Knapsack problem (Obtaining optimal solution in a noiseless simulation and then applying the noise model to find the optimal parameters of the ZNE method )

KilianPoirier added a commit that referenced this issue May 28, 2024
- Integrate Mitiq into OpenQAOA to allow error mitigation techniques to take place during the execution of the QAOA. We have created a wrapper focusing on the ZNE technique following a similar structure to the SPAM Twirling wrapper.
- This is a project born from the Quantum Open Source Foundation Mentorship program
- New dependency to add: Mitiq
- Fixes Integrate ZNE from Mitiq into OpenQAOA #207
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants