Skip to content

Conversation

@comp-phys-marc
Copy link
Contributor

Context: We would like to support Joseph Bowles' paper "train on classical, deploy ono quantum" on Instantaneous Quantum Polynomial (IQP) circuits by adding supporting functionality to PennyLane.

Description of the Change: Adds a template that builds an IQP circuit and a ResourceOperator that allows us to estimate the resources required to run an IQP circuit in theory.

Benefits: We are set up to do the second part of the workflow proposed by Joseph: deploy on quantum (once the QC capacity becomes available). We can also estimate exactly what the costs associated would be in terms of gate counts, wires, etc.

Possible Drawbacks: Does not implement the analytical expectation value, maximum mean discrepancy calculations presented in the paper. These will be included in a follow-up PR.

Related ShortCut Stories: [sc-105538] [sc-105539]

@PennyLaneAI PennyLaneAI deleted a comment from github-actions bot Dec 9, 2025
@comp-phys-marc comp-phys-marc marked this pull request as ready for review December 9, 2025 20:07
@codecov
Copy link

codecov bot commented Dec 9, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 99.37%. Comparing base (48090d2) to head (2a2507e).
⚠️ Report is 1 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #8748   +/-   ##
=======================================
  Coverage   99.37%   99.37%           
=======================================
  Files         589      590    +1     
  Lines       63237    63297   +60     
=======================================
+ Hits        62842    62902   +60     
  Misses        395      395           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@comp-phys-marc comp-phys-marc changed the title IQP Circuit and Resource Function IQP Circuit and Resource Operator Dec 10, 2025
comp-phys-marc and others added 5 commits December 16, 2025 09:04
Co-authored-by: Gabriela Sánchez Díaz <[email protected]>
Co-authored-by: Gabriela Sánchez Díaz <[email protected]>
Co-authored-by: Gabriela Sánchez Díaz <[email protected]>
@gabrielasd
Copy link
Contributor

Thanks a lot @comp-phys-marc for implementing these changes!! 🚀
I am ready to approve them after one final request.
Please can you add the IQP template to the templates.rst file? I think it can go under the Other subroutines section there

@comp-phys-marc
Copy link
Contributor Author

Thanks a lot @comp-phys-marc for implementing these changes!! 🚀 I am ready to approve them after one final request. Please can you add the IQP template to the templates.rst file? I think it can go under the Other subroutines section there

Done in 27fb14c

Copy link
Contributor

@gabrielasd gabrielasd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Thank you!
Please could you wait until PR #8766 is merged to merge these changes? Its to minimize merge conflicts

@gabrielasd
Copy link
Contributor

Oh, I missed this,
@comp-phys-marc there seems to be something strange with the rendering of specs's output in the example for the resource template:
image

could you check this?

@comp-phys-marc
Copy link
Contributor Author

Oh, I missed this, @comp-phys-marc there seems to be something strange with the rendering of specs's output in the example for the resource template: image

could you check this?

Thanks for catching. Fixed it.

@comp-phys-marc comp-phys-marc added this pull request to the merge queue Dec 16, 2025
Merged via the queue into master with commit 3b2393e Dec 16, 2025
55 checks passed
@comp-phys-marc comp-phys-marc deleted the feature/IQPCircuit branch December 16, 2025 22:53
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 this pull request may close these issues.

4 participants