Allow repeated measurements in deferred transformer#5857
Merged
tanujkhattar merged 48 commits intoquantumlib:masterfrom Dec 19, 2022
Merged
Allow repeated measurements in deferred transformer#5857tanujkhattar merged 48 commits intoquantumlib:masterfrom
tanujkhattar merged 48 commits intoquantumlib:masterfrom
Conversation
4 tasks
Collaborator
|
@daxfohl Please resolve the conflicts and I'll be happy to review this PR as well. |
Collaborator
Author
|
Converting to draft to clean up some merge artifacts |
Collaborator
Author
|
@tanujkhattar ready |
Collaborator
Author
|
@tanujkhattar ready |
tanujkhattar
approved these changes
Dec 19, 2022
Contributor
|
Automerge cancelled: Pull Request is not mergeable. |
harry-phasecraft
pushed a commit
to PhaseCraft/Cirq
that referenced
this pull request
Oct 31, 2024
* Add handling for sympy conditions in deferred measurement transformer * docstring * mypy * mypy * cover * Make this more generic, covers all kinds of conditions. * Better docs * Sympy can also be CX * docs * docs * Allow repeated measurements in deferred transformer * Coverage * Add mixed tests, simplify loop, add simplification in ControlledGate * Fix error message * Simplify error message * Inline variable * fix merge * qudit sympy test * fix build * Fix test * Fix test * nits * mypy * mypy * mypy * Add some code comments * Add test for repeated measurement diagram * change test back Co-authored-by: Tanuj Khattar <tanujkhattar@google.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes the deferred measurements transformer in the presence of repeated measurements on the same measurement key by maintaining all those measurements as a list and controlling against the correct qubits per the control index.
This change will update diagrams of the output circuits slightly. The ancilla qubits now have indexes to represent the order of the measurement for that key.
Closes #5884