-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove deprecated feature in 0.45 in unroller (#11581)
* Removed unroller * Additional removals where unroller appears * Fix lint and remove unroller test * Fixed test_controlled_gate * Fix test_preset_passmanagers * Fixed lint * Fixed test_circuit_methods * Fixed lint * Fixed lint again * Fixed test_circuit_methods again * Fixed test_pass_manager_drawer * Undo change in requirements.txt * Fix test_controlled_gate * Updated release note * Fix test_circuit_methods * Update releasenotes/notes/remove-deprecated-unroller-4693330708c681e0.yaml Co-authored-by: Julien Gacon <[email protected]> * Reverted change to requirements * Added seperate function for equality check to test_controlled_gate * Fixed requirements.txt --------- Co-authored-by: Julien Gacon <[email protected]>
- Loading branch information
1 parent
8002a3e
commit cfb13c9
Showing
22 changed files
with
179 additions
and
1,177 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
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
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
This file was deleted.
Oops, something went wrong.
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
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
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
22 changes: 22 additions & 0 deletions
22
releasenotes/notes/remove-deprecated-unroller-4693330708c681e0.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,22 @@ | ||
--- | ||
upgrade: | ||
- | | ||
Removes the deprecated ``Unroller`` class in :mod:`qiskit.transpiler.passes.basis`. | ||
This class was deprecated in Qiskit Terra 0.45 and has been replaced by | ||
the combination usage of :class:`.BasisTranslator` and :class:`.UnrollCustomDefinitions`. | ||
Note that :class:`.BasisTranslator` and :class:`.UnrollCustomDefinitions` take different | ||
arguments than ``Unroller``, as they requires a `EquivalenceLibrary` object to be passed in. | ||
Where previously ``Unroller(basis_gates)`` could be used, | ||
you can now use:: | ||
from qiskit.circuit.library.standard_gates.equivalence_library import ( | ||
StandardEquivalenceLibrary as std_eqlib, | ||
) | ||
pm = PassManager([ | ||
UnrollCustomDefinitions(std_eqlib, basis_gates) | ||
BasisTranslator(std_eqlib, basis_gates), | ||
]) | ||
translated = pm.run(circuit) | ||
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 |
---|---|---|
|
@@ -6,4 +6,4 @@ dill>=0.3 | |
python-dateutil>=2.8.0 | ||
stevedore>=3.0.0 | ||
typing-extensions | ||
symengine>=0.11 | ||
symengine>=0.11 |
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
Oops, something went wrong.