Adds AbstractInitialMapper base class and IdentityInitialMapper#5829
Merged
tanujkhattar merged 29 commits intoquantumlib:masterfrom Aug 19, 2022
Merged
Conversation
mpharrigan
reviewed
Aug 16, 2022
tanujkhattar
requested changes
Aug 16, 2022
Collaborator
tanujkhattar
left a comment
There was a problem hiding this comment.
One question regarding the interface of initial mapper. Should we instead expose a method that expects a circuit or a (circuti, device_graph) and returns an initial mapping for that circuit / circuit, device graph combination?
I'm thinking that the class should encapsulate the strategy to map a circuit on a device; and not necessarily hardcode exact circuit / device combination as part of it's construction.
tanujkhattar
requested changes
Aug 17, 2022
Collaborator
tanujkhattar
left a comment
There was a problem hiding this comment.
Can we rebase it to master so that unrelated changes in mapping manager don't appear here? We can merge once it's rebased.
9ba9cef to
c899e16
Compare
mpharrigan
reviewed
Aug 18, 2022
tanujkhattar
approved these changes
Aug 19, 2022
rht
pushed a commit
to rht/Cirq
that referenced
this pull request
May 1, 2023
…tumlib#5829) * added abstract initial mapper and identity initial mapper * added __str__ and __repr__ for MappingManager * minor bug * made MappingManager not serializable * removed unused import * addressed comments * fixed bug with edges not being sorted for graph equality testing * fixed bug with digraphs repr method in MappingManager and added test for it * rebase * minor lint fix * addressed comments * addressed some comments * changed interface for AbstractInitialMapper * made MappingManager serializable * removed print statements * ready for merging * nit * temp * fix lint * removed serialization * removed unused imports * addressed comments and made HardCodedInitialMapper not serializable * fixed nit * fixed raises docstring * forgot to add import statement * import bug * removed debug print
harry-phasecraft
pushed a commit
to PhaseCraft/Cirq
that referenced
this pull request
Oct 31, 2024
…tumlib#5829) * added abstract initial mapper and identity initial mapper * added __str__ and __repr__ for MappingManager * minor bug * made MappingManager not serializable * removed unused import * addressed comments * fixed bug with edges not being sorted for graph equality testing * fixed bug with digraphs repr method in MappingManager and added test for it * rebase * minor lint fix * addressed comments * addressed some comments * changed interface for AbstractInitialMapper * made MappingManager serializable * removed print statements * ready for merging * nit * temp * fix lint * removed serialization * removed unused imports * addressed comments and made HardCodedInitialMapper not serializable * fixed nit * fixed raises docstring * forgot to add import statement * import bug * removed debug print
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.
This PR starts the implementation of the placement strategy for qubit routing http://tinyurl.com/cirq-qubit-routing. A base class
AbstractInitialMapperand a trivial implementationIdentityInitialMapperare added.