Skip to content

Add IQP expval#8749

Merged
comp-phys-marc merged 118 commits into
masterfrom
feature/IQP_expval
Jan 2, 2026
Merged

Add IQP expval#8749
comp-phys-marc merged 118 commits into
masterfrom
feature/IQP_expval

Conversation

@comp-phys-marc

@comp-phys-marc comp-phys-marc commented Dec 9, 2025

Copy link
Copy Markdown
Contributor

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

Description of the Change: Adds functionality for the calculation of the expectation value to the math module.

Benefits: Allows us to calculate the expectation values of Z measurements following IQP circuits without the need to perform state vector simulations of the IQP circuits. This is useful for training IQP circuits classically.

Possible Drawbacks: Does not yet implement corresponding loss function(s).

Related ShortCut Stories: [sc-105540]

@comp-phys-marc comp-phys-marc changed the title Add IQP expval [WIP] Add IQP expval Dec 9, 2025
@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 10, 2025 15:31
Comment thread pennylane/qnn/iqp.py Outdated
comp-phys-marc and others added 6 commits December 31, 2025 16:10

@josephbowles josephbowles left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Mostly just some improvements to the docstrings.

Comment thread pennylane/qnn/iqp.py Outdated
Comment thread pennylane/qnn/iqp.py Outdated
Comment thread pennylane/qnn/iqp.py Outdated
Comment thread pennylane/qnn/iqp.py Outdated
Comment thread pennylane/qnn/iqp.py Outdated
Comment thread pennylane/qnn/iqp.py Outdated
comp-phys-marc and others added 5 commits January 2, 2026 09:19
Co-authored-by: josephbowles <54283511+josephbowles@users.noreply.github.com>
Co-authored-by: josephbowles <54283511+josephbowles@users.noreply.github.com>
Co-authored-by: josephbowles <54283511+josephbowles@users.noreply.github.com>
Co-authored-by: josephbowles <54283511+josephbowles@users.noreply.github.com>
Co-authored-by: josephbowles <54283511+josephbowles@users.noreply.github.com>

@JerryChen97 JerryChen97 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM!

@gabrielasd gabrielasd left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thank you @comp-phys-marc!
I only made two minor update suggestions for the docstring example but this looks good to me :)

Comment thread pennylane/qnn/iqp.py Outdated
Comment thread pennylane/qnn/iqp.py Outdated
comp-phys-marc and others added 4 commits January 2, 2026 10:34
Co-authored-by: Gabriela Sánchez Díaz <gsdiaz21@gmail.com>
Co-authored-by: Gabriela Sánchez Díaz <gsdiaz21@gmail.com>
@comp-phys-marc comp-phys-marc added this pull request to the merge queue Jan 2, 2026
Merged via the queue into master with commit 8983496 Jan 2, 2026
55 checks passed
@comp-phys-marc comp-phys-marc deleted the feature/IQP_expval branch January 2, 2026 16:29
Jaybsoni pushed a commit that referenced this pull request Jan 2, 2026
**Context:** We would like to support Joseph Bowles'
[paper](https://arxiv.org/pdf/2503.02934) "train on classical, deploy on
quantum" on Instantaneous Quantum Polynomial (IQP) circuits by adding
supporting functionality to PennyLane.

**Description of the Change:** Adds functionality for the calculation of
the expectation value to the `math` module.

**Benefits:** Allows us to calculate the expectation values of Z
measurements following IQP circuits without the need to perform state
vector simulations of the IQP circuits. This is useful for training IQP
circuits classically.

**Possible Drawbacks:** Does not yet implement corresponding loss
function(s).

**Related ShortCut Stories:** [sc-105540]

---------

Co-authored-by: josephbowles <54283511+josephbowles@users.noreply.github.com>
Co-authored-by: Joseph Bowles <bowles.physics@gmail.com>
Co-authored-by: Yushao Chen (Jerry) <chenys13@outlook.com>
Co-authored-by: Gabriela Sánchez Díaz <gsdiaz21@gmail.com>
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