From fa0491b87736f5244c0e604df71cfcd91683aa43 Mon Sep 17 00:00:00 2001 From: Kevin Hartman Date: Thu, 27 Jul 2023 17:36:52 -0400 Subject: [PATCH] Prepare 0.25.0 release (#10497) * Bump version. * Add 0.25.0 release prelude. * Remove 0.24 backports from releasenotes/notes/0.25. * Update releasenotes/config.yaml for categories. * New features section. * Fix circular import. * Add misc section. * Fixes. * More fixes. * Fixes. * Hack for section containing only other subsections. * Upgrades section. * Deprecations section. * Bugfix section. * Update prelude. * Address review comments. * Update algorithms prelude. * Additional fixups. * Address review comments. * Update for comments on #10503. --------- Co-authored-by: Matthew Treinish --- qiskit/VERSION.txt | 2 +- qiskit/dagcircuit/__init__.py | 11 ++ qiskit/dagcircuit/collect_blocks.py | 13 ++- qiskit/pulse/__init__.py | 2 + qiskit/pulse/library/__init__.py | 1 + qiskit/quantum_info/__init__.py | 1 + qiskit/quantum_info/states/measures.py | 6 +- releasenotes/config.yaml | 43 ++++++++ ...ubit_coordinates_map-8abc318fefdb99ac.yaml | 4 - ...-parameterexpression-347ffef62946b38b.yaml | 5 +- ...k-collection-options-359d5e496313acdb.yaml | 11 +- ...assical-predecessors-9ecef0561822e934.yaml | 6 +- ...ve-cancellation-pass-85fe310d911d9a00.yaml | 10 +- ...o-consolidate-blocks-e013e28007170377.yaml | 9 +- .../add-dag-causal-cone-5a19311e40fbb3af.yaml | 2 +- ...onal-to-DiagonalGate-c945e0f8adcd2940.yaml | 5 - ...garithmic-negativity-fce5d8392460a0e9.yaml | 9 +- ...-to-positional-index-6cd43a42f56eb549.yaml | 17 ++- ...d-pauli-equivalences-74c635ec5c23ee33.yaml | 6 +- ...chmidt-decomposition-c196cff16381b305.yaml | 9 +- ...a_allocation_no_cmap-ac3ff65b3639988e.yaml | 8 +- ...er-to-concrete-value-7cad75c97183257f.yaml | 29 ----- .../clifford-no-circuly-c7c4a1c9c5472af7.yaml | 2 +- .../ctrl-flow-o2-o3-83f660d704226848.yaml | 2 +- .../cx_cz_synthesis-3d5ec98372ce1608.yaml | 18 ++-- ...-propagate-condition-898052b53edb1f17.yaml | 2 +- ...t-separable-circuits-142853e69f530a16.yaml | 8 +- ...deprecate-algorithms-7149dee2da586549.yaml | 8 +- ...cuit-library-jupyter-629f927e8dd5cc22.yaml | 4 +- ...eprecate-complex-amp-41381bd9722bc878.yaml | 10 +- ...e-get_vf2_call_limit-826e0f9212fb27b9.yaml | 2 +- ...ate-instruction-qasm-9380f721e7bdaf6b.yaml | 11 +- ...lse-Call-instruction-538802d8fad7e257.yaml | 10 +- ...-library-deprecation-3a95eba7e29d8d49.yaml | 12 ++- ...trol-flow-mpl-drawer-2dbc7b57ac52d138.yaml | 13 ++- ...arget_aware_meas_map-0d8542402a74e9d8.yaml | 21 ++-- ...ter-parameter-rebind-3c799e74456469d9.yaml | 2 +- ...ilter-schedule-block-29d392ca351f1fb1.yaml | 6 +- ...m-shannon-decomposer-c99ce6509f03715b.yaml | 7 -- ...ix-basicswap-fakerun-7469835327f6c8a1.yaml | 4 - .../0.25/fix-bit-copy-4b2f7349683f616a.yaml | 7 -- ...map-nested-condition-1776f952f6c6722a.yaml | 6 -- ...collapse-with-clbits-e14766353303d442.yaml | 9 -- .../fix-compose-switch-19ada3828d939353.yaml | 5 - .../fix-decompose-name-f83f5e4e64918aa9.yaml | 2 +- .../fix-delay-padding-75937bda37ebc3fd.yaml | 13 --- ...dispatching-backends-28aff96f726ca9c5.yaml | 4 - ...exception-decription-3ba0b5db82c576cf.yaml | 4 - ...ion-from_dimacs_file-b9338f3c913a9bff.yaml | 7 -- ..._layout-loose-qubits-0c59b2d6fb99d7e6.yaml | 6 -- ...-mcrz-relative-phase-6ea81a369f8bda38.yaml | 7 -- ...utputs-of-measure_v2-8959ebbbf5f87294.yaml | 7 -- ...ranspose-output-dims-3082fcf4147055dc.yaml | 5 - ...egend-not-showing-up-3202bec143529e49.yaml | 6 +- ...-config-from-backend-f3b71b11858b4f08.yaml | 9 -- ...ives-import-warnings-439e3e237fdb9d7b.yaml | 7 -- ...-qasm-circuit-export-943394536bc0d292.yaml | 7 -- ...er-of-QuantumCircuit-7dd3e84e1dea1abd.yaml | 8 -- ...with-symbolic-angles-a070b9973a16b8c3.yaml | 6 -- ...synthesis-cf-mapping-fe9bd2e5fbd56dfb.yaml | 6 -- ...fix-transpile-pickle-4045805b67c0c11b.yaml | 5 - ...ruction-schedule-map-d1cba4e4db4b679e.yaml | 5 +- .../fix-vf2-scoring-1q-e2ac29075831d64d.yaml | 6 -- .../0.25/fix-vqd-result-27b26f0a6d49e7c7.yaml | 5 - .../notes/0.25/fix_9016-2e8bc2cb10b5e204.yaml | 7 +- .../0.25/fixes_8060-ae91e0da9d53a288.yaml | 8 +- ...latten-nlocal-family-292b23b99947f3c9.yaml | 2 +- ...an-square-echo-pulse-84306f1a02e2bb28.yaml | 9 +- .../has-pygments-tester-3fb9f9c34907d45d.yaml | 2 +- ...gn-parameters-typing-70c9623405cbd420.yaml | 2 +- ...-functions-usability-45265f293a80a6e5.yaml | 6 +- ...ircuit-qasm2-methods-b1a06ee2859e2cce.yaml | 13 ++- .../normalize-stateprep-e21972dce8695509.yaml | 2 +- ...e-consolidate-blocks-3ea60c18bc546273.yaml | 9 +- ...parameter-float-cast-48f3731fec5e47cd.yaml | 13 --- ...otation-equivalences-6b2449c93c042dc9.yaml | 2 +- ...et-pm-vf2-max-trials-958bb8a36fff472f.yaml | 23 ---- ...qasm3-alias-refactor-3389bfce3e29e4cf.yaml | 4 +- .../qasm3-no-subroutine-b69c5ed7c65ce9ac.yaml | 2 +- .../0.25/qiskit_version-956916f7b8d7bbb9.yaml | 8 +- .../0.25/qpy-layout-927ab34f2b47f4aa.yaml | 12 --- ...riminator_and_kernel-3b6048bf1499f9d3.yaml | 2 +- ...e_order_restrictions-ffc0cfeacd7b8d4b.yaml | 4 +- ...ionset-circuit-cregs-91617e4b0993db9a.yaml | 2 +- ...eprecated-mpl-drawer-9d6eaa40d5a86777.yaml | 4 +- ...-transpile-broadcast-1dfde28d508efa0d.yaml | 8 +- .../0.25/remove-util-3cd9eae2efc95176.yaml | 2 +- .../sabre-control-flow-3772af2c5b02c6d5.yaml | 4 +- .../sabre-ctrl-flow-o1-431cd25a19adbcdc.yaml | 2 +- ...meter-multiplication-245173f0b232f59b.yaml | 4 +- ...en-swapper-rustworkx-9e02c0ab67a59fe8.yaml | 4 +- .../0.25/umda-callback-eb644a49c5a9ad37.yaml | 4 +- ...unding-with-max-size-1498af5f9a467990.yaml | 5 +- .../notes/0.25/use-abi3-4a935e0557d3833b.yaml | 4 +- ...l-validation-bug-fix-c06f8445cecc8478.yaml | 2 +- ...pr-rvalue-conditions-8b5d5f7c015658c0.yaml | 23 ++-- .../notes/prepare-0.25-2efd7230b0ae0719.yaml | 100 ++++++++++++++++++ setup.py | 2 +- 98 files changed, 375 insertions(+), 428 deletions(-) delete mode 100644 releasenotes/notes/0.25/433_qubit_coordinates_map-8abc318fefdb99ac.yaml delete mode 100644 releasenotes/notes/0.25/add-diagonal-to-DiagonalGate-c945e0f8adcd2940.yaml delete mode 100644 releasenotes/notes/0.25/circuit-assign-parameter-to-concrete-value-7cad75c97183257f.yaml delete mode 100644 releasenotes/notes/0.25/fix-1q-matrix-bug-in-quantum-shannon-decomposer-c99ce6509f03715b.yaml delete mode 100644 releasenotes/notes/0.25/fix-basicswap-fakerun-7469835327f6c8a1.yaml delete mode 100644 releasenotes/notes/0.25/fix-bit-copy-4b2f7349683f616a.yaml delete mode 100644 releasenotes/notes/0.25/fix-checkmap-nested-condition-1776f952f6c6722a.yaml delete mode 100644 releasenotes/notes/0.25/fix-collapse-with-clbits-e14766353303d442.yaml delete mode 100644 releasenotes/notes/0.25/fix-compose-switch-19ada3828d939353.yaml delete mode 100644 releasenotes/notes/0.25/fix-delay-padding-75937bda37ebc3fd.yaml delete mode 100644 releasenotes/notes/0.25/fix-dispatching-backends-28aff96f726ca9c5.yaml delete mode 100644 releasenotes/notes/0.25/fix-exception-decription-3ba0b5db82c576cf.yaml delete mode 100644 releasenotes/notes/0.25/fix-exception-from_dimacs_file-b9338f3c913a9bff.yaml delete mode 100644 releasenotes/notes/0.25/fix-initial_layout-loose-qubits-0c59b2d6fb99d7e6.yaml delete mode 100644 releasenotes/notes/0.25/fix-mcrz-relative-phase-6ea81a369f8bda38.yaml delete mode 100644 releasenotes/notes/0.25/fix-outputs-of-measure_v2-8959ebbbf5f87294.yaml delete mode 100644 releasenotes/notes/0.25/fix-partial-transpose-output-dims-3082fcf4147055dc.yaml delete mode 100644 releasenotes/notes/0.25/fix-pm-config-from-backend-f3b71b11858b4f08.yaml delete mode 100644 releasenotes/notes/0.25/fix-primitives-import-warnings-439e3e237fdb9d7b.yaml delete mode 100644 releasenotes/notes/0.25/fix-qasm-circuit-export-943394536bc0d292.yaml delete mode 100644 releasenotes/notes/0.25/fix-regression-in-the-LaTeX-drawer-of-QuantumCircuit-7dd3e84e1dea1abd.yaml delete mode 100644 releasenotes/notes/0.25/fix-synth-fail-with-symbolic-angles-a070b9973a16b8c3.yaml delete mode 100644 releasenotes/notes/0.25/fix-synthesis-cf-mapping-fe9bd2e5fbd56dfb.yaml delete mode 100644 releasenotes/notes/0.25/fix-transpile-pickle-4045805b67c0c11b.yaml delete mode 100644 releasenotes/notes/0.25/fix-vf2-scoring-1q-e2ac29075831d64d.yaml delete mode 100644 releasenotes/notes/0.25/fix-vqd-result-27b26f0a6d49e7c7.yaml delete mode 100644 releasenotes/notes/0.25/parameter-float-cast-48f3731fec5e47cd.yaml delete mode 100644 releasenotes/notes/0.25/preset-pm-vf2-max-trials-958bb8a36fff472f.yaml delete mode 100644 releasenotes/notes/0.25/qpy-layout-927ab34f2b47f4aa.yaml create mode 100644 releasenotes/notes/prepare-0.25-2efd7230b0ae0719.yaml diff --git a/qiskit/VERSION.txt b/qiskit/VERSION.txt index 2e65a4dedb1b..d21d277be513 100644 --- a/qiskit/VERSION.txt +++ b/qiskit/VERSION.txt @@ -1 +1 @@ -0.25.0rc1 +0.25.0 diff --git a/qiskit/dagcircuit/__init__.py b/qiskit/dagcircuit/__init__.py index 2c5ed3dbd03e..b7d558e4b973 100644 --- a/qiskit/dagcircuit/__init__.py +++ b/qiskit/dagcircuit/__init__.py @@ -38,7 +38,18 @@ :toctree: ../stubs/ DAGCircuitError + +Utilities +========= + +.. autosummary:: + :toctree: ../stubs/ + + BlockCollapser + BlockCollector + BlockSplitter """ +from .collect_blocks import BlockCollapser, BlockCollector, BlockSplitter from .dagcircuit import DAGCircuit from .dagnode import DAGNode, DAGOpNode, DAGInNode, DAGOutNode from .dagdepnode import DAGDepNode diff --git a/qiskit/dagcircuit/collect_blocks.py b/qiskit/dagcircuit/collect_blocks.py index cf9adf16fe85..3da89ad977b0 100644 --- a/qiskit/dagcircuit/collect_blocks.py +++ b/qiskit/dagcircuit/collect_blocks.py @@ -16,7 +16,9 @@ from qiskit.circuit import QuantumCircuit, CircuitInstruction, ClassicalRegister from qiskit.circuit.controlflow import condition_resources -from . import DAGOpNode, DAGCircuit, DAGDependency +from .dagnode import DAGOpNode +from .dagcircuit import DAGCircuit +from .dagdependency import DAGDependency from .exceptions import DAGCircuitError @@ -318,15 +320,18 @@ def split_block_into_layers(block): class BlockCollapser: """This class implements various strategies of consolidating blocks of nodes - in a DAG (direct acyclic graph). It works both with the - :class:`~qiskit.dagcircuit.DAGCircuit` and - :class:`~qiskit.dagcircuit.DAGDependency` DAG representations. + in a DAG (direct acyclic graph). It works both with + the :class:`~qiskit.dagcircuit.DAGCircuit` + and :class:`~qiskit.dagcircuit.DAGDependency` DAG representations. """ def __init__(self, dag): """ Args: dag (Union[DAGCircuit, DAGDependency]): The input DAG. + + Raises: + DAGCircuitError: the input object is not a DAG. """ self.dag = dag diff --git a/qiskit/pulse/__init__.py b/qiskit/pulse/__init__.py index d8c42734cebf..90d84d54f821 100644 --- a/qiskit/pulse/__init__.py +++ b/qiskit/pulse/__init__.py @@ -34,6 +34,7 @@ This is sufficient to allow the quantum physicist to explore and correct for noise in a quantum system. +.. automodule:: qiskit.pulse.configuration .. automodule:: qiskit.pulse.instructions .. automodule:: qiskit.pulse.library .. automodule:: qiskit.pulse.channels @@ -51,6 +52,7 @@ InstructionScheduleMap + Exceptions ========== diff --git a/qiskit/pulse/library/__init__.py b/qiskit/pulse/library/__init__.py index d8809607e3d9..f019e6332c04 100644 --- a/qiskit/pulse/library/__init__.py +++ b/qiskit/pulse/library/__init__.py @@ -48,6 +48,7 @@ :toctree: ../stubs/ Waveform + ScalableSymbolicPulse SymbolicPulse ParametricPulse diff --git a/qiskit/quantum_info/__init__.py b/qiskit/quantum_info/__init__.py index 6021955e8d54..a07b1bc0c95e 100644 --- a/qiskit/quantum_info/__init__.py +++ b/qiskit/quantum_info/__init__.py @@ -76,6 +76,7 @@ Utility Functions ================= +.. autofunction:: negativity .. autofunction:: partial_trace .. autofunction:: schmidt_decomposition .. autofunction:: shannon_entropy diff --git a/qiskit/quantum_info/states/measures.py b/qiskit/quantum_info/states/measures.py index a5f988fccd20..53d1c9decb02 100644 --- a/qiskit/quantum_info/states/measures.py +++ b/qiskit/quantum_info/states/measures.py @@ -258,10 +258,12 @@ def entanglement_of_formation(state: Statevector | DensityMatrix) -> float: def negativity(state, qargs): - r"""Calculates the negativity + r"""Calculates the negativity. The mathematical expression for negativity is given by: + .. math:: + {\cal{N}}(\rho) = \frac{|| \rho^{T_A}|| - 1 }{2} Args: @@ -269,7 +271,7 @@ def negativity(state, qargs): qargs (list): The subsystems to be transposed. Returns: - negv (float): Negativity value of the quantum state + float: Negativity value of the quantum state Raises: QiskitError: if the input state is not a valid QuantumState. diff --git a/releasenotes/config.yaml b/releasenotes/config.yaml index 141d552cd9f0..006c7d68cce2 100644 --- a/releasenotes/config.yaml +++ b/releasenotes/config.yaml @@ -1,3 +1,46 @@ --- encoding: utf8 default_branch: main +collapse_pre_releases: true +sections: + - [features, New Features] + - [features_transpiler, Transpiler Features, 2] + - [features_circuits, Circuits Features, 2] + - [features_algorithms, Algorithms Features, 2] + - [features_qasm, OpenQASM Features, 2] + - [features_quantum_info, Quantum Information Features, 2] + - [features_pulse, Pulse Features, 2] + - [features_providers, Providers Features, 2] + - [features_primitives, Primitives Features, 2] + - [features_synthesis, Synthesis Features, 2] + - [features_visualization, Visualization Features, 2] + - [features_misc, Misc. Features, 2] + - [issues, Known Issues] + - [upgrade, Upgrade Notes] + - [upgrade_transpiler, Transpiler Upgrade Notes, 2] + - [upgrade_circuits, Circuits Upgrade Notes, 2] + - [upgrade_algorithms, Algorithms Upgrade Notes, 2] + - [upgrade_qasm, OpenQASM Upgrade Notes, 2] + - [upgrade_quantum_info, Quantum Information Upgrade Notes, 2] + - [upgrade_pulse, Pulse Upgrade Notes, 2] + - [upgrade_providers, Providers Upgrade Notes, 2] + - [upgrade_primitives, Primitives Upgrade Notes, 2] + - [upgrade_synthesis, Synthesis Upgrade Notes, 2] + - [upgrade_visualization, Visualization Upgrade Notes, 2] + - [upgrade_misc, Misc. Upgrade Notes, 2] + - [deprecations, Deprecation Notes] + - [deprecations_transpiler, Transpiler Deprecations, 2] + - [deprecations_circuits, Circuits Deprecations, 2] + - [deprecations_algorithms, Algorithms Deprecations, 2] + - [deprecations_qasm, OpenQASM Deprecations, 2] + - [deprecations_quantum_info, Quantum Information Deprecations, 2] + - [deprecations_pulse, Pulse Deprecations, 2] + - [deprecations_providers, Providers Deprecations, 2] + - [deprecations_primitives, Primitives Deprecations, 2] + - [deprecations_synthesis, Synthesis Deprecations, 2] + - [deprecations_visualization, Visualization Deprecations, 2] + - [deprecations_misc, Misc. Deprecations, 2] + - [critical, Critical Issues] + - [security, Security Issues] + - [fixes, Bug Fixes] + - [other, Other Notes] diff --git a/releasenotes/notes/0.25/433_qubit_coordinates_map-8abc318fefdb99ac.yaml b/releasenotes/notes/0.25/433_qubit_coordinates_map-8abc318fefdb99ac.yaml deleted file mode 100644 index ede523105e6c..000000000000 --- a/releasenotes/notes/0.25/433_qubit_coordinates_map-8abc318fefdb99ac.yaml +++ /dev/null @@ -1,4 +0,0 @@ ---- -fixes: - - | - Updated :func:`~qiskit.visualization.plot_gate_map`, :func:`~qiskit.visualization.plot_error_map`, and :func:`~qiskit.visualization.plot_circuit_layout` to support 433 qubit heavy-hex coupling maps. This allows coupling map visualizations for IBM's ``ibm_seattle``. diff --git a/releasenotes/notes/0.25/add-abs-to-parameterexpression-347ffef62946b38b.yaml b/releasenotes/notes/0.25/add-abs-to-parameterexpression-347ffef62946b38b.yaml index 1385724d8d1f..86059a4f9e97 100644 --- a/releasenotes/notes/0.25/add-abs-to-parameterexpression-347ffef62946b38b.yaml +++ b/releasenotes/notes/0.25/add-abs-to-parameterexpression-347ffef62946b38b.yaml @@ -1,5 +1,8 @@ +features: + - | + The following features have been added in this release. -issues: +features_circuits: - | Added support for taking absolute values of :class:`.ParameterExpression`\s. For example, the following is now possible:: diff --git a/releasenotes/notes/0.25/add-block-collection-options-359d5e496313acdb.yaml b/releasenotes/notes/0.25/add-block-collection-options-359d5e496313acdb.yaml index 0c0fe3eadd2f..721b6adfa329 100644 --- a/releasenotes/notes/0.25/add-block-collection-options-359d5e496313acdb.yaml +++ b/releasenotes/notes/0.25/add-block-collection-options-359d5e496313acdb.yaml @@ -1,18 +1,19 @@ --- -features: +features_transpiler: - | - Added two new options to :class:`~BlockCollector`. + Added two new options to :class:`~qiskit.dagcircuit.BlockCollector`. - The first new options ``split_layers`` allows to split the collected block into sub-blocks + The first new option ``split_layers`` allows collected blocks to be split into sub-blocks over disjoint qubit subsets, i.e. into depth-1 sub-blocks. - The second new option ``collect_from_back`` allows to greedily collect blocks starting + The second new option ``collect_from_back`` allows blocks to be greedily collected starting from the outputs of the circuit. This is important in combination with ALAP-scheduling passes where we may prefer to put gates in the later rather than earlier blocks. - | Added new options ``split_layers`` and ``collect_from_back`` to - :class:`~CollectLinearFunctions` and :class:`~CollectCliffords` transpiler passes. + :class:`~qiskit.transpiler.passes.CollectLinearFunctions` and + :class:`~qiskit.transpiler.passes.CollectCliffords` transpiler passes. When ``split_layers`` is `True`, the collected blocks are split into into sub-blocks over disjoint qubit subsets, i.e. into depth-1 sub-blocks. diff --git a/releasenotes/notes/0.25/add-classical-predecessors-9ecef0561822e934.yaml b/releasenotes/notes/0.25/add-classical-predecessors-9ecef0561822e934.yaml index 9c554633d4ff..4b9c7675b292 100644 --- a/releasenotes/notes/0.25/add-classical-predecessors-9ecef0561822e934.yaml +++ b/releasenotes/notes/0.25/add-classical-predecessors-9ecef0561822e934.yaml @@ -1,9 +1,9 @@ --- -features: +features_transpiler: - | Added :meth:`.DAGCircuit.classical_predecessors` and - :meth:`.DAGCircuit.classical_successors`, an alternative to select the classical - wires without having to go to the inner graph object directly of a node in the DAG. + :meth:`.DAGCircuit.classical_successors`, an alternative to selecting classical + wires that doesn't require accessing the inner graph of a DAG node directly. The following example illustrates the new functionality:: from qiskit import QuantumCircuit, QuantumRegister, ClassicalRegister diff --git a/releasenotes/notes/0.25/add-control-flow-to-commutative-cancellation-pass-85fe310d911d9a00.yaml b/releasenotes/notes/0.25/add-control-flow-to-commutative-cancellation-pass-85fe310d911d9a00.yaml index c668bd242c70..0c1026dc4ae2 100644 --- a/releasenotes/notes/0.25/add-control-flow-to-commutative-cancellation-pass-85fe310d911d9a00.yaml +++ b/releasenotes/notes/0.25/add-control-flow-to-commutative-cancellation-pass-85fe310d911d9a00.yaml @@ -1,8 +1,6 @@ --- -features: +features_transpiler: - | - Enabled performing the :class:`qiskit.transpiler.passes.CommutativeCancellation` pass inside the - blocks of :class:`qiskit.circuit.ControlFlowOp`. This pass reorders some commuting gates and - reduces resulting pairs of self-inverse gates. Previously, the blocks in control flow operations - were skipped by this pass. The new feature operates recursively, that is, it will act on control - flow operations inside blocks. + Enabled support for :class:`~qiskit.circuit.ControlFlowOp` operations in the + :class:`~qiskit.transpiler.passes.CommutativeCancellation` pass. + Previously, the blocks in control flow operations were skipped by this pass. diff --git a/releasenotes/notes/0.25/add-control-flow-to-consolidate-blocks-e013e28007170377.yaml b/releasenotes/notes/0.25/add-control-flow-to-consolidate-blocks-e013e28007170377.yaml index cdfc14ca3810..2f555b5e4231 100644 --- a/releasenotes/notes/0.25/add-control-flow-to-consolidate-blocks-e013e28007170377.yaml +++ b/releasenotes/notes/0.25/add-control-flow-to-consolidate-blocks-e013e28007170377.yaml @@ -1,9 +1,4 @@ --- -features: +features_transpiler: - | - Enabled performing the :class:`.ConsolidateBlocks` pass inside the - blocks of :class:`.ControlFlowOp`. This pass collects several sequences of gates - and replaces each sequence with the equivalent numeric unitary gate. This new feature enables - applying this pass recursively to the blocks in control flow operations. Note that the meaning - of "block" in :class:`.ConsolidateBlocks` is unrelated to that in - :class:`.ControlFlowOp`. + Enabled support for :class:`.ControlFlowOp` operations in the :class:`.ConsolidateBlocks` pass. diff --git a/releasenotes/notes/0.25/add-dag-causal-cone-5a19311e40fbb3af.yaml b/releasenotes/notes/0.25/add-dag-causal-cone-5a19311e40fbb3af.yaml index 3785fadd73ea..c2fe04d5984c 100644 --- a/releasenotes/notes/0.25/add-dag-causal-cone-5a19311e40fbb3af.yaml +++ b/releasenotes/notes/0.25/add-dag-causal-cone-5a19311e40fbb3af.yaml @@ -1,5 +1,5 @@ --- -features: +features_transpiler: - | Added :meth:`.DAGCircuit.quantum_causal_cone` to obtain the causal cone of a qubit in a :class:`~.DAGCircuit`. diff --git a/releasenotes/notes/0.25/add-diagonal-to-DiagonalGate-c945e0f8adcd2940.yaml b/releasenotes/notes/0.25/add-diagonal-to-DiagonalGate-c945e0f8adcd2940.yaml deleted file mode 100644 index 1252b13ef89e..000000000000 --- a/releasenotes/notes/0.25/add-diagonal-to-DiagonalGate-c945e0f8adcd2940.yaml +++ /dev/null @@ -1,5 +0,0 @@ ---- -fixes: - - | - Fixed the deserialization of :class:`.DiagonalGate` instances through QPY. - See `#10364 `__. diff --git a/releasenotes/notes/0.25/add-feature-negativity-logarithmic-negativity-fce5d8392460a0e9.yaml b/releasenotes/notes/0.25/add-feature-negativity-logarithmic-negativity-fce5d8392460a0e9.yaml index 2a62f886e0f0..e7785e1bb3d8 100644 --- a/releasenotes/notes/0.25/add-feature-negativity-logarithmic-negativity-fce5d8392460a0e9.yaml +++ b/releasenotes/notes/0.25/add-feature-negativity-logarithmic-negativity-fce5d8392460a0e9.yaml @@ -1,11 +1,10 @@ --- -features: +features_quantum_info: - | - Added a new function , :func:`negativity` that adds support for calculating - entanglement measures negativity of an quantum state. - An illustrative example for using the above function is given below: + Added a new function :func:`~qiskit.quantum_info.negativity` that calculates + the entanglement measure of negativity of a quantum state. + Example usage of the above function is given below:: - .. code-block: from qiskit.quantum_info.states.densitymatrix import DensityMatrix from qiskit.quantum_info.states.statevector import Statevector from qiskit.quantum_info import negativity diff --git a/releasenotes/notes/0.25/add-method-for-mapping-qubit-clbit-to-positional-index-6cd43a42f56eb549.yaml b/releasenotes/notes/0.25/add-method-for-mapping-qubit-clbit-to-positional-index-6cd43a42f56eb549.yaml index 50200ff8e94f..af537febe985 100644 --- a/releasenotes/notes/0.25/add-method-for-mapping-qubit-clbit-to-positional-index-6cd43a42f56eb549.yaml +++ b/releasenotes/notes/0.25/add-method-for-mapping-qubit-clbit-to-positional-index-6cd43a42f56eb549.yaml @@ -1,12 +1,9 @@ --- -features: +features_transpiler: - | - A new method, :meth:`~qiskit.dagcircuit.dag.find_bit`, has - been added to the :class:`~qiskit.dagcircuit.DagCircuit` class. - This is a method to get mapping of Qubit and Clbit to positional index. - The method takes a Bit as input, checks whether it's a Qubit or a Clbit, - and then returns the corresponding BitLocations from the respective index - dictionary (_qubit_indices or _clbit_indices). - The BitLocations is a namedtuple which includes the positional index of the - bit in the circuit and a list of registers containing the bit. If the bit - cannot be found or is of an unknown type, it raises a DAGCircuitError. \ No newline at end of file + A new method :meth:`~qiskit.dagcircuit.DAGCircuit.find_bit` has + been added to the :class:`~qiskit.dagcircuit.DAGCircuit` class, + which returns the bit locations of the given :class:`.Qubit` or + :class:`.Clbit` as a tuple of the positional index of the bit within + the circuit and a list of tuples which locate the bit in the circuit's + registers. diff --git a/releasenotes/notes/0.25/add-pauli-equivalences-74c635ec5c23ee33.yaml b/releasenotes/notes/0.25/add-pauli-equivalences-74c635ec5c23ee33.yaml index cba26f7b8f82..f3a408cccaa0 100644 --- a/releasenotes/notes/0.25/add-pauli-equivalences-74c635ec5c23ee33.yaml +++ b/releasenotes/notes/0.25/add-pauli-equivalences-74c635ec5c23ee33.yaml @@ -1,7 +1,9 @@ --- -features: +features_transpiler: - | - The transpiler's built-in :class:`.EquivalenceLibrary` has been taught the circular Pauli + The transpiler's built-in :class:`.EquivalenceLibrary` + (``qiskit.circuit.equivalence_library.SessionEquivalenceLibrary``) + has been taught the circular Pauli relations :math:`X = iYZ`, :math:`Y = iZX` and :math:`Z = iXY`. This should make transpiling to constrained, and potentially incomplete, basis sets more reliable. See `#10293 `__ for more detail. diff --git a/releasenotes/notes/0.25/add-schmidt-decomposition-c196cff16381b305.yaml b/releasenotes/notes/0.25/add-schmidt-decomposition-c196cff16381b305.yaml index 725a5bd1b26e..083a9aaefcc8 100644 --- a/releasenotes/notes/0.25/add-schmidt-decomposition-c196cff16381b305.yaml +++ b/releasenotes/notes/0.25/add-schmidt-decomposition-c196cff16381b305.yaml @@ -1,6 +1,7 @@ --- -features: +features_quantum_info: - | - Add ``schmidt_decomposition`` function to the ``quantum_info`` module. - This function works with the ``Statevector`` and ``DensityMatrix`` - classes for bipartite pure states. + Added the function :func:`~qiskit.quantum_info.schmidt_decomposition`. + This function works with the :class:`~qiskit.quantum_info.Statevector` + and :class:`~qiskit.quantum_info.DensityMatrix` classes for bipartite + pure states. diff --git a/releasenotes/notes/0.25/ancilla_allocation_no_cmap-ac3ff65b3639988e.yaml b/releasenotes/notes/0.25/ancilla_allocation_no_cmap-ac3ff65b3639988e.yaml index ac8d2c1d9eb1..49eb1a58d8b7 100644 --- a/releasenotes/notes/0.25/ancilla_allocation_no_cmap-ac3ff65b3639988e.yaml +++ b/releasenotes/notes/0.25/ancilla_allocation_no_cmap-ac3ff65b3639988e.yaml @@ -1,7 +1,7 @@ --- fixes: - | - Fixed an issue with :class:`~.FullAncillaAllocation` so it can now function with :class:`~.Target` objects that do not have a - coupling map (typically because there are no 2 qubit gates in the :class:`~.Target`). In this case :class:`~.FullAncillaAllocation` will add - ancilla qubits so that the number of qubits in the :class:`~.DAGCircuit` matches the number - :attr:`.Target.num_qubits`. + Fixed an issue with using :class:`~.Target`\ s without coupling maps with the :class:`~.FullAncillaAllocation` transpiler pass. + In this case, :class:`~.FullAncillaAllocation` will now add + ancilla qubits so that the number of qubits in the :class:`~.DAGCircuit` matches + that of :attr:`Target.num_qubits`. diff --git a/releasenotes/notes/0.25/circuit-assign-parameter-to-concrete-value-7cad75c97183257f.yaml b/releasenotes/notes/0.25/circuit-assign-parameter-to-concrete-value-7cad75c97183257f.yaml deleted file mode 100644 index 036d672e480d..000000000000 --- a/releasenotes/notes/0.25/circuit-assign-parameter-to-concrete-value-7cad75c97183257f.yaml +++ /dev/null @@ -1,29 +0,0 @@ ---- -fixes: - - | - Changed the binding of numeric values with - :meth:`.QuantumCircuit.assign_parameters` to avoid a mismatch between the - values of circuit instruction parameters and corresponding parameter keys - in the circuit's calibration dictionary. Fixed `#9764 - `_ and `#10166 - `_. See also the - related upgrade note regarding :meth:`.QuantumCircuit.assign_parameters`. -upgrade: - - | - Changed :meth:`.QuantumCircuit.assign_parameters` to bind - assigned integer and float values directly into the parameters of - :class:`~qiskit.circuit.Instruction` instances in the circuit rather than - binding the values wrapped within a - :class:`~qiskit.circuit.ParameterExpression`. This change should have - little user impact as ``float(QuantumCircuit.data[i].operation.params[j])`` - still produces a ``float`` (and is the only way to access the value of a - :class:`~qiskit.circuit.ParameterExpression`). Also, - :meth:`~qiskit.circuit.Instruction` parameters could already be ``float`` - as well as a :class:`~qiskit.circuit.ParameterExpression`, so code dealing - with instruction parameters should already handle both cases. The most - likely chance for user impact is in code that uses ``isinstance`` to check - for :class:`~qiskit.circuit.ParameterExpression` and behaves differently - depending on the result. Additionally, qpy serializes the numeric value in - a bound :class:`~qiskit.circuit.ParameterExpression` at a different - precision than a ``float`` (see also the related bug fix note about - :meth:`.QuantumCircuit.assign_parameters`). diff --git a/releasenotes/notes/0.25/clifford-no-circuly-c7c4a1c9c5472af7.yaml b/releasenotes/notes/0.25/clifford-no-circuly-c7c4a1c9c5472af7.yaml index 5fb80275a98c..210ad733e541 100644 --- a/releasenotes/notes/0.25/clifford-no-circuly-c7c4a1c9c5472af7.yaml +++ b/releasenotes/notes/0.25/clifford-no-circuly-c7c4a1c9c5472af7.yaml @@ -1,5 +1,5 @@ --- -upgrade: +upgrade_quantum_info: - | :meth:`.Clifford.from_circuit` will no longer attempt to resolve instructions whose :attr:`~.circuit.Instruction.definition` fields are mutually recursive with some other object. diff --git a/releasenotes/notes/0.25/ctrl-flow-o2-o3-83f660d704226848.yaml b/releasenotes/notes/0.25/ctrl-flow-o2-o3-83f660d704226848.yaml index 19e4bbe1d818..dac0c37584be 100644 --- a/releasenotes/notes/0.25/ctrl-flow-o2-o3-83f660d704226848.yaml +++ b/releasenotes/notes/0.25/ctrl-flow-o2-o3-83f660d704226848.yaml @@ -1,5 +1,5 @@ --- -features: +features_transpiler: - | Control-flow operations are now supported through the transpiler at all optimization levels, including levels 2 and 3 (e.g. calling diff --git a/releasenotes/notes/0.25/cx_cz_synthesis-3d5ec98372ce1608.yaml b/releasenotes/notes/0.25/cx_cz_synthesis-3d5ec98372ce1608.yaml index 2f91f60cc002..8509e1a2d7bc 100644 --- a/releasenotes/notes/0.25/cx_cz_synthesis-3d5ec98372ce1608.yaml +++ b/releasenotes/notes/0.25/cx_cz_synthesis-3d5ec98372ce1608.yaml @@ -1,10 +1,12 @@ --- -features: +features_synthesis: - | - Added a new synthesis algorithm :func:`qiskit.synthesis.linear_phase.synth_cx_cz_depth_line_my` - of a CX circuit followed by a CZ circuit for linear nearest neighbor (LNN) connectivity in - 2-qubit depth of at most 5n using CX and phase gates (S, Sdg or Z). The synthesis algorithm is - based on the paper of Maslov and Yang (https://arxiv.org/abs/2210.16195). + Added a new synthesis function :func:`~qiskit.synthesis.synth_cx_cz_depth_line_my` + which produces the circuit form of a CX circuit followed by a CZ circuit for linear + nearest neighbor (LNN) connectivity in 2-qubit depth of at most 5n, using CX and + phase gates (S, Sdg or Z). The synthesis algorithm is based on the paper of Maslov + and Yang, `arXiv:2210.16195 `__. + The algorithm accepts a binary invertible matrix ``mat_x`` representing the CX-circuit, a binary symmetric matrix ``mat_z`` representing the CZ-circuit, and returns a quantum circuit with 2-qubit depth of at most 5n computing the composition of the CX and CZ circuits. @@ -16,8 +18,8 @@ features: mat_z = np.array([[0, 1], [1, 0]]) qc = synth_cx_cz_depth_line_my(mat_x, mat_z) - This algorithm is now used by default in the Clifford synthesis algorithm - :func:`qiskit.synthesis.clifford.synth_clifford_depth_lnn` that optimizes 2-qubit depth + This function is now used by default in the Clifford synthesis algorithm + :func:`~qiskit.synthesis.synth_clifford_depth_lnn` that optimizes 2-qubit depth for LNN connectivity, improving the 2-qubit depth from 9n+4 to 7n+2. The clifford synthesis algorithm can be used as follows:: @@ -29,4 +31,4 @@ features: The above synthesis can be further improved as described in the paper by Maslov and Yang, using local optimization between 2-qubit layers. This improvement is left for follow-up - work. \ No newline at end of file + work. diff --git a/releasenotes/notes/0.25/dag-substitute-node-propagate-condition-898052b53edb1f17.yaml b/releasenotes/notes/0.25/dag-substitute-node-propagate-condition-898052b53edb1f17.yaml index d5dfd69f54aa..289bdd2a7e11 100644 --- a/releasenotes/notes/0.25/dag-substitute-node-propagate-condition-898052b53edb1f17.yaml +++ b/releasenotes/notes/0.25/dag-substitute-node-propagate-condition-898052b53edb1f17.yaml @@ -1,5 +1,5 @@ --- -features: +features_transpiler: - | :meth:`.DAGCircuit.substitute_node` gained a ``propagate_condition`` keyword argument that is analogous to the same argument in :meth:`~.DAGCircuit.substitute_node_with_dag`. Setting this diff --git a/releasenotes/notes/0.25/dagcircuit-separable-circuits-142853e69f530a16.yaml b/releasenotes/notes/0.25/dagcircuit-separable-circuits-142853e69f530a16.yaml index 2ddd5fbb2894..f522115ac1cd 100644 --- a/releasenotes/notes/0.25/dagcircuit-separable-circuits-142853e69f530a16.yaml +++ b/releasenotes/notes/0.25/dagcircuit-separable-circuits-142853e69f530a16.yaml @@ -1,10 +1,10 @@ --- -features: +features_transpiler: - | - Introduced a new method, :meth:`~.DAGCircuit.separable_circuits`, which returns a + Introduced a new method, :meth:`.DAGCircuit.separable_circuits`, which returns a list of :class:`.DAGCircuit` objects, one for each set of connected qubits which have no gates connecting them to another set. - Each :class:`~.DAGCircuit` instance returned by this method will contain the same - number of clbits as ``self``. This method will not return :class:`~.DAGCircuit` + Each :class:`.DAGCircuit` instance returned by this method will contain the same + number of clbits as ``self``. This method will not return :class:`.DAGCircuit` instances consisting solely of clbits. diff --git a/releasenotes/notes/0.25/deprecate-algorithms-7149dee2da586549.yaml b/releasenotes/notes/0.25/deprecate-algorithms-7149dee2da586549.yaml index 4edaefe8bb7c..8fec5c49a463 100644 --- a/releasenotes/notes/0.25/deprecate-algorithms-7149dee2da586549.yaml +++ b/releasenotes/notes/0.25/deprecate-algorithms-7149dee2da586549.yaml @@ -1,5 +1,5 @@ --- -deprecations: +deprecations_algorithms: - | The :mod:`qiskit.algorithms` module has been deprecated and will be removed in a future release. It has been superseded by a new standalone library @@ -7,11 +7,11 @@ deprecations: https://github.com/qiskit-community/qiskit-algorithms - The :mod:`qiskit.algorithms` will continue to work as before and bug fixes - will be made to module until its future removal, but active development + The :mod:`qiskit.algorithms` module will continue to work as before and bug fixes + will be made to it until its future removal, but active development of new features has moved to the new package. If you're relying on :mod:`qiskit.algorithms` you should update your - requirements to also include ``qiskit-algorithms`` and update the imports + Python requirements to also include ``qiskit-algorithms`` and update the imports from ``qiskit.algorithms`` to ``qiskit_algorithms``. Please note that this new package does not include already deprecated algorithms code, including ``opflow`` and ``QuantumInstance``-based algorithms. If you have not yet diff --git a/releasenotes/notes/0.25/deprecate-circuit-library-jupyter-629f927e8dd5cc22.yaml b/releasenotes/notes/0.25/deprecate-circuit-library-jupyter-629f927e8dd5cc22.yaml index 00a5a2487d20..3bb4559247b7 100644 --- a/releasenotes/notes/0.25/deprecate-circuit-library-jupyter-629f927e8dd5cc22.yaml +++ b/releasenotes/notes/0.25/deprecate-circuit-library-jupyter-629f927e8dd5cc22.yaml @@ -1,5 +1,5 @@ --- -deprecations: +deprecations_misc: - | The Jupyter magic ``%circuit_library_info`` and the objects in ``qiskit.tools.jupyter.library`` it calls in turn: @@ -10,5 +10,5 @@ deprecations: - ``circuit_digram_widget`` - ``circuit_library_widget`` - are deprecated and will be removed in Terra 0.27. These objects were only intended for use in + are deprecated and will be removed in a future release. These objects were only intended for use in the documentation build. They are no longer used there, so are no longer supported or maintained. diff --git a/releasenotes/notes/0.25/deprecate-complex-amp-41381bd9722bc878.yaml b/releasenotes/notes/0.25/deprecate-complex-amp-41381bd9722bc878.yaml index 23eadb7ff391..467f04fa384f 100644 --- a/releasenotes/notes/0.25/deprecate-complex-amp-41381bd9722bc878.yaml +++ b/releasenotes/notes/0.25/deprecate-complex-amp-41381bd9722bc878.yaml @@ -1,7 +1,7 @@ --- -deprecations: +deprecations_pulse: - | - Initializing a :class:`~qiskit.pulse.library.ScalableSymbolicPulse` with complex `amp` value is now deprecated. + Initializing a :class:`~qiskit.pulse.library.ScalableSymbolicPulse` with complex value for ``amp``. This change also affects the following library pulses: * :class:`~qiskit.pulse.library.Gaussian` @@ -9,8 +9,8 @@ deprecations: * :class:`~qiskit.pulse.library.Drag` * :class:`~qiskit.pulse.library.Constant` - Initializing them with complex `amp` is now deprecated as well. + Initializing ``amp`` for these with a complex value is now deprecated as well. - Instead, one should use two floats for the `amp` and `angle` parameters, where `amp` represents the + Instead, use two floats when specifying the ``amp`` and ``angle`` parameters, where ``amp`` represents the magnitude of the complex amplitude, and `angle` represents the angle of the complex amplitude. i.e. the - complex amplitude is given by `amp` * exp(1j * `angle`). + complex amplitude is given by :math:`\texttt{amp} \times \exp(i \times \texttt{angle})`. \ No newline at end of file diff --git a/releasenotes/notes/0.25/deprecate-get_vf2_call_limit-826e0f9212fb27b9.yaml b/releasenotes/notes/0.25/deprecate-get_vf2_call_limit-826e0f9212fb27b9.yaml index 686ffe004233..6c2deb871da6 100644 --- a/releasenotes/notes/0.25/deprecate-get_vf2_call_limit-826e0f9212fb27b9.yaml +++ b/releasenotes/notes/0.25/deprecate-get_vf2_call_limit-826e0f9212fb27b9.yaml @@ -1,5 +1,5 @@ --- -deprecations: +deprecations_transpiler: - | The function ``get_vf2_call_limit`` available via the module :mod:`qiskit.transpiler.preset_passmanagers.common` has been diff --git a/releasenotes/notes/0.25/deprecate-instruction-qasm-9380f721e7bdaf6b.yaml b/releasenotes/notes/0.25/deprecate-instruction-qasm-9380f721e7bdaf6b.yaml index cd15938e6c06..a115b84964b4 100644 --- a/releasenotes/notes/0.25/deprecate-instruction-qasm-9380f721e7bdaf6b.yaml +++ b/releasenotes/notes/0.25/deprecate-instruction-qasm-9380f721e7bdaf6b.yaml @@ -1,6 +1,11 @@ --- -deprecations: +deprecations_circuits: - | The method :meth:`~qiskit.circuit.Instruction.qasm` and all overriding methods of subclasses - of `:meth:`~qiskit.circuit.Instruction` are deprecated. There is no replacement for generating - an OpenQASM 2 string for an isolated instruction. + of `:class:~qiskit.circuit.Instruction` are deprecated. There is no replacement for generating + an OpenQASM2 string for an isolated instruction as typically + a single instruction object has insufficient context to completely + generate a valid OpenQASM2 string. If you're relying on this + method currently you'll have to instead rely on the OpenQASM2 + exporter: :meth:`.QuantumCircuit.qasm` to generate the OpenQASM2 + for an entire circuit object. diff --git a/releasenotes/notes/0.25/deprecate-pulse-Call-instruction-538802d8fad7e257.yaml b/releasenotes/notes/0.25/deprecate-pulse-Call-instruction-538802d8fad7e257.yaml index 6ed28e8e6a9d..a46a30f20719 100644 --- a/releasenotes/notes/0.25/deprecate-pulse-Call-instruction-538802d8fad7e257.yaml +++ b/releasenotes/notes/0.25/deprecate-pulse-Call-instruction-538802d8fad7e257.yaml @@ -1,9 +1,7 @@ --- -deprecations: +deprecations_pulse: - | - The :class:`~qiskit.pulse.instructions.Call` has been deprecated and will + The :class:`~qiskit.pulse.instructions.Call` instruction has been deprecated and will be removed in a future release. - Instead, use the `pulse builder - `_ - function :func:`~qiskit.pulse.builder.call` - within an active building context. + Instead, use function :func:`~qiskit.pulse.builder.call` from module + :mod:`qiskit.pulse.builder` within an active building context. diff --git a/releasenotes/notes/0.25/discrete-pulse-library-deprecation-3a95eba7e29d8d49.yaml b/releasenotes/notes/0.25/discrete-pulse-library-deprecation-3a95eba7e29d8d49.yaml index 37c776060d89..eb6a36bb16e1 100644 --- a/releasenotes/notes/0.25/discrete-pulse-library-deprecation-3a95eba7e29d8d49.yaml +++ b/releasenotes/notes/0.25/discrete-pulse-library-deprecation-3a95eba7e29d8d49.yaml @@ -1,14 +1,16 @@ --- -features: +features_pulse: - | - The :class:`~qiskit.pulse.SymbolicPulse` library was extended. The new pulses in the library are: + + The :class:`~qiskit.pulse.library.SymbolicPulse` library was extended. The new pulse functions + in the library are: * :func:`~qiskit.pulse.library.GaussianDeriv` * :func:`~qiskit.pulse.library.Sech` * :func:`~qiskit.pulse.library.SechDeriv` * :func:`~qiskit.pulse.library.Square` - The new functions return a :class:`ScalableSymbolicPulse`, and match the functionality + The new functions return a :class:`~qiskit.pulse.library.ScalableSymbolicPulse` instance, and match the functionality of the corresponding functions in the discrete pulse library, with the exception of - `Square()` for which a phase of :math:`2\\pi` shifts by a full cycle (contrary to the - discrete `square()` where such a shift was induced by a :math:`\\pi` phase). + :func:`~qiskit.pulse.library.Square` for which a phase of :math:`2\pi` shifts by a full cycle (contrary to the + discrete :func:`~qiskit.pulse.library.square` where such a shift was induced by a :math:`\pi` phase). diff --git a/releasenotes/notes/0.25/display-control-flow-mpl-drawer-2dbc7b57ac52d138.yaml b/releasenotes/notes/0.25/display-control-flow-mpl-drawer-2dbc7b57ac52d138.yaml index 825dcdd63bfb..4d25c4abe325 100644 --- a/releasenotes/notes/0.25/display-control-flow-mpl-drawer-2dbc7b57ac52d138.yaml +++ b/releasenotes/notes/0.25/display-control-flow-mpl-drawer-2dbc7b57ac52d138.yaml @@ -1,9 +1,8 @@ --- -features: +features_visualization: - | - In :class:`~qiskit.visualization.circuit.MatplotlibDrawer`, operations - built from :class:`~qiskit.circuit.ControlFlowOp`, including - ``if``, ``else``, ``while``, ``for``, and ``switch/case``, whether - directly instantiated or built using methods in :class:`~qiskit.circuit.QuantumCircuit`, - will now fully display the circuits defined in the ControlFlowOps wrapped - with boxes to delineate the circuits. + :meth:`.QuantumCircuit.draw` and function :func:`~qiskit.visualization.circuit_drawer` + when using option ``output='mpl'`` now support drawing the nested circuit blocks of + :class:`~qiskit.circuit.ControlFlowOp` operations, including + ``if``, ``else``, ``while``, ``for``, and ``switch/case``. Circuit blocks are + wrapped with boxes to delineate the circuits. diff --git a/releasenotes/notes/0.25/enable_target_aware_meas_map-0d8542402a74e9d8.yaml b/releasenotes/notes/0.25/enable_target_aware_meas_map-0d8542402a74e9d8.yaml index b0bb3df33f94..e517a0786181 100644 --- a/releasenotes/notes/0.25/enable_target_aware_meas_map-0d8542402a74e9d8.yaml +++ b/releasenotes/notes/0.25/enable_target_aware_meas_map-0d8542402a74e9d8.yaml @@ -1,16 +1,17 @@ --- -features: +features_transpiler: - | - Added :attr:`~.Target.concurrent_measurements` which represents a hardware constraint of qubits - measured concurrently. This constraint is provided in the nested list form, - in which each element represents qubit group to be measured together. - In an example below, - - .. code-block:: python + Added the attribute :attr:`.Target.concurrent_measurements` which represents a hardware + constraint of qubits measured concurrently. This constraint is provided in a nested list form, + in which each element represents a qubit group to be measured together. + In an example below:: [[0, 1], [2, 3, 4]] qubits 0 and 1, and 2, 3 and 4 are measured together on the device. - This constraint doesn't block measuring an individual qubit, - however, Qiskit scheduler must consider the alignment of - measure operations for those qubits. \ No newline at end of file + This constraint doesn't block measuring an individual qubit, but you may + need to consider the alignment of measure operations for these qubits when + working with the + `Qiskit Pulse scheduler `__ + and when authoring new transpiler passes that are timing-aware (i.e. passes + that perform scheduling). diff --git a/releasenotes/notes/0.25/faster-parameter-rebind-3c799e74456469d9.yaml b/releasenotes/notes/0.25/faster-parameter-rebind-3c799e74456469d9.yaml index c8f7e3ddd8c2..3ba7eab75ecd 100644 --- a/releasenotes/notes/0.25/faster-parameter-rebind-3c799e74456469d9.yaml +++ b/releasenotes/notes/0.25/faster-parameter-rebind-3c799e74456469d9.yaml @@ -1,5 +1,5 @@ --- -features: +features_circuits: - | The performance of :meth:`.QuantumCircuit.assign_parameters` and :meth:`~.QuantumCircuit.bind_parameters` has significantly increased for large circuits with structures typical of applications uses. diff --git a/releasenotes/notes/0.25/filter-schedule-block-29d392ca351f1fb1.yaml b/releasenotes/notes/0.25/filter-schedule-block-29d392ca351f1fb1.yaml index b49dd1a2a8c4..58b09678063d 100644 --- a/releasenotes/notes/0.25/filter-schedule-block-29d392ca351f1fb1.yaml +++ b/releasenotes/notes/0.25/filter-schedule-block-29d392ca351f1fb1.yaml @@ -1,9 +1,9 @@ --- -features: +features_pulse: - | The method :meth:`~qiskit.pulse.schedule.ScheduleBlock.filter` is activated in the :class:`~qiskit.pulse.schedule.ScheduleBlock` class. - This method enables users to retain only :class:`~qiskit.pulse.Instruction` + This method enables users to retain only :class:`~qiskit.pulse.instructions.Instruction` objects which pass through all the provided filters. As builtin filter conditions, pulse :class:`~qiskit.pulse.channels.Channel` subclass instance and :class:`~qiskit.pulse.instructions.Instruction` @@ -13,7 +13,7 @@ features: - | The method :meth:`~qiskit.pulse.schedule.ScheduleBlock.exclude` is activated in the :class:`~qiskit.pulse.schedule.ScheduleBlock` class. - This method enables users to retain only :class:`~qiskit.pulse.Instruction` + This method enables users to retain only :class:`~qiskit.pulse.instructions.Instruction` objects which do not pass at least one of all the provided filters. As builtin filter conditions, pulse :class:`~qiskit.pulse.channels.Channel` subclass instance and :class:`~qiskit.pulse.instructions.Instruction` diff --git a/releasenotes/notes/0.25/fix-1q-matrix-bug-in-quantum-shannon-decomposer-c99ce6509f03715b.yaml b/releasenotes/notes/0.25/fix-1q-matrix-bug-in-quantum-shannon-decomposer-c99ce6509f03715b.yaml deleted file mode 100644 index d68d20c89e24..000000000000 --- a/releasenotes/notes/0.25/fix-1q-matrix-bug-in-quantum-shannon-decomposer-c99ce6509f03715b.yaml +++ /dev/null @@ -1,7 +0,0 @@ ---- -fixes: - - | - When :func:`~qiskit.quantum_info.synthesis.qs_decomposition`, which does quantum Shannon - decomposition, was called on trivial numeric unitaries that do not benefit from this - decomposition, an unexpected error was raised. With this fix, such unitaries are detected and - the equivalent circuit is returned without performing Shannon decomposition. diff --git a/releasenotes/notes/0.25/fix-basicswap-fakerun-7469835327f6c8a1.yaml b/releasenotes/notes/0.25/fix-basicswap-fakerun-7469835327f6c8a1.yaml deleted file mode 100644 index c740479e2889..000000000000 --- a/releasenotes/notes/0.25/fix-basicswap-fakerun-7469835327f6c8a1.yaml +++ /dev/null @@ -1,4 +0,0 @@ -fixes: - - | - Fixes a typo where BasicSwap called ``fake_run()`` the attribute instead of ``_fake_run()`` the function. - Refer to `#10149 ` for more details. diff --git a/releasenotes/notes/0.25/fix-bit-copy-4b2f7349683f616a.yaml b/releasenotes/notes/0.25/fix-bit-copy-4b2f7349683f616a.yaml deleted file mode 100644 index 41d76acdb609..000000000000 --- a/releasenotes/notes/0.25/fix-bit-copy-4b2f7349683f616a.yaml +++ /dev/null @@ -1,7 +0,0 @@ ---- -fixes: - - | - Fixed an issue with copying circuits with new-style :class:`.Clbit`\ s and - :class:`.Qubit`\ s (bits without registers) where references to these bits - from the containing circuit could be broken, causing issues with - serialization and circuit visualization. diff --git a/releasenotes/notes/0.25/fix-checkmap-nested-condition-1776f952f6c6722a.yaml b/releasenotes/notes/0.25/fix-checkmap-nested-condition-1776f952f6c6722a.yaml deleted file mode 100644 index 0805524cd7b0..000000000000 --- a/releasenotes/notes/0.25/fix-checkmap-nested-condition-1776f952f6c6722a.yaml +++ /dev/null @@ -1,6 +0,0 @@ ---- -fixes: - - | - The :class:`.CheckMap` transpiler pass will no longer spuriously error when dealing with nested - conditional structures created by the control-flow builder interface. See `#10394 - `__. diff --git a/releasenotes/notes/0.25/fix-collapse-with-clbits-e14766353303d442.yaml b/releasenotes/notes/0.25/fix-collapse-with-clbits-e14766353303d442.yaml deleted file mode 100644 index ef3e073e28af..000000000000 --- a/releasenotes/notes/0.25/fix-collapse-with-clbits-e14766353303d442.yaml +++ /dev/null @@ -1,9 +0,0 @@ ---- -fixes: - - | - Fixed a bug in :class:`~BlockCollapser` where classical bits were ignored when collapsing - a block of nodes. - - | - Fixed a bug in :meth:`~qiskit.dagcircuit.DAGCircuit.replace_block_with_op` and - :meth:`~qiskit.dagcircuit.DAGDependency.replace_block_with_op` - that led to ignoring classical bits. diff --git a/releasenotes/notes/0.25/fix-compose-switch-19ada3828d939353.yaml b/releasenotes/notes/0.25/fix-compose-switch-19ada3828d939353.yaml deleted file mode 100644 index da83aafe33c7..000000000000 --- a/releasenotes/notes/0.25/fix-compose-switch-19ada3828d939353.yaml +++ /dev/null @@ -1,5 +0,0 @@ ---- -fixes: - - | - Fixed a bug in :meth:`.QuantumCircuit.compose` where the :attr:`.SwitchCaseOp.target` attribute - in the subcircuit would not get mapped to a register in the base circuit correctly. diff --git a/releasenotes/notes/0.25/fix-decompose-name-f83f5e4e64918aa9.yaml b/releasenotes/notes/0.25/fix-decompose-name-f83f5e4e64918aa9.yaml index 54810d35afdf..9243022001b5 100644 --- a/releasenotes/notes/0.25/fix-decompose-name-f83f5e4e64918aa9.yaml +++ b/releasenotes/notes/0.25/fix-decompose-name-f83f5e4e64918aa9.yaml @@ -1,7 +1,7 @@ --- fixes: - | - Fixed an issue in the :func:`.QuantumCircuit.decompose` method + Fixed an issue in :meth:`.QuantumCircuit.decompose` where passing a circuit name to the function that matched a composite gate name would not decompose the gate if it had a label assigned to it as well. diff --git a/releasenotes/notes/0.25/fix-delay-padding-75937bda37ebc3fd.yaml b/releasenotes/notes/0.25/fix-delay-padding-75937bda37ebc3fd.yaml deleted file mode 100644 index 34c42ab5baf8..000000000000 --- a/releasenotes/notes/0.25/fix-delay-padding-75937bda37ebc3fd.yaml +++ /dev/null @@ -1,13 +0,0 @@ ---- -fixes: - - | - Fixed an issue in tranpiler passes for padding delays, which did not respect target's constraints - and inserted delays even for qubits not supporting :class:`~.circuit.Delay` instruction. - :class:`~.PadDelay` and :class:`~.PadDynamicalDecoupling` are fixed - so that they do not pad any idle time of qubits such that the target does not support - ``Delay`` instructions for the qubits. - Also legacy scheduling passes ``ASAPSchedule`` and ``ALAPSchedule``, - which pad delays internally, are fixed in the same way. - In addition, :func:`transpile` is fixed to call ``PadDelay`` with a ``target`` object - so that it works correctly when called with ``scheduling_method`` option. - Fixed `#9993 `__ diff --git a/releasenotes/notes/0.25/fix-dispatching-backends-28aff96f726ca9c5.yaml b/releasenotes/notes/0.25/fix-dispatching-backends-28aff96f726ca9c5.yaml deleted file mode 100644 index 5ab5aee5bc51..000000000000 --- a/releasenotes/notes/0.25/fix-dispatching-backends-28aff96f726ca9c5.yaml +++ /dev/null @@ -1,4 +0,0 @@ ---- -fixes: - - | - Fixed an failure of the pulse builder when the context is initialized with :class:`.BackendV2`. diff --git a/releasenotes/notes/0.25/fix-exception-decription-3ba0b5db82c576cf.yaml b/releasenotes/notes/0.25/fix-exception-decription-3ba0b5db82c576cf.yaml deleted file mode 100644 index 5733e1c85287..000000000000 --- a/releasenotes/notes/0.25/fix-exception-decription-3ba0b5db82c576cf.yaml +++ /dev/null @@ -1,4 +0,0 @@ ---- -fixes: - - Fix a bug in :class:`~.RZXCalibrationBuilder` where calling calibration with wrong parameters - would crash instead of raising exception. diff --git a/releasenotes/notes/0.25/fix-exception-from_dimacs_file-b9338f3c913a9bff.yaml b/releasenotes/notes/0.25/fix-exception-from_dimacs_file-b9338f3c913a9bff.yaml deleted file mode 100644 index b7f2d34d5cda..000000000000 --- a/releasenotes/notes/0.25/fix-exception-from_dimacs_file-b9338f3c913a9bff.yaml +++ /dev/null @@ -1,7 +0,0 @@ ---- -fixes: - - | - Fixed an issue with the :meth:`.BooleanExpression.from_dimacs_file` - constructor method where the exception type raised when tweedledum wasn't - installed was not the expected :class:`~.MissingOptionalLibrary`. - Fixed `#10079 `__ diff --git a/releasenotes/notes/0.25/fix-initial_layout-loose-qubits-0c59b2d6fb99d7e6.yaml b/releasenotes/notes/0.25/fix-initial_layout-loose-qubits-0c59b2d6fb99d7e6.yaml deleted file mode 100644 index 4bac5214f5c6..000000000000 --- a/releasenotes/notes/0.25/fix-initial_layout-loose-qubits-0c59b2d6fb99d7e6.yaml +++ /dev/null @@ -1,6 +0,0 @@ ---- -fixes: - - | - Using ``initial_layout`` in calls to :func:`.transpile` will no longer error if the - circuit contains qubits not in any registers, or qubits that exist in more than one - register. See `#10125 `__. diff --git a/releasenotes/notes/0.25/fix-mcrz-relative-phase-6ea81a369f8bda38.yaml b/releasenotes/notes/0.25/fix-mcrz-relative-phase-6ea81a369f8bda38.yaml deleted file mode 100644 index aa89abeb662d..000000000000 --- a/releasenotes/notes/0.25/fix-mcrz-relative-phase-6ea81a369f8bda38.yaml +++ /dev/null @@ -1,7 +0,0 @@ ---- -fixes: - - | - Fixed the gate decomposition of multi-controlled Z rotation gates added via - :meth:`.QuantumCircuit.mcrz`. Previously, this method implemented a multi-controlled - phase gate, which has a relative phase difference to the Z rotation. To obtain the - previous `.QuantumCircuit.mcrz` behaviour, use `.QuantumCircuit.mcp`. diff --git a/releasenotes/notes/0.25/fix-outputs-of-measure_v2-8959ebbbf5f87294.yaml b/releasenotes/notes/0.25/fix-outputs-of-measure_v2-8959ebbbf5f87294.yaml deleted file mode 100644 index 0699d854a1de..000000000000 --- a/releasenotes/notes/0.25/fix-outputs-of-measure_v2-8959ebbbf5f87294.yaml +++ /dev/null @@ -1,7 +0,0 @@ ---- -fixes: - - | - Fixed the output of pulse :func:`~qiskit.pulse.macros.measure` and - :func:`~qiskit.pulse.macros.measure_all` when functions are called - with the :class:`.BackendV2` backend. - diff --git a/releasenotes/notes/0.25/fix-partial-transpose-output-dims-3082fcf4147055dc.yaml b/releasenotes/notes/0.25/fix-partial-transpose-output-dims-3082fcf4147055dc.yaml deleted file mode 100644 index edba41333ce8..000000000000 --- a/releasenotes/notes/0.25/fix-partial-transpose-output-dims-3082fcf4147055dc.yaml +++ /dev/null @@ -1,5 +0,0 @@ ---- -fixes: - - | - Fixed the dimensions of the output density matrix from :meth:`.DensityMatrix.partial_transpose` - so they match the dimensions of the corresponding input density matrix. diff --git a/releasenotes/notes/0.25/fix-plot-legend-not-showing-up-3202bec143529e49.yaml b/releasenotes/notes/0.25/fix-plot-legend-not-showing-up-3202bec143529e49.yaml index 375aab340dcb..213736c9f6b0 100644 --- a/releasenotes/notes/0.25/fix-plot-legend-not-showing-up-3202bec143529e49.yaml +++ b/releasenotes/notes/0.25/fix-plot-legend-not-showing-up-3202bec143529e49.yaml @@ -1,6 +1,6 @@ --- fixes: - | - Fixed plot legend error when your dataset has a zero value at first position. - When one of your counts or distributions had a zero value at first position, the relative legend didn't show up. - See `#10158 ` for more details. + Fixed an issue with :func:`qiskit.visualization.plot_histogram` where the relative legend + did not show up when the given dataset had a zero value in the first position. + See `#10158 `__ for more details. diff --git a/releasenotes/notes/0.25/fix-pm-config-from-backend-f3b71b11858b4f08.yaml b/releasenotes/notes/0.25/fix-pm-config-from-backend-f3b71b11858b4f08.yaml deleted file mode 100644 index c85355478f06..000000000000 --- a/releasenotes/notes/0.25/fix-pm-config-from-backend-f3b71b11858b4f08.yaml +++ /dev/null @@ -1,9 +0,0 @@ ---- -fixes: - - | - Fixed an issue with the :meth:`.PassManagerConfig.from_backend` constructor - when building a :class:`~.PassManagerConfig` object from a :class:`~.BackendV1` - instance that didn't have a coupling map attribute defined. Previously, the - constructor would incorrectly create a :class:`~.CouplingMap` object with - 0 qubits instead of using ``None``. - Fixed `#10171 `__ diff --git a/releasenotes/notes/0.25/fix-primitives-import-warnings-439e3e237fdb9d7b.yaml b/releasenotes/notes/0.25/fix-primitives-import-warnings-439e3e237fdb9d7b.yaml deleted file mode 100644 index f3827cca160c..000000000000 --- a/releasenotes/notes/0.25/fix-primitives-import-warnings-439e3e237fdb9d7b.yaml +++ /dev/null @@ -1,7 +0,0 @@ ---- -fixes: - - | - Importing :mod:`qiskit.primitives` will no longer cause deprecation warnings stemming from the - deprecated :mod:`qiskit.opflow` module. These warnings would have been hidden to users by the - default Python filters, but triggered the eager import of :mod:`.opflow`, which meant that a - subsequent import by a user would not trigger the warnings. diff --git a/releasenotes/notes/0.25/fix-qasm-circuit-export-943394536bc0d292.yaml b/releasenotes/notes/0.25/fix-qasm-circuit-export-943394536bc0d292.yaml deleted file mode 100644 index fdbf087deef3..000000000000 --- a/releasenotes/notes/0.25/fix-qasm-circuit-export-943394536bc0d292.yaml +++ /dev/null @@ -1,7 +0,0 @@ ---- -fixes: - - | - Fixed the OpenQASM 2 output of :meth:`.QuantumCircuit.qasm` when a custom gate object contained - a gate with the same name. Ideally this shouldn't happen for most gates, but complex algorithmic - operations like the :class:`.GroverOperator` class could produce such structures accidentally. - See `#10162 `__. diff --git a/releasenotes/notes/0.25/fix-regression-in-the-LaTeX-drawer-of-QuantumCircuit-7dd3e84e1dea1abd.yaml b/releasenotes/notes/0.25/fix-regression-in-the-LaTeX-drawer-of-QuantumCircuit-7dd3e84e1dea1abd.yaml deleted file mode 100644 index fdeec4027e2c..000000000000 --- a/releasenotes/notes/0.25/fix-regression-in-the-LaTeX-drawer-of-QuantumCircuit-7dd3e84e1dea1abd.yaml +++ /dev/null @@ -1,8 +0,0 @@ - -fixes: - - | - Fixed a regression in the LaTeX drawer of :meth:`.QuantumCircuit.draw` - when temporary files are placed on a separate filesystem to the working - directory. See - `#10211 `__. - diff --git a/releasenotes/notes/0.25/fix-synth-fail-with-symbolic-angles-a070b9973a16b8c3.yaml b/releasenotes/notes/0.25/fix-synth-fail-with-symbolic-angles-a070b9973a16b8c3.yaml deleted file mode 100644 index a58af12280b2..000000000000 --- a/releasenotes/notes/0.25/fix-synth-fail-with-symbolic-angles-a070b9973a16b8c3.yaml +++ /dev/null @@ -1,6 +0,0 @@ ---- -fixes: - - | - Fixes a bug introduced in Qiskit 0.24.0 where numeric rotation angles were no longer substituted - for symbolic ones before preparing for two-qubit synthesis. This caused an exception to be - raised because the synthesis routines require numberic matrices. diff --git a/releasenotes/notes/0.25/fix-synthesis-cf-mapping-fe9bd2e5fbd56dfb.yaml b/releasenotes/notes/0.25/fix-synthesis-cf-mapping-fe9bd2e5fbd56dfb.yaml deleted file mode 100644 index c713facfd8fd..000000000000 --- a/releasenotes/notes/0.25/fix-synthesis-cf-mapping-fe9bd2e5fbd56dfb.yaml +++ /dev/null @@ -1,6 +0,0 @@ ---- -fixes: - - | - Fixed an issue with :class:`.UnitarySynthesis` when using the ``target`` - parameter where circuits with control flow were not properly mapped - to the target. diff --git a/releasenotes/notes/0.25/fix-transpile-pickle-4045805b67c0c11b.yaml b/releasenotes/notes/0.25/fix-transpile-pickle-4045805b67c0c11b.yaml deleted file mode 100644 index 7160cb7f9376..000000000000 --- a/releasenotes/notes/0.25/fix-transpile-pickle-4045805b67c0c11b.yaml +++ /dev/null @@ -1,5 +0,0 @@ ---- -fixes: - - Fix a bug in which running :class:`~.Optimize1qGatesDecomposition` - in parallel would raise an error due to OneQubitGateErrorMap - not being picklable. \ No newline at end of file diff --git a/releasenotes/notes/0.25/fix-update-from-instruction-schedule-map-d1cba4e4db4b679e.yaml b/releasenotes/notes/0.25/fix-update-from-instruction-schedule-map-d1cba4e4db4b679e.yaml index e651138a3264..397a49bf1b17 100644 --- a/releasenotes/notes/0.25/fix-update-from-instruction-schedule-map-d1cba4e4db4b679e.yaml +++ b/releasenotes/notes/0.25/fix-update-from-instruction-schedule-map-d1cba4e4db4b679e.yaml @@ -1,6 +1,7 @@ --- fixes: - | - Fixed an failure of :meth:`.Target.update_from_instruction_schedule_map` when - the argument ``inst_map`` has schedule with unassigned duration. + Fixed a failure with method :meth:`.Target.update_from_instruction_schedule_map` + triggered by the given ``inst_map`` containing a :class:`~qiskit.pulse.Schedule` + with unassigned durations. diff --git a/releasenotes/notes/0.25/fix-vf2-scoring-1q-e2ac29075831d64d.yaml b/releasenotes/notes/0.25/fix-vf2-scoring-1q-e2ac29075831d64d.yaml deleted file mode 100644 index b2901ede4489..000000000000 --- a/releasenotes/notes/0.25/fix-vf2-scoring-1q-e2ac29075831d64d.yaml +++ /dev/null @@ -1,6 +0,0 @@ ---- -fixes: - - | - Fix a bug in the :class:`~.VF2Layout` and :class:`~.VF2PostLayout` passes - where the passes wer failing to account for the 1 qubit error component when - evaluating a potential layout. diff --git a/releasenotes/notes/0.25/fix-vqd-result-27b26f0a6d49e7c7.yaml b/releasenotes/notes/0.25/fix-vqd-result-27b26f0a6d49e7c7.yaml deleted file mode 100644 index 8b2854c36da0..000000000000 --- a/releasenotes/notes/0.25/fix-vqd-result-27b26f0a6d49e7c7.yaml +++ /dev/null @@ -1,5 +0,0 @@ ---- -fixes: - - | - Fixed bug in :class:`~qiskit.algorithms.eigensolvers.VQD` where ``result.optimal_values`` was a - copy of ``result.optimal_points``. It now returns the corresponding values. diff --git a/releasenotes/notes/0.25/fix_9016-2e8bc2cb10b5e204.yaml b/releasenotes/notes/0.25/fix_9016-2e8bc2cb10b5e204.yaml index 890223e82b8c..ebb1398b9812 100644 --- a/releasenotes/notes/0.25/fix_9016-2e8bc2cb10b5e204.yaml +++ b/releasenotes/notes/0.25/fix_9016-2e8bc2cb10b5e204.yaml @@ -1,7 +1,8 @@ --- fixes: - | - When the parameter ``conditional=True`` is set in - ``qiskit.circuit.random.random_circuit``, the conditional operations will - be preceded by a full mid-circuit measurment. + When the parameter ``conditional=True`` is specified in + :func:`~qiskit.circuit.random.random_circuit`, conditional operations + in the resulting circuit will + now be preceded by a full mid-circuit measurment. Fixes `#9016 `__ diff --git a/releasenotes/notes/0.25/fixes_8060-ae91e0da9d53a288.yaml b/releasenotes/notes/0.25/fixes_8060-ae91e0da9d53a288.yaml index d04ccf203a3b..22418f6b30a1 100644 --- a/releasenotes/notes/0.25/fixes_8060-ae91e0da9d53a288.yaml +++ b/releasenotes/notes/0.25/fixes_8060-ae91e0da9d53a288.yaml @@ -1,4 +1,8 @@ --- -features: +features_transpiler: - | - The transpiler pass :class:`SetLayout` now is able to be constructed with a list of integers that represent the physical qubits on which the quantum circuit will be mapped on. That is, the first qubit in the circuit will be allocated in the physical qubit in the position zero of the list, and so on. + The transpiler pass :class:`~qiskit.transpiler.passes.SetLayout` can now + be constructed with a list of integers that represent the physical qubits + on which the quantum circuit will be mapped on. That is, the first qubit + in the circuit will be allocated to the physical qubit in position zero + of the list, and so on. diff --git a/releasenotes/notes/0.25/flatten-nlocal-family-292b23b99947f3c9.yaml b/releasenotes/notes/0.25/flatten-nlocal-family-292b23b99947f3c9.yaml index ebb699e8c7b1..c3f0d9dad537 100644 --- a/releasenotes/notes/0.25/flatten-nlocal-family-292b23b99947f3c9.yaml +++ b/releasenotes/notes/0.25/flatten-nlocal-family-292b23b99947f3c9.yaml @@ -1,5 +1,5 @@ --- -features: +features_circuits: - | Added a new keyword argument ``flatten`` to the constructor for the following classes: diff --git a/releasenotes/notes/0.25/gaussian-square-echo-pulse-84306f1a02e2bb28.yaml b/releasenotes/notes/0.25/gaussian-square-echo-pulse-84306f1a02e2bb28.yaml index b733f6ba6228..6e0a7849c628 100644 --- a/releasenotes/notes/0.25/gaussian-square-echo-pulse-84306f1a02e2bb28.yaml +++ b/releasenotes/notes/0.25/gaussian-square-echo-pulse-84306f1a02e2bb28.yaml @@ -1,9 +1,10 @@ --- -features: +features_pulse: - | - Add new :meth:`~qiskit.pulse.gaussian_square_echo` pulse shape. This pulse - is composed by three :class:`~qiskit.pulse.GaussianSquare` pulses. The + Added a new function :func:`~qiskit.pulse.library.gaussian_square_echo` to the + pulse library. The returned pulse + is composed of three :class:`~qiskit.pulse.library.GaussianSquare` pulses. The first two are echo pulses with duration half of the total duration and implement rotary tones. The third pulse is a cancellation tone that lasts the full duration of the pulse and implements correcting single qubit - rotations. \ No newline at end of file + rotations. diff --git a/releasenotes/notes/0.25/has-pygments-tester-3fb9f9c34907d45d.yaml b/releasenotes/notes/0.25/has-pygments-tester-3fb9f9c34907d45d.yaml index e82fe1f32216..ebdf3ae70382 100644 --- a/releasenotes/notes/0.25/has-pygments-tester-3fb9f9c34907d45d.yaml +++ b/releasenotes/notes/0.25/has-pygments-tester-3fb9f9c34907d45d.yaml @@ -1,5 +1,5 @@ --- -features: +features_misc: - | A new lazy import tester, :data:`.HAS_PYGMENTS`, is available for testing for the presence of `the Pygments syntax highlighting library `__. diff --git a/releasenotes/notes/0.25/improve-quantum-circuit-assign-parameters-typing-70c9623405cbd420.yaml b/releasenotes/notes/0.25/improve-quantum-circuit-assign-parameters-typing-70c9623405cbd420.yaml index 7804a518c30d..2abf5ca9b958 100644 --- a/releasenotes/notes/0.25/improve-quantum-circuit-assign-parameters-typing-70c9623405cbd420.yaml +++ b/releasenotes/notes/0.25/improve-quantum-circuit-assign-parameters-typing-70c9623405cbd420.yaml @@ -1,7 +1,7 @@ --- fixes: - | - Improve the type annotations on the + Improved the type annotations on the :meth:`.QuantumCircuit.assign_parameters` method to reflect the change in return type depending on the ``inplace`` argument. diff --git a/releasenotes/notes/0.25/linear-functions-usability-45265f293a80a6e5.yaml b/releasenotes/notes/0.25/linear-functions-usability-45265f293a80a6e5.yaml index ffffff32f169..3620b0e567a6 100644 --- a/releasenotes/notes/0.25/linear-functions-usability-45265f293a80a6e5.yaml +++ b/releasenotes/notes/0.25/linear-functions-usability-45265f293a80a6e5.yaml @@ -1,10 +1,10 @@ --- -features: +features_circuits: - | - Allowing to construct a :class:`.LinearFunction` object from more general quantum circuits, + Added support for constructing :class:`.LinearFunction`\ s from more general quantum circuits, that may contain: - * Barriers (of type :class:`~qiskit.circuit.Barrier`) and delays (:class:`~qiskit.circuit.Delay`), + * Barriers (of type :class:`.Barrier`) and delays (:class:`~qiskit.circuit.Delay`), which are simply ignored * Permutations (of type :class:`~qiskit.circuit.library.PermutationGate`) * Other linear functions diff --git a/releasenotes/notes/0.25/new-circuit-qasm2-methods-b1a06ee2859e2cce.yaml b/releasenotes/notes/0.25/new-circuit-qasm2-methods-b1a06ee2859e2cce.yaml index 36b4cba14f16..e7f0a0ce1f09 100644 --- a/releasenotes/notes/0.25/new-circuit-qasm2-methods-b1a06ee2859e2cce.yaml +++ b/releasenotes/notes/0.25/new-circuit-qasm2-methods-b1a06ee2859e2cce.yaml @@ -1,5 +1,16 @@ --- -upgrade: +upgrade_circuits: + - | + The OpenQASM 2 constructor methods on :class:`.QuantumCircuit` + (:meth:`~.QuantumCircuit.from_qasm_str` and :meth:`~.QuantumCircuit.from_qasm_file`) have been + switched to use the Rust-based parser added in Qiskit Terra 0.24. This should result in + significantly faster parsing times (10 times or more is not uncommon) and massively reduced + intermediate memory usage. + + The :class:`.QuantumCircuit` methods are kept with the same interface for continuity; the + preferred way to access the OpenQASM 2 importer is to use :func:`.qasm2.load` and + :func:`.qasm2.loads`, which offer an expanded interface to control the parsing and construction. +upgrade_qasm: - | The OpenQASM 2 constructor methods on :class:`.QuantumCircuit` (:meth:`~.QuantumCircuit.from_qasm_str` and :meth:`~.QuantumCircuit.from_qasm_file`) have been diff --git a/releasenotes/notes/0.25/normalize-stateprep-e21972dce8695509.yaml b/releasenotes/notes/0.25/normalize-stateprep-e21972dce8695509.yaml index e460b6e55ee1..5cc9d3904e2b 100644 --- a/releasenotes/notes/0.25/normalize-stateprep-e21972dce8695509.yaml +++ b/releasenotes/notes/0.25/normalize-stateprep-e21972dce8695509.yaml @@ -1,5 +1,5 @@ --- -features: +features_circuits: - | The instructions :class:`.StatePreparation` and :class:`~.extensions.Initialize`, and their associated circuit methods :meth:`.QuantumCircuit.prepare_state` and :meth:`~.QuantumCircuit.initialize`, diff --git a/releasenotes/notes/0.25/optimize-consolidate-blocks-3ea60c18bc546273.yaml b/releasenotes/notes/0.25/optimize-consolidate-blocks-3ea60c18bc546273.yaml index 9bb8216bd981..a4d1d7cfe764 100644 --- a/releasenotes/notes/0.25/optimize-consolidate-blocks-3ea60c18bc546273.yaml +++ b/releasenotes/notes/0.25/optimize-consolidate-blocks-3ea60c18bc546273.yaml @@ -1,14 +1,9 @@ --- -features: - - | - Added utility function :func:`qiskit.transpiler.passes.utils._block_to_matrix` that can - generate a matrix based on a block of operations between two qubits. This function can - be used in transpiler passes that work on some decomposed circuits such as :class:`.ConsolidateBlocks`. fixes: - | Reduced overhead of the :class:`.ConsolidateBlocks` pass by performing matrix operations - on all two-qubit blocks using :func:`qiskit.transpiler.passes.utils._block_to_matrix` - instead of creating an instance of :class:`.QuantumCircuit` and passing it to an :class:`.Operator`. + on all two-qubit blocks instead of creating an instance of :class:`.QuantumCircuit` and + passing it to an :class:`.Operator`. The speedup will only be applicable when consolidating two-qubit blocks. Anything higher than that will still be handled by the :class:`.Operator` class. Check `#8779 `__ for details. diff --git a/releasenotes/notes/0.25/parameter-float-cast-48f3731fec5e47cd.yaml b/releasenotes/notes/0.25/parameter-float-cast-48f3731fec5e47cd.yaml deleted file mode 100644 index 9f9aef5aac76..000000000000 --- a/releasenotes/notes/0.25/parameter-float-cast-48f3731fec5e47cd.yaml +++ /dev/null @@ -1,13 +0,0 @@ ---- -fixes: - - | - Improved the error messages returned when an attempt to convert a fully bound - :class:`.ParameterExpression` into a concrete ``float`` or ``int`` failed, for example because - the expression was naturally a complex number. - - | - Fixed ``float`` conversions for :class:`.ParameterExpression` values which had, at some point in - their construction history, an imaginary component that had subsequently been cancelled. When - using Sympy as a backend, these conversions would usually already have worked. When using - Symengine as the backend, these conversions would often fail with type errors, despite the - result having been symbolically evaluated to be real, and :meth:`.ParameterExpression.is_real` - being true. diff --git a/releasenotes/notes/0.25/pauli-rotation-equivalences-6b2449c93c042dc9.yaml b/releasenotes/notes/0.25/pauli-rotation-equivalences-6b2449c93c042dc9.yaml index 5c435eb51a53..108e2133c588 100644 --- a/releasenotes/notes/0.25/pauli-rotation-equivalences-6b2449c93c042dc9.yaml +++ b/releasenotes/notes/0.25/pauli-rotation-equivalences-6b2449c93c042dc9.yaml @@ -1,5 +1,5 @@ --- -features: +features_transpiler: - | The transpiler's built-in :class:`.EquivalenceLibrary` has been taught more Pauli-rotation equivalences between the one-qubit :math:`R_X`, :math:`R_Y` and :math:`R_Z` gates, and between diff --git a/releasenotes/notes/0.25/preset-pm-vf2-max-trials-958bb8a36fff472f.yaml b/releasenotes/notes/0.25/preset-pm-vf2-max-trials-958bb8a36fff472f.yaml deleted file mode 100644 index f28aaf325056..000000000000 --- a/releasenotes/notes/0.25/preset-pm-vf2-max-trials-958bb8a36fff472f.yaml +++ /dev/null @@ -1,23 +0,0 @@ ---- -upgrade: - - | - The maximum number of trials evaluated when searching for the best - layout using :class:`.VF2Layout` and :class:`.VF2PostLayout` is now - limited in - :func:`qiskit.transpiler.preset_passmanagers.level_1_pass_manager`, - :func:`qiskit.transpiler.preset_passmanagers.level_2_pass_manager`, - and - :func:`qiskit.transpiler.preset_passmanagers.level_3_pass_manager` - to ``2,500``, ``25,000``, and ``250,000``, respectively. Previously, - all possible layouts were evaluated. This change was made to prevent - transpilation from hanging during layout scoring for circuits with many - connected components on larger devices, which scales combinatorially - since each connected component must be evaluated in all possible - positions on the device. To perform a full search as - before, manually run :class:`.VF2PostLayout` over the transpiled circuit - in strict mode, specifying ``0`` for ``max_trials``. -fixes: - - | - Fixed a potential performance scaling issue with layout scoring in preset - pass managers, which could occur when transpiling circuits with many - connected components on large devices. diff --git a/releasenotes/notes/0.25/qasm3-alias-refactor-3389bfce3e29e4cf.yaml b/releasenotes/notes/0.25/qasm3-alias-refactor-3389bfce3e29e4cf.yaml index d539bd4515f9..c0ea1a468034 100644 --- a/releasenotes/notes/0.25/qasm3-alias-refactor-3389bfce3e29e4cf.yaml +++ b/releasenotes/notes/0.25/qasm3-alias-refactor-3389bfce3e29e4cf.yaml @@ -1,11 +1,11 @@ --- -features: +features_qasm: - | The OpenQASM 3 exporters (:func:`.qasm3.dump`, :func:`~.qasm3.dumps` and :class:`~.qasm3.Exporter`) have a new ``allow_aliasing`` argument, which will eventually replace the ``alias_classical_registers`` argument. This controls whether aliasing is permitted for either classical bits or qubits, rather than the option only being available for classical bits. -upgrade: +upgrade_qasm: - | The OpenQASM 3 exporters (:func:`.qasm3.dump`, :func:`~.qasm3.dumps` and :class:`~.qasm3.Exporter`) will now use fewer "register alias" definitions in its output. The circuit described will not diff --git a/releasenotes/notes/0.25/qasm3-no-subroutine-b69c5ed7c65ce9ac.yaml b/releasenotes/notes/0.25/qasm3-no-subroutine-b69c5ed7c65ce9ac.yaml index b895e8e5fe7c..86d15c655f5e 100644 --- a/releasenotes/notes/0.25/qasm3-no-subroutine-b69c5ed7c65ce9ac.yaml +++ b/releasenotes/notes/0.25/qasm3-no-subroutine-b69c5ed7c65ce9ac.yaml @@ -3,6 +3,6 @@ fixes: - | The OpenQASM 3 exporter (:mod:`qiskit.qasm3`) will no longer output invalid OpenQASM 3 for non-unitary :class:`~.circuit.Instruction` instances, but will instead raise a - :exc:`.QASM3ExporterError` explaining that this are not yet supported. This feature will is + :exc:`.QASM3ExporterError` explaining that these are not yet supported. This feature is slated for a later release of Qiskit, when there are more classical-processing facilities throughout the library. diff --git a/releasenotes/notes/0.25/qiskit_version-956916f7b8d7bbb9.yaml b/releasenotes/notes/0.25/qiskit_version-956916f7b8d7bbb9.yaml index 33f8d825e3af..152fe6771bb9 100644 --- a/releasenotes/notes/0.25/qiskit_version-956916f7b8d7bbb9.yaml +++ b/releasenotes/notes/0.25/qiskit_version-956916f7b8d7bbb9.yaml @@ -1,9 +1,9 @@ --- -features: +features_misc: - | The magic ``%qiskit_version_table`` from ``qiskit.tools.jupyter`` now includes all - imported modules with ``'qiskit`` in their name. + imported modules with ``qiskit`` in their name. deprecations: - | - The dictionary ``qiskit.__qiskit_version__`` is deprecated, as Qiskit is define with a single package (``qiskit-terra``). - In the future, ``qiskit.__version__`` will be the single point to query the Qiskit release, as a standard string. + The dictionary ``qiskit.__qiskit_version__`` is deprecated, as Qiskit is defined with a single package (``qiskit-terra``). + In the future, ``qiskit.__version__`` will be the single point to query the Qiskit version, as a standard string. diff --git a/releasenotes/notes/0.25/qpy-layout-927ab34f2b47f4aa.yaml b/releasenotes/notes/0.25/qpy-layout-927ab34f2b47f4aa.yaml deleted file mode 100644 index 35ce0ce4ca57..000000000000 --- a/releasenotes/notes/0.25/qpy-layout-927ab34f2b47f4aa.yaml +++ /dev/null @@ -1,12 +0,0 @@ ---- -upgrade: - - | - The QPY format version emitted by :class:`~.qpy.dump` has increased to 8. - This new format version adds support for serializing the - :attr:`.QuantumCircuit.layout` attribute. -fixes: - - | - Fixed the :mod:`~qiskit.qpy` serialization of :attr:`.QuantumCircuit.layout` - attribue. Previously, the :attr:`~.QuantumCircuit.layout` attribute would - have been dropped when serializing a circuit to QPY. - Fixed `#10112 `__ diff --git a/releasenotes/notes/0.25/qpy_supports_discriminator_and_kernel-3b6048bf1499f9d3.yaml b/releasenotes/notes/0.25/qpy_supports_discriminator_and_kernel-3b6048bf1499f9d3.yaml index e730042274e0..46d398143888 100644 --- a/releasenotes/notes/0.25/qpy_supports_discriminator_and_kernel-3b6048bf1499f9d3.yaml +++ b/releasenotes/notes/0.25/qpy_supports_discriminator_and_kernel-3b6048bf1499f9d3.yaml @@ -1,5 +1,5 @@ --- -features: +features_pulse: - | QPY supports the :class:`~qiskit.pulse.configuration.Discriminator` and :class:`~qiskit.pulse.configuration.Kernel` objects. diff --git a/releasenotes/notes/0.25/relax_wire_order_restrictions-ffc0cfeacd7b8d4b.yaml b/releasenotes/notes/0.25/relax_wire_order_restrictions-ffc0cfeacd7b8d4b.yaml index c8fd6337fdb7..a1b0bac903ac 100644 --- a/releasenotes/notes/0.25/relax_wire_order_restrictions-ffc0cfeacd7b8d4b.yaml +++ b/releasenotes/notes/0.25/relax_wire_order_restrictions-ffc0cfeacd7b8d4b.yaml @@ -1,7 +1,7 @@ --- -features: +features_visualization: - | - Some restrictions when using ``wire_order`` in the circuit drawers had been relaxed. + Some restrictions when using ``wire_order`` in the circuit drawers have been relaxed. Now, ``wire_order`` can list just qubits and, in that case, it can be used with ``cregbundle=True``, since it will not affect the classical bits. diff --git a/releasenotes/notes/0.25/remove-deprecate-instructionset-circuit-cregs-91617e4b0993db9a.yaml b/releasenotes/notes/0.25/remove-deprecate-instructionset-circuit-cregs-91617e4b0993db9a.yaml index f1d8ebdad29b..0d89e9b654c1 100644 --- a/releasenotes/notes/0.25/remove-deprecate-instructionset-circuit-cregs-91617e4b0993db9a.yaml +++ b/releasenotes/notes/0.25/remove-deprecate-instructionset-circuit-cregs-91617e4b0993db9a.yaml @@ -1,5 +1,5 @@ --- -upgrade: +upgrade_circuits: - | The deprecated ``circuit_cregs`` argument to the constructor for the :class:`~.InstructionSet` class has been removed. It was deprecated in the diff --git a/releasenotes/notes/0.25/remove-deprecated-mpl-drawer-9d6eaa40d5a86777.yaml b/releasenotes/notes/0.25/remove-deprecated-mpl-drawer-9d6eaa40d5a86777.yaml index 59d8cef6d5e9..22cb8022f077 100644 --- a/releasenotes/notes/0.25/remove-deprecated-mpl-drawer-9d6eaa40d5a86777.yaml +++ b/releasenotes/notes/0.25/remove-deprecated-mpl-drawer-9d6eaa40d5a86777.yaml @@ -1,7 +1,7 @@ --- -upgrade: +upgrade_visualization: - | - In the internal ``qiskit.visualization.circuit.matplotlib.MatplotlibDrawer`` object, the arguments + In the internal ``~qiskit.visualization.circuit.matplotlib.MatplotlibDrawer`` object, the arguments ``layout``, ``global_phase``, ``qregs`` and ``cregs`` have been removed. They were originally deprecated in Qiskit Terra 0.20. These objects are simply inferred from the given ``circuit`` now. diff --git a/releasenotes/notes/0.25/remove-transpile-broadcast-1dfde28d508efa0d.yaml b/releasenotes/notes/0.25/remove-transpile-broadcast-1dfde28d508efa0d.yaml index f054b8fdb99c..075f38791f11 100644 --- a/releasenotes/notes/0.25/remove-transpile-broadcast-1dfde28d508efa0d.yaml +++ b/releasenotes/notes/0.25/remove-transpile-broadcast-1dfde28d508efa0d.yaml @@ -1,11 +1,11 @@ --- -upgrade: +upgrade_transpiler: - | Support for passing in lists of argument values to the :func:`~.transpile` function is removed. This functionality was deprecated as part of the - 0.23.0 release and is now being removed. You are still able to pass in a - list of :class:`~.QuantumCircuit` objects for the first positional argument, - what has been removed is the broadcasting lists of the other arguments to + 0.23.0 release. You are still able to pass in a + list of :class:`~.QuantumCircuit` objects for the first positional argument. + What has been removed is list broadcasting of the other arguments to each circuit in that input list. Removing this functionality was necessary to greatly reduce the overhead for parallel execution for transpiling multiple circuits at once. If you’re using this functionality diff --git a/releasenotes/notes/0.25/remove-util-3cd9eae2efc95176.yaml b/releasenotes/notes/0.25/remove-util-3cd9eae2efc95176.yaml index 2999490b1c34..a79989e0bb38 100644 --- a/releasenotes/notes/0.25/remove-util-3cd9eae2efc95176.yaml +++ b/releasenotes/notes/0.25/remove-util-3cd9eae2efc95176.yaml @@ -1,5 +1,5 @@ --- -upgrade: +upgrade_misc: - | The ``qiskit.util`` import location has been removed, as it had been deprecated since Qiskit Terra 0.17. Users should use the new diff --git a/releasenotes/notes/0.25/sabre-control-flow-3772af2c5b02c6d5.yaml b/releasenotes/notes/0.25/sabre-control-flow-3772af2c5b02c6d5.yaml index 1a900a01325c..83ade2183ff1 100644 --- a/releasenotes/notes/0.25/sabre-control-flow-3772af2c5b02c6d5.yaml +++ b/releasenotes/notes/0.25/sabre-control-flow-3772af2c5b02c6d5.yaml @@ -1,9 +1,9 @@ --- -features: +features_transpiler: - | Control-flow operations are now supported by the Sabre family of transpiler passes, namely layout pass :class:`.SabreLayout` and routing pass :class:`.SabreSwap`. Function :func:`.transpile` keyword arguments ``layout_method`` and ``routing_method`` now - accept the option "sabre" for circuits with control flow, + accept the option ``"sabre"`` for circuits with control flow, which was previously unsupported. diff --git a/releasenotes/notes/0.25/sabre-ctrl-flow-o1-431cd25a19adbcdc.yaml b/releasenotes/notes/0.25/sabre-ctrl-flow-o1-431cd25a19adbcdc.yaml index e80e77bc308d..6e386c2ec9a4 100644 --- a/releasenotes/notes/0.25/sabre-ctrl-flow-o1-431cd25a19adbcdc.yaml +++ b/releasenotes/notes/0.25/sabre-ctrl-flow-o1-431cd25a19adbcdc.yaml @@ -1,5 +1,5 @@ --- -upgrade: +upgrade_transpiler: - | The Sabre family of transpiler passes (namely :class:`.SabreLayout` and :class:`.SabreSwap`) are now used by default for all circuits diff --git a/releasenotes/notes/0.25/support-SparsePauliOp-Parameter-multiplication-245173f0b232f59b.yaml b/releasenotes/notes/0.25/support-SparsePauliOp-Parameter-multiplication-245173f0b232f59b.yaml index a140e4aed629..5383ba45d47c 100644 --- a/releasenotes/notes/0.25/support-SparsePauliOp-Parameter-multiplication-245173f0b232f59b.yaml +++ b/releasenotes/notes/0.25/support-SparsePauliOp-Parameter-multiplication-245173f0b232f59b.yaml @@ -1,4 +1,4 @@ -features: +features_quantum_info: - | Adds support for multiplication of :class:`.SparsePauliOp` objects with :class:`.Parameter` objects by using the * operator, for example:: @@ -12,4 +12,4 @@ features: fixes: - | - Fixes issue `#10185 `. + Fixes issue `#10185 `__. diff --git a/releasenotes/notes/0.25/token-swapper-rustworkx-9e02c0ab67a59fe8.yaml b/releasenotes/notes/0.25/token-swapper-rustworkx-9e02c0ab67a59fe8.yaml index fdfaf394e8b0..489d0eee9ea2 100644 --- a/releasenotes/notes/0.25/token-swapper-rustworkx-9e02c0ab67a59fe8.yaml +++ b/releasenotes/notes/0.25/token-swapper-rustworkx-9e02c0ab67a59fe8.yaml @@ -1,6 +1,4 @@ --- upgrade: - | - The :meth:`~.ApproximateTokenSwapper.map` has been modified to use the new ``rustworkx`` version - of :func:`~graph_token_swapper` for performance reasons. Qiskit Terra 0.25 now requires versison - 0.13.0 of ``rustworkx``. + Qiskit Terra 0.25 now requires versison 0.13.0 of ``rustworkx``. diff --git a/releasenotes/notes/0.25/umda-callback-eb644a49c5a9ad37.yaml b/releasenotes/notes/0.25/umda-callback-eb644a49c5a9ad37.yaml index f79a13a164e4..0dd500ab7dda 100644 --- a/releasenotes/notes/0.25/umda-callback-eb644a49c5a9ad37.yaml +++ b/releasenotes/notes/0.25/umda-callback-eb644a49c5a9ad37.yaml @@ -1,7 +1,7 @@ --- -features: +features_algorithms: - | Added the option to pass a callback to the :class:`.UMDA` optimizer, which allows - to keep track of the number of function evaluations, the current parameters, and the + keeping track of the number of function evaluations, the current parameters, and the best achieved function value. diff --git a/releasenotes/notes/0.25/unintended-rounding-with-max-size-1498af5f9a467990.yaml b/releasenotes/notes/0.25/unintended-rounding-with-max-size-1498af5f9a467990.yaml index 8beadb8cb994..41e60557052b 100644 --- a/releasenotes/notes/0.25/unintended-rounding-with-max-size-1498af5f9a467990.yaml +++ b/releasenotes/notes/0.25/unintended-rounding-with-max-size-1498af5f9a467990.yaml @@ -1,6 +1,7 @@ --- fixes: - | - The function :func:`~qiskit.visualization.state_visualization.state_to_latex` produced not valid LaTeX with unintended coefficient rounding, - resulting in errors when calling :func:`~qiskit.visualization.state_visualization.state_drawer` is called. + Fixed an issue with function :func:`~qiskit.visualization.state_visualization.state_to_latex`. + Previously, it produced invalid LaTeX with unintended coefficient rounding, which resulted in + errors when calling :func:`~qiskit.visualization.state_visualization.state_drawer`. Fixed `#9297 `__. diff --git a/releasenotes/notes/0.25/use-abi3-4a935e0557d3833b.yaml b/releasenotes/notes/0.25/use-abi3-4a935e0557d3833b.yaml index db946ded97ef..004546aadd95 100644 --- a/releasenotes/notes/0.25/use-abi3-4a935e0557d3833b.yaml +++ b/releasenotes/notes/0.25/use-abi3-4a935e0557d3833b.yaml @@ -5,13 +5,13 @@ upgrade: `Python Stable ABI `__ with support back to the oldest version of Python supported by Qiskit (currently 3.8). This means that moving forward there - will be a single precompiled wheels that are shipped on release that + will be a single precompiled wheel that is shipped on release that works with all of Qiskit's supported Python versions. There isn't any expected runtime performance difference using the limited API so it is enabled by default for all builds now. Previously, the compiled extensions were built using the version specific API and would only work with a single Python version. This change was made to reduce the number of package files we need to build and publish in each - release. When building Qiskit from source there should be no changes + release. When building Qiskit from source, there should be no changes necessary to the build process except that the default tags in the output filenames will be different to reflect the use of the limited API. diff --git a/releasenotes/notes/channel-validation-bug-fix-c06f8445cecc8478.yaml b/releasenotes/notes/channel-validation-bug-fix-c06f8445cecc8478.yaml index b68ae2a68dfe..16a7a64281bb 100644 --- a/releasenotes/notes/channel-validation-bug-fix-c06f8445cecc8478.yaml +++ b/releasenotes/notes/channel-validation-bug-fix-c06f8445cecc8478.yaml @@ -1,5 +1,5 @@ --- fixes: - | - Fixed a bug in :class:`.pulse.Channel` where index validation was done incorrectly and only + Fixed a bug in :class:`~qiskit.pulse.channels.Channel` where index validation was done incorrectly and only raised an error when the index was both non-integer and negative, instead of either. diff --git a/releasenotes/notes/expr-rvalue-conditions-8b5d5f7c015658c0.yaml b/releasenotes/notes/expr-rvalue-conditions-8b5d5f7c015658c0.yaml index 234888b2ac9b..53ce2c4a529e 100644 --- a/releasenotes/notes/expr-rvalue-conditions-8b5d5f7c015658c0.yaml +++ b/releasenotes/notes/expr-rvalue-conditions-8b5d5f7c015658c0.yaml @@ -1,5 +1,5 @@ --- -features: +features_circuits: - | The fields :attr:`.IfElseOp.condition`, :attr:`.WhileLoopOp.condition` and :attr:`.SwitchCaseOp.target` can now be instances of the new runtime classical-expression type @@ -36,9 +36,11 @@ features: For more examples, see the documentation for :mod:`qiskit.circuit.classical`. - This is a feature that hardware is only just beginning to support, so Qiskit's support is - starting conservatively, and you may well find rough edges in places where hardware doesn't - support expressions that look simple in Qiskit. Please bear with us, and your hardware vendors! + This feature is new for both Qiskit and the available quantum hardware that + Qiskit works with. As the features are still being developed there are likely + to be places where there are unexpected edge cases that will need some time to + be worked out. If you encounter any issue around classical expression support + or usage please open an issue with Qiskit or your hardware vendor. In this initial release, Qiskit has added the operations: @@ -65,18 +67,19 @@ features: (which is re-exposed via :mod:`qiskit.qasm3`), which we hope will be extended to match the new features in Qiskit. - | - In addition to the new representations of classical runtime expressions, some tools for working - with these objects have also been added. A general :class:`~.expr.ExprVisitor` is provided for + Tooling for working with the new representations of classical runtime expressions + has been added. + A general :class:`~.expr.ExprVisitor` is provided for consumers of these expressions to subclass. Two utilities based on this structure, :func:`~.expr.iter_vars` and :func:`~.expr.structurally_equivalent`, are also provided, which respectively produce an iterator through the :class:`~.expr.Var` nodes and check whether two :class:`~.expr.Expr` instances are structurally the same, up to some mapping of the :class:`~.expr.Var` nodes contained. - | - For those who wish to convert all old-style conditions into new-style :class:`~.expr.Expr` nodes - immediately, the function :func:`~.expr.lift_legacy_condition` is provided, though these new - expression nodes are not permitted in old-style :attr:`.Instruction.condition` fields, which are - due to be replaced by more advanced classical handling such as :class:`.IfElseOp`. + Added function :func:`~.expr.lift_legacy_condition` which can be used to convert old-style + conditions into new-style :class:`~.expr.Expr` nodes. + Note that these expression nodes are not permitted in old-style :attr:`.Instruction.condition` + fields, which are due to be replaced by more advanced classical handling such as :class:`.IfElseOp`. issues: - | Circuits containing classical expressions made with the :mod:`~.classical.expr` module are not diff --git a/releasenotes/notes/prepare-0.25-2efd7230b0ae0719.yaml b/releasenotes/notes/prepare-0.25-2efd7230b0ae0719.yaml new file mode 100644 index 000000000000..178dfe6df70f --- /dev/null +++ b/releasenotes/notes/prepare-0.25-2efd7230b0ae0719.yaml @@ -0,0 +1,100 @@ +--- +prelude: | + The Qiskit Terra 0.25.0 release highlights are: + + * Control-flow operations are now supported through the transpiler at + all optimization levels, including levels 2 and 3 (e.g. calling + :func:`.transpile` or :func:`.generate_preset_pass_manager` with + keyword argument ``optimization_level`` specified as 2 or 3 is now + supported). + + * The fields :attr:`.IfElseOp.condition`, :attr:`.WhileLoopOp.condition` and + :attr:`.SwitchCaseOp.target` can now be instances of the new runtime classical-expression type + :class:`.expr.Expr`. This is distinct from :class:`.ParameterExpression` because it is + evaluated *at runtime* for backends that support such operations. + + These new expressions have significantly more power than the old two-tuple form of supplying + classical conditions. For example, one can now represent equality constraints between two + different classical registers, or the logic "or" of two classical bits. These two examples + would look like:: + + from qiskit.circuit import QuantumCircuit, ClassicalRegister, QuantumRegister + from qiskit.circuit.classical import expr + + qr = QuantumRegister(4) + cr1 = ClassicalRegister(2) + cr2 = ClassicalRegister(2) + qc = QuantumCircuit(qr, cr1, cr2) + qc.h(0) + qc.cx(0, 1) + qc.h(2) + qc.cx(2, 3) + qc.measure([0, 1, 2, 3], [0, 1, 2, 3]) + + # If the two registers are equal to each other. + with qc.if_test(expr.equal(cr1, cr2)): + qc.x(0) + + # While either of two bits are set. + with qc.while_loop(expr.logic_or(cr1[0], cr1[1])): + qc.reset(0) + qc.reset(1) + qc.measure([0, 1], cr1) + + For more examples, see the documentation for :mod:`qiskit.circuit.classical`. + + This feature is new for both Qiskit and the available quantum hardware that + Qiskit works with. As the features are still being developed there are likely + to be places where there are unexpected edge cases that will need some time to + be worked out. If you encounter any issue around classical expression support + or usage please open an issue with Qiskit or your hardware vendor. + + In this initial release, Qiskit has added the operations: + + * :func:`~.expr.bit_not` + * :func:`~.expr.logic_not` + * :func:`~.expr.bit_and` + * :func:`~.expr.bit_or` + * :func:`~.expr.bit_xor` + * :func:`~.expr.logic_and` + * :func:`~.expr.logic_or` + * :func:`~.expr.equal` + * :func:`~.expr.not_equal` + * :func:`~.expr.less` + * :func:`~.expr.less_equal` + * :func:`~.expr.greater` + * :func:`~.expr.greater_equal` + + These can act on Python integer and Boolean literals, or on :class:`.ClassicalRegister` + and :class:`.Clbit` instances. + + All these classical expressions are fully supported through the Qiskit transpiler stack, through + QPY serialisation (:mod:`qiskit.qpy`) and for export to OpenQASM 3 (:mod:`qiskit.qasm3`). Import + from OpenQASM 3 is currently managed by `a separate package `__ + (which is re-exposed via :mod:`qiskit.qasm3`), which we hope will be extended to match the new + features in Qiskit. + + * The :mod:`qiskit.algorithms` module has been deprecated and will be removed + in a future release. It has been superseded by a new standalone library + ``qiskit-algorithms`` which can be found on PyPi or on Github here: + + https://github.com/qiskit-community/qiskit-algorithms + + The :mod:`qiskit.algorithms` module will continue to work as before and bug fixes + will be made to it until its future removal, but active development + of new features has moved to the new package. + If you're relying on :mod:`qiskit.algorithms` you should update your + Python requirements to also include ``qiskit-algorithms`` and update the imports + from ``qiskit.algorithms`` to ``qiskit_algorithms``. Please note that this + new package does not include already deprecated algorithms code, including + ``opflow`` and ``QuantumInstance``-based algorithms. If you have not yet + migrated from ``QuantumInstance``-based to primitives-based algorithms, + you should follow the migration guidelines in https://qisk.it/algo_migration. + The decision to migrate the :mod:`~.algorithms` module to a + separate package was made to clarify the purpose Qiskit and + make a distinction between the tools and libraries built on top of it. + + Qiskit Terra 0.25 has dropped support for Python 3.7 following + deprecation warnings started in Qiskit Terra 0.23. This is consistent + with Python 3.7’s end-of-life on the 27th of June, 2023. To continue + using Qiskit, you must upgrade to a more recent version of Python. diff --git a/setup.py b/setup.py index d932311cc682..ec0420f70691 100644 --- a/setup.py +++ b/setup.py @@ -58,7 +58,7 @@ setup( name="qiskit-terra", - version="0.25.0rc1", + version="0.25.0", description="Software for developing quantum computing programs", long_description=README, long_description_content_type="text/markdown",