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
Variational Quantum Regression using the Parameter Shift Rule #654
Conversation
Codecov ReportBase: 100.00% // Head: 100.00% // No change to project coverage 👍
Additional details and impacted files@@ Coverage Diff @@
## master #654 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 80 80
Lines 10455 10455
=========================================
Hits 10455 10455
Flags with carried forward coverage won't be shown. Click here to find out more. Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
for more information, see https://pre-commit.ci
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@MatteoRobbiati thank you very much for this contribution. It is in a really good shape.
I am just wondering if we should place the VQRegressor in a QML / variational module for Qibo and provide the optimizer as a standalone optimizer. @stavros11 what is your opinion about that?
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
@MatteoRobbiati could you please complete this PR by:
|
@scarrazza Modifications done, thank you for the comment. |
@@ -0,0 +1 @@ | |||
../../../../../examples/vqregressor/README.md |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This file has a typo.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, but please test sphinx manually every time you perform a change, otherwise you don't really now if things are working well. In fact, at the current state, the tutorial is not appearing in the website due to the typo.
@scarrazza thanks for the advice. I've fixed it and modified the README so that the formulas can be read in documentation. |
In this example a Variational Quantum Circuit based on the re-uploading strategy is used to tackle a simple 1-dimensional regression problem: (to fit$y= \sin 2x$ ).
This context is exploited for introducing the Parameter Shift Rule, which is useful for evaluating the gradients of a circuit in a quantum-hardware compatible way.
A demo markdown is included.