Release 0.41.0
New features since last release
-
Add native support for
qml.PCPhaseforlightning.qubitandlightning.gpu. (#1107) -
Integrate sparse kernels into the Lightning-Qubit dynamic dispatcher, enhance the Python layers, and expand the testing process for dense and sparse operations. (#1094)
-
Add
qml.PSWAPgate native implementation to PennyLane-Lightning devices. (#1088) -
Implement new C++ kernels for efficient in-place multiplication of sparse matrices to state vectors, supporting both controlled and non-controlled gates, and add comprehensive tests for this new functionality. (#1085)
-
Add support for sparse
qml.QubitUnitarygates for Lightning state-vector simulators. (#1068) -
Lightning devices support dynamically allocated wires (e.g.
qml.device("lightning.qubit")). (#1043) -
Add support for Python 3.13 Lightning wheel builds. (#1001)
-
Add native
qml.SXandqml.ctrl(qml.SX)gates to all lightning devices. (#731)
Breaking changes
- Update the minimum required version of PennyLane to
v0.40.0. (#1033)
Improvements
-
Install Pytorch 2.5.1 CPU in CIs and update
make pythoncommand. (#1118) -
Update TF, Keras and Torch versions in the CIs based on PennyLane's pinned versions. (#1112)
-
Build Lightning-GPU and Lightning-Tensor wheels against Python 3.10 and 3.13 on non-release PRs. (#1112)
-
Use cuQuantum API for calculating expectation value of Pauli sentences in Lightning-GPU. (#1104)
-
Update CIs to use
requirements-tests.txtinstead ofrequirements-dev.txt. (#1105) -
Hide internal C++ APIs in Lightning docs. (#1096)
-
Implement the
jaxpr_jvpmethod to compute the jvp of a jaxpr usinglightning.qubit.
This method currently only support the adjoint differentiation method. (#1087) (#1106) -
Modify
expvalof named operators in Lightning-Qubit for in-place computation of expectation value, to avoid creating an intermediate statevector (#1079) (#565) -
Device (
"lightning.qubit","lightning.gpu","lightning.kokkos") pre-processing is now included in the execution pipeline when program capture is enabled. (#1084) -
Add semgrep/bandit security scanning for pull requests. (#1100)
-
Hide anonymous namespaces in Lightning docs. (#1097)
-
Expand test structure to efficiently handle sparse data. (#1085)
-
Remove redundant
reset_statecalls for circuit execution when state vector is freshly initialized. (#1076) -
Introduce a generalized sparse gate selection system via the
_observable_is_sparsemethod in the base measurement class, enabling future expansion for any number of sparse observables. (#1068) -
Optimize the copy of a input state-vector into Lightning-GPU. (#1071)
-
Add new GitHub workflow to enable benchmarking within pull request. (#1073)
-
Fix wheel naming in Docker builds for
setuptools v75.8.1compatibility. (#1075) -
Use native C++ kernels for controlled-adjoint and adjoint-controlled of supported operations. (#1063)
-
In Lightning-Tensor, allow
qml.MPSPrepto accept an MPS withlen(MPS) = n_wires-1. (#1064) -
Capture execution via
dev.eval_jaxprcan now be used withjax.jitandjax.vmap. (#1055) -
Add an
execution_configkeyword argument toLightningBase.eval_jaxprto accommodate a Device API change. (#1067) -
Remove the old device API references in the Lightning repo and test suite. (#1057)
-
Update GPU workflow to use the new self-hosted GPU runner infrastructure. (#1061)
-
Optimize MPO operation in
lightning.tensor. (#1054) -
Update
qml.ControlledQubitUnitarytests following the latest updates in PennyLane. (#1047) -
Remove unnecessary adjoint pytest skip for Lightning-Kokkos. (#1048)
-
Add
isortto the precommit hook. (#1052) -
Update source code to use
blackformatter 25.1.0. (#1059) -
Replace the type checking using the property
return_typeofMeasurementProcesswith directisinstancechecks. (#1044) -
Update Lightning integration tests following the
gradient_kwargsdeprecation in Pennylane. (#1045) -
Update
qml.MultiControlledXtests following the latest updates in PennyLane. (#1040) -
Merge the
v0.40.0-rcbranch to the master and bump version. (#1038) -
Reduce the number of shots in the PennyLane Python tests on CIs, from 20k to 10k. (#1046)
-
Program transformed by
qml.defer_measurementscan be executed onlightning.qubit. Supportsctrlandadjointwith program capture inlightning.qubit. (#1069)
Documentation
-
Modify
CHANGELOG.mdto prepare it for release v0.41.0 (#1117) -
Update install instructions for
lightning.gpu. (#1037)
Bug fixes
-
Fix the issue with decomposing controlled
qml.SProdandqml.Expoperations. (#1120) -
Fix the validation for all wires present after adding the extra wires from apply
mid_circuit_measurements. (#1119) -
Fix the issue with pip installing PennyLane (and Lightning-Qubit) on Windows. (#1116)
-
Fix the stable/stable issue with missing
pytest-split. (#1112) -
Add missing GH workflow step id, python setup, and virtual environment for aarch64 cuda. (#1113)
-
Fix the development wheel upload step for Python 3.13 by following the same syntax as for the other Python wheels. (#1111)
-
Add a workflow to run
label-external-pull-requestto label pull requests from external forks. (#1110) -
Fix the
test_preprocesstest skip condition forlightning.tensor. (#1092) -
Fix measurements with empty wires and operators for statevectors with dynamically allocated wires. (#1081)
-
Fix unit tests that were being skipped in
testApplyControlledPhaseShift. (#1083) -
Fix Github CI for aarch64 cuda to clean up after runs. (#1074)
-
Increase maximum time for aarch64-CUDA Github CI action. (#1072)
-
Fix
SyntaxWarningfromiswith a literal in Python tests. (#1070) -
Fix CI to collect Python code coverage for Lightning-Qubit and Lightning-Kokkos CPU. (#1053)
-
Upgrade the version of QEMU image to fix AARCH64 wheel action. (#1056)
-
Patch
MultiControlledXtests to fix stable/latest failures after the v0.40.0 release. (#1046) -
Update Github CI to use Ubuntu 24 and remove
libopenblas-basepackage. (#1041) -
Update the
eval_jaxprmethod to handle the new signatures for thecond,while, andforprimitives. (#1051)
Contributors
This release contains contributions from (in alphabetical order):
Runor Agbaire,
Catalina Albornoz,
Ali Asadi,
Saeed Bohloul,
Astral Cai,
Yushao Chen,
Amintor Dusko,
Pietropaolo Frisoni,
Christina Lee,
Joseph Lee,
Rashid N H M,
Luis Alfredo Nuñez Meneses,
Lee J. O'Riordan,
Mudit Pandey,
Andrija Paurevic,
Alex Preciado,
Shuli Shu,
Jake Zaia