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

RB circuits should be made of Clifford objects, not a converted instruction #1023

Open
ajavadia opened this issue Jan 24, 2023 · 0 comments
Open
Assignees
Labels
bug Something isn't working

Comments

@ajavadia
Copy link
Contributor

Informations

  • Qiskit Experiments version:
  • Python version:
  • Operating system:

Current StandardRB and IterleavedRB circuits are built from a Clifford converted to an instruction, which contains the decomposition inside it. In addition to making the circuits heavy, this prevents custom compiling routines on the Cliffords which were recently added to Qiskit (Qiskit/qiskit#7966).

So it's better to build the circuits from Clifford objects and not clifford.to_instruction().

@ajavadia ajavadia added the bug Something isn't working label Jan 24, 2023
github-merge-queue bot pushed a commit that referenced this issue Jan 18, 2024
### Summary
Make the Clifford synthesis algorithm for RB circuits pluggable
(implementing it as a `HighLevelSynthesisPlugin`).
Fixes #1279 and #1023.
Change to accept Clifford elements consisting only of instructions
supported by the backend for `interleaved_element` option in
`InterleavedRB`.
Speed up 2Q RB/IRB for backends with unidirectional 2q gates, e.g. IBM's
127Q Eagle processors.

### Details and comments
Previously, for 3Q+ RB circuits, entire circuit is transpiled at once
and hence for each of the resulting Cliffords, the initial and the final
layout may differ, that means sampled Cliffords are changed during the
transpilation. Also in the worst case, the resulting circuit may use
physical qubits not in the supplied `physical_qubits`. To avoid that,
this commit changes to transpile an RB sequence Clifford by Clifford.
The Clifford synthesis algorithm (`rb_default`) is implemented as a
`HighLevelSynthesisPlugin` (see `RBDefaultCliffordSynthesis` in
`clifford_synthesis.py`), which forces the initial layout (i.e.
guarantees the initial layout = the final layout) and physical qubits to
use. As a byproduct, the performance of 2Q RB/IRB for backends with
directed 2q gates (e.g. IBM's 127Q Eagle processors) is drastically
improved. For those cases, previously we had to rely on `transpile`
function to make generated circuits comply with the coupling map,
however, after this commit, we can synthesize Cliffords with considering
the 2q-gate direction and go through the fast path introduced in #982.

Depends on Qiskit/qiskit#10477 (qiskit 0.45)

---------

Co-authored-by: Helena Zhang <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants