forked from Qiskit/qiskit
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix handling of simulator backends in BackendV2Converter (Qiskit#9630)
This commit fixes some issues in the BackendV2Converter class around its usage wrapping BackendV1 based simulators (such as Qiskit Aer with the current release as of this commit 0.11.x). The BackendV2 converter was incorrectly handling some edge cases in Target creation with simulators that have ideal gates. The first issue was that the handling of ideal gates without any properties was incorrect and could not handle gates that took > 1 qubit. This has been corrected so the converter will work as expect. The second issue is the `online_date` field in the `BackendConfiguration` is optional and may not exist, especially on simulators which that field never really applies for. With these fixes the BackendV2Converter can be used to wrap BackendV1 simulators. Fixes Qiskit#9562 Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
- Loading branch information
1 parent
3512bbd
commit 789707c
Showing
3 changed files
with
276 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 9 additions & 0 deletions
9
releasenotes/notes/fix-backendv2-converter-simulator-e8f150d1fd6861fe.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
--- | ||
fixes: | ||
- | | ||
Fixed an issue with the :class:`~.BackendV2Converter` class when wrapping | ||
a :class:`~.BackendV1` based simulator which would error if either | ||
the ``online_date`` field in the :class:`~.BackendConfiguration` for the | ||
simulator was not present or if the simulator backend supports ideal | ||
implementations of gates that involve more than 1 qubit. | ||
Fixed `#9562 <https://github.com/Qiskit/qiskit-terra/issues/9562>`__ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters