Qiskit 0.30 release notes
0.30.1
Terra 0.18.3
Prelude
This bugfix release fixes a few minor issues in 0.18, including a performance regression in assemble when dealing with executing QuantumCircuit objects on pulse-enabled backends.
Bug Fixes
- Fixed #7004 where
AttributeErrorwas raised when executingScheduleBlockon a pulse backend. These blocks are now correctly treated as pulse jobs, likeSchedule. - Fixed an issue causing an error when binding a complex parameter value to an operator’s coefficient. Casts to
floatinPrimitiveOpwere generalized to casts tocomplexif necessary, but will remainfloatif there is no imaginary component. Fixes #6976. - Update the 1-qubit gate errors in
plot_error_mapto use the sx gate instead of the u2 gate, consistent with IBMQ backends.
Aer 0.9.0
No change
Ignis 0.6.0
No change
Aqua 0.9.5
No change
IBM Q Provider 0.16.0
No change
0.30.0
Terra 0.18.2
No change
Aer 0.9.0
Prelude
The 0.9 release includes new backend options for parallel exeuction of large numbers of circuits on a HPC cluster using a Dask distributed, along with other general performance improvements and bug fixes.
New Features
-
Added support for set_matrix_product_state.
-
Add qiskit library
SXdgGateandCUGateto the supported basis gates for the Aer simulator backends. Note that theCUGategate is only natively supported for thestatevectorandunitarymethods. For other simulation methods it must be transpiled to the supported basis gates for that method. -
Adds support for N-qubit Pauli gate (
qiskit.circuit.library.generalized_gates.PauliGate) to all simulation methods of theAerSimulatorandQasmSimulator. -
Adds the ability to set a custom executor and configure job splitting for executing multiple circuits in parallel on a HPC clustor. A custom executor can be set using the
executoroption, and job splitting is configured by using themax_job_sizeoption.For example configuring a backend and executing using
backend = AerSimulator(max_job_size=1, executor=custom_executor) job = backend.run(circuits)will split the exection into multiple jobs each containing a single circuit. If job splitting is enabled the
runmethod will return aAerJobSetobject containing all the individualAerJobclasses. After all individual jobs finish running the job results are automatically combined into a single Result object that is returned byjob.result().Supported executors include those in the Python
concurrent.futuresmodule (eg.ThreadPoolExecutor,ProcessPoolExecutor), and Dask distributed Client executors if the optional dask library is installed. Using a Dask executor allows configuring parallel execution of multiple circuits on HPC clusters. -
Adds ability to record logging data for the
matrix_product_statesimulation method to the experiment result metadata by setting the backend optionmps_log_data=True. The saved data includes the bond dimensions and the discarded value (the sum of the squares of the Schmidt coeffients that were discarded by approximation) after every relevant circuit instruction. -
The
run()method for theAerSimulator,QasmSimulator,StatevectorSimulator, andUnitarySimulatorhas a new kwarg,parameter_bindswhich is used to provide a list of values to use for any unbound parameters in the inbound circuit. For example:from qiskit.circuit import QuantumCircuit, Parameter from qiskit.providers.aer import AerSimulator shots = 1000 backend = AerSimulator() circuit = QuantumCircuit(2) theta = Parameter('theta') circuit.rx(theta, 0) circuit.cx(0, 1) circuit.measure_all() parameter_binds = [{theta: [0, 3.14, 6.28]}] backend.run(circuit, shots=shots, parameter_binds=parameter_binds).result()will run the input circuit 3 times with the values 0, 3.14, and 6.28 for theta. When running with multiple parameters the length of the value lists must all be the same. When running with multiple circuits, the length of
parameter_bindsmust match the number of input circuits (you can use an empty dict,{}, if there are no binds for a circuit). -
The
PulseSimulatorcan now takeQuantumCircuitobjects on therun(). Previously, it only would exceptScheduleobjects as input torun(). When a circuit or list of circuits is passed to the simulator it will callschedule()to convert the circuits to a schedule before executing the circuit. For example:from qiskit.circuit import QuantumCircuit from qiskit.compiler import transpile from qiskit.test.mock import FakeVigo from qiskit.providers.aer.backends import PulseSimulator backend = PulseSimulator.from_backend(FakeVigo()) circuit = QuantumCircuit(2) circuit.h(0) circuit.cx(0, 1) circuit.measure_all() transpiled_circuit = transpile(circuit, backend) backend.run(circuit)
Known Issues
- The
SaveExpectationValueandSaveExpectationValueVariancehave been disabled for the extended_stabilizer method of theQasmSimulatorandAerSimulatordue to returning the incorrect value for certain Pauli operator components. Refer to #1227 <https://github.com/Qiskit/qiskit-aer/issues/1227> for more information and examples.
Upgrade Notes
- The default basis for the
NoiseModelclass has been changed from["id", "u3", "cx"]to["id", "rz", "sx", "cx"]due to the deprecation of theu3circuit method in qiskit-terra and change of qiskit-ibmq-provider backend basis gates. To use the old basis gates you can initialize a noise model with custom basis gates asNoiseModel(basis_gates=["id", "u3", "cx"]). - Removed the
backend_optionskwarg from therunmethnod of Aer backends that was deprecated in qiskit-aer 0.7. All run options must now be passed as separate kwargs. - Removed passing
system_modelas a positional arg for therunmethod of thePulseSimulator.
Deprecation Notes
- Passing an assembled qobj directly to the
run()method of the Aer simulator backends has been deprecated in favor of passing transpiled circuits directly asbackend.run(circuits, **run_options). - All snapshot instructions in
qiskit.providers.aer.extensionshave been deprecated. For replacement use the save instructions from theqiskit.providers.aer.librarymodule. - Adding non-local quantum errors to a
NoiseModelhas been deprecated due to inconsistencies in how this noise is applied to the optimized circuit. Non-local noise should be manually added to a scheduled circuit in Qiskit using a custom transpiler pass before being run on the simulator. - Use of the
methodoption of theStatevectorSimulator, andUnitarySimulatorto run a GPU simulation has been deprecated. To run a GPU simulation on a compatible system use the optiondevice='GPU'instead.
Bug Fixes
- Fixes performance issue with how the
basis_gatesconfiguration attribute was set. Previously there were unintended side-effects to the backend class which could cause repeated simulation runtime to incrementally increase. Refer to #1229 <https://github.com/Qiskit/qiskit-aer/issues/1229> for more information and examples. - Fixed bug in MPS::apply_kraus. After applying the kraus matrix to the relevant qubits, we should propagate the changes to the neighboring qubits.
- Fixes a bug where qiskit-terra assumes that qubits in a multiplexer gate are first the targets and then the controls of the gate while qiskit-aer assumes the opposite order.
- Fixes a bug introduced in 0.8.0 where GPU simulations would allocate unneeded host memory in addition to the GPU memory.
- Fixes bug where the initialize instruction would disable measurement sampling optimization for the statevector and matrix product state simulation methods even when it was the first circuit instruction or applied to all qubits and hence deterministic.
- Fix issue #1196 by using the inner products with the computational basis states to calculate the norm rather than the norm estimation algorithm.
- Fixes a bug in the
stabilizersimulator method of theQasmSimulatorandAerSimulatorwhere the expectation value for thesave_expectation_valueandsnapshot_expectation_valuecould have the wrong sign for certainYPauli’s. - Fixes bug where the if the required memory is smaller than the system memory the multi-chunk simulation method was enabled and simulation was still started. This case will now throw an insufficient memory exception.
- Fixes issue where setting the
shotsoption for a backend withset_options(shots=k)was always running the default number of shots (1024) rather than the specified value. - Fixes a bug in how the
AerSimulatorhandled the option value formax_parallel_experiments=1. Previously this was treated the same asmax_parallel_experiments=0. - Fixes bug in the
extended_stabilizersimulation method where it incorrectly treated qelay gate and multi-qubit Pauli instructions as unsupported. - Fixes typo in the
AerSimulatorandQasmSimulatoroptions for theextended_stabilizer_norm_estimation_repetitionsoption. - Fixes bug with applying the
unitarygate in using thematrix_product_statesimulation method which did not correctly support permutations in the ordering of the qubits on which the gate is applied. - Fixes an issue where gate fusion could still be enabled for the
matrix_product_statesimulation method even though it is not supported. Now fusion is always disabled for this method. - Fixed bug in the
matrix_product_statesimulation method in computing the normalization following truncation of the Schmidt coefficients after performing the SVD.
Other Notes
- Improves the performance of the measurement sampling algorithm for the
matrix_product_statesimulation method. The new default behaviour is to always sample using the improvedmps_apply_measuremethod. Themps_probabilitiessampling method be still used by setting the custom option valuemps_sample_measure_algorithm="mps_probabilities".
Ignis 0.6.0
No change
Aqua 0.9.5
No change
IBM Q Provider 0.16.0
No change