-
Notifications
You must be signed in to change notification settings - Fork 82
Open
Labels
cirq_interopIssues related to Cirq interopIssues related to Cirq interop
Description
cirq.ControlledGate uses cirq.has_unitary to verify whether the controlled object can be controlled. This is brittle to rely on in Qualtran: Cirq is trying to ask whether the gate is spiritually unitary, so we used to say "yes, if all registers are THRU registers". But in Cirq 1.5+, has_unitary mostly is asking "can I get a unitary matrix for this gate". In Qualtran, we can have bloqs that represent unitary operations for which we can't compute a unitary matrix.
First reported in #1570. Hacky fix in #1761
We should use the Qualtran controlled protocol for doing controlled versions of things.
Metadata
Metadata
Assignees
Labels
cirq_interopIssues related to Cirq interopIssues related to Cirq interop