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

Fix QPE cirq simulation tests #1494

Merged
merged 4 commits into from
Nov 12, 2024

Conversation

anurudhp
Copy link
Contributor

@anurudhp anurudhp commented Nov 10, 2024

Cirq simulator was unable to simulate Controlled(QubitizationWalkOperator), so decompose one level further to get simulable gates.

Also made a subset fast tests to catch issues early on. Fixes the current Nightly test failure.

@anurudhp
Copy link
Contributor Author

@fdmalone ptal

@mpharrigan
Copy link
Collaborator

is there a more fundamental issue at play here? this seems like a hacky fix on top of the existing tests

qpe_reg, selection, target = (gh.quregs['qpe_reg'], gh.quregs['selection'], gh.quregs['target'])
qpe_bloq = QubitizationQPE(walk, state_prep)

def should_decompose(binst):
Copy link
Collaborator

Choose a reason for hiding this comment

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

can you open an issue and link it here. I assume this isn't ideally how things would work?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yeah, I spent some time but couldn't figure out the root cause. Opened #1495 and linked here.

@mpharrigan mpharrigan merged commit 07c98b6 into quantumlib:main Nov 12, 2024
8 checks passed
@anurudhp anurudhp deleted the 2024/11/10-fix-qpe-sim-tests branch November 12, 2024 19:58
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.

2 participants