Skip to content

Added Generic Cirq Target#728

Open
ScottCarda-MS wants to merge 8 commits intomainfrom
sccarda/GenericCirqTarget
Open

Added Generic Cirq Target#728
ScottCarda-MS wants to merge 8 commits intomainfrom
sccarda/GenericCirqTarget

Conversation

@ScottCarda-MS
Copy link
Contributor

@ScottCarda-MS ScottCarda-MS commented Mar 4, 2026

This adds a generic Cirq target wrapper that is automatically applied to all targets that are not Cirq targets, allowing users to submit Cirq jobs to any target. This wrapper will convert Cirq circuits to QIR before submission to the target, and will convert the jobs submitted to Cirq-wrapped targets to appear as Cirq jobs when queried using the azure.quantum.cirq.AzureQuantumService. Finally, it will convert the QIR results of a job submitted to a Cirq-wrapped target to cirq.Result.

For error results like qubit loss, we use a similar strategy as we did with Qiskit. We drop error results, like qubit loss, to keep the standard Cirq result's measurement dict compatible with Cirq tooling that expect only integer 0 or integer 1 results. We keep the raw data for users who are interested in the error results via a new results.raw_shots to get the data as it was returned directly from the target, and a lazy-eval function results.raw_measurements() which will return a measurement dict structured similar to how Cirq's measurement dict is structured, but that contains the raw result chars, including error results.

@ScottCarda-MS ScottCarda-MS marked this pull request as ready for review March 5, 2026 23:24
@ScottCarda-MS ScottCarda-MS requested a review from a team as a code owner March 5, 2026 23:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant