-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Use singletons for standard library unparameterized, non-controlled gates #10314
Merged
Merged
Changes from all commits
Commits
Show all changes
37 commits
Select commit
Hold shift + click to select a range
7087462
Use singletons for standard library unparameterized, non-controlled g…
mtreinish 330beb8
Fix Python 3.8 compatibility
mtreinish c653304
Simplify qpy deserialization label handling
mtreinish 7d54237
Remove unused classmethod decorator
mtreinish 1743262
Fix lint
mtreinish ce6cf24
Merge remote-tracking branch 'origin/main' into singleton-gates-poc
mtreinish aadd8cb
Fix timeline drawer on output of legacy DD pass
mtreinish ffa051c
Fix doc build
mtreinish 09dbcd7
Add methods to deal with mutability of singleton gates
mtreinish d1435cd
Merge branch 'main' into singleton-gates-poc
mtreinish 7d91466
Merge remote-tracking branch 'origin/main' into singleton-gates-poc
mtreinish c29887a
Disallow custom attribute on singleton instances
mtreinish 4d17c9f
Merge branch 'main' into singleton-gates-poc
mtreinish a788da4
Fix rebase error
mtreinish a03cce5
Merge branch 'main' into singleton-gates-poc
mtreinish 9b49dc3
Fix rebase issues
mtreinish 43f41d3
Merge remote-tracking branch 'origin/main' into singleton-gates-poc
mtreinish 4e9911a
Merge branch 'main' into singleton-gates-poc
mtreinish 95ecb6d
Merge remote-tracking branch 'origin/main' into singleton-gates-poc
mtreinish 96cf467
Fix module docstring
mtreinish e1a0ef4
Add .mutable and .to_mutable() to Instruction
mtreinish 3784da4
Unify handling of gates in scheduling passes
mtreinish b90eebb
Remove unnecessary deepcopy in substitute_node_wtih_dag
mtreinish 4b242e1
Fix logic for SingletonGate.copy
mtreinish d9ff18a
Update Singleton Gate class docstring
mtreinish 86ea2a0
Remove unused imports
mtreinish 32d5395
Update release notes
mtreinish 306fcc8
Merge branch 'main' into singleton-gates-poc
mtreinish 75eb6e6
Fix release note typos
mtreinish efc7a12
Merge branch 'main' into singleton-gates-poc
mtreinish b95ac96
Improve setattr performance
mtreinish 8deb2cb
Fix deepcopy logic
mtreinish 2479b12
Add check for kwargs up front
mtreinish 9c9bc09
Fix docs typos
mtreinish 37a30cb
Add comment on to_mutable __init__ call
mtreinish ba04a8e
Fix lint
mtreinish 7f99a09
Handle positional initialization arguments in SingletonGate
mtreinish File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here (and everywhere), is there a reason not to use
"dt"
directly as the default value in the signature?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The reason is there wasn't a way to differentiate between a user specified value and the default when
__new__
is called. I guess we can change the__new__
check ifkwargs["unit"] == "dt"
and then do that. I'll give that a try locally and push it up if it works.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If there's a reason, it's already fine by me.