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

Allow StandardRB to handle a V2 backend without a coupling map (backport #1293) #1298

Merged
merged 2 commits into from
Oct 31, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -240,6 +240,9 @@ def _get_basis_gates(self) -> Optional[Tuple[str, ...]]:
return tuple(sorted(basis_gates)) if basis_gates else None

def is_bidirectional(coupling_map):
if coupling_map is None:
# None for a coupling map implies all-to-all coupling
return True
return len(coupling_map.reduce(self.physical_qubits).get_edges()) == 2

# 2 qubits case: Return all basis gates except for one-way directed 2q-gates.
Expand Down
12 changes: 12 additions & 0 deletions releasenotes/notes/rb-v2-none-coupling-fda2b22afdef507b.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
---
fixes:
- |
Changed :class:`.StandardRB` to treat two qubit operations in the
:class:`qiskit.transpiler.Target` as having all-to-all connectivity if
there is no set of specific pairs of coupled qubits. Most importantly, this
change allows :class:`.StandardRB` to work with
:class:`qiskit_aer.AerSimulator` for multi-qubit benchmarking after
``qiskit-aer`` 0.13.0. Version 0.13.0 of ``qiskit-aer`` changed
the default :class:`qiskit_aer.AerSimulator` to have such a
:class:`qiskit.transpiler.Target` without specific coupled pairs.
See `#1292 <https://github.com/Qiskit-Extensions/qiskit-experiments/issues/1292>`__.