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

Return NotImplemented from Moment._kraus_() if self._has_kraus_() is False #4794

Merged
merged 2 commits into from
Jan 5, 2022

Conversation

tanujkhattar
Copy link
Collaborator

@tanujkhattar tanujkhattar commented Jan 4, 2022

Also implements the same pattern for Moment._superoperator_().

This pattern is followed for other protocols like (eg: _unitary_ and _has_unitary_) and is useful to keep the protocols.kraus code consistent.

@tanujkhattar tanujkhattar requested a review from viathor January 4, 2022 07:35
@tanujkhattar tanujkhattar requested review from cduck, vtomole and a team as code owners January 4, 2022 07:35
@CirqBot CirqBot added the size: S 10< lines changed <50 label Jan 4, 2022
@tanujkhattar tanujkhattar changed the title Return NotImplemented from Moment._kraus_() if self._has_kraus_() is False Return NotImplemented from Moment._kraus_() if self._has_kraus_() is False Jan 4, 2022
Copy link
Collaborator

@viathor viathor left a comment

Choose a reason for hiding this comment

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

Thanks!

@viathor viathor added the automerge Tells CirqBot to sync and merge this PR. (If it's running.) label Jan 5, 2022
@CirqBot CirqBot added the front_of_queue_automerge CirqBot uses this label to indicate (and remember) what's being merged next. label Jan 5, 2022
@CirqBot CirqBot merged commit b60b9f8 into quantumlib:master Jan 5, 2022
@CirqBot CirqBot removed automerge Tells CirqBot to sync and merge this PR. (If it's running.) front_of_queue_automerge CirqBot uses this label to indicate (and remember) what's being merged next. labels Jan 5, 2022
MichaelBroughton pushed a commit to MichaelBroughton/Cirq that referenced this pull request Jan 22, 2022
…)` is False (quantumlib#4794)

Also implements the same pattern for `Moment._superoperator_()`.

This pattern is followed for other protocols like (eg: `_unitary_` and `_has_unitary_`) and is useful to keep the `protocols.kraus` code consistent.
rht pushed a commit to rht/Cirq that referenced this pull request May 1, 2023
…)` is False (quantumlib#4794)

Also implements the same pattern for `Moment._superoperator_()`.

This pattern is followed for other protocols like (eg: `_unitary_` and `_has_unitary_`) and is useful to keep the `protocols.kraus` code consistent.
harry-phasecraft pushed a commit to PhaseCraft/Cirq that referenced this pull request Oct 31, 2024
…)` is False (quantumlib#4794)

Also implements the same pattern for `Moment._superoperator_()`.

This pattern is followed for other protocols like (eg: `_unitary_` and `_has_unitary_`) and is useful to keep the `protocols.kraus` code consistent.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size: S 10< lines changed <50
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants