Pennylane-lightning

Latest version: v0.36.0

Safety actively analyzes 628989 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 2 of 6

0.33.0

New features since last release

* Add documentation updates for the `lightning_gpu` backend. (525)

* Add `SparseHamiltonian` support for Lightning-Qubit and Lightning-GPU. (526)

* Add `SparseHamiltonian` support for Lightning-Kokkos. (527)

* Integrate python/pybind layer of distributed Lightning-GPU into the Lightning monorepo with python unit tests. (518)

* Integrate the distributed C++ backend of Lightning-GPU into the Lightning monorepo. (514)

* Integrate Lightning-GPU into the Lightning monorepo. The new backend is named `lightning_gpu` and includes all single-GPU features. (499)

* Build Linux wheels for Lightning-GPU (CUDA-11). (517)

* Add `Dockerfile` in `docker` and `make docker` workflow in `Makefile`. The Docker images and documentation are available on [DockerHub](https://hub.docker.com/repository/docker/pennylaneai/pennylane). (#496)

* Add mid-circuit state preparation operation tests. (495)

Improvements

* Improve Python testing for Lightning-GPU (+MPI) by adding jobs in Actions files and adding Python tests to increase code coverage. (522)

* Add support for `pip install pennylane-lightning[kokkos]` for the OpenMP backend. (515)

* Update `setup.py` to allow for multi-package co-existence. The `PennyLane_Lightning` package now is the responsible for the core functionality, and will be depended upon by all other extensions. (504)

* Redesign Lightning-Kokkos `StateVectorKokkos` class to use Kokkos `RangePolicy` together with special functors in `applyMultiQubitOp` to apply 1- to 4-wire generic unitary gates. For more than 4 wires, the general implementation using Kokkos `TeamPolicy` is employed to yield the best all-around performance. (490)

* Redesign Lightning-Kokkos `Measurements` class to use Kokkos `RangePolicy` together with special functors to obtain the expectation value of 1- to 4-wire generic unitary gates. For more than 4 wires, the general implementation using Kokkos `TeamPolicy` is employed to yield the best all-around performance. (489)

* Add tests to increase Lightning-Kokkos coverage. (485)

* Add memory locality tag reporting and adjoint diff dispatch for `lightning.qubit` statevector classes. (492)

* Add support for dependent external packages to C++ core. (482)

* Add support for building multiple backend simulators. (497)

Breaking changes

* Add `tests_gpu.yml` workflow to test the Lightning-Kokkos backend with CUDA-12. (494)

* Implement `LM::GeneratorDoubleExcitation`, `LM::GeneratorDoubleExcitationMinus`, `LM::GeneratorDoubleExcitationPlus` kernels. Lightning-Qubit default kernels are now strictly from the `LM` implementation, which requires less memory and is faster for large state vectors. (512)

* Add workflows validating compatibility between PennyLane and Lightning's most recent stable releases and development (latest) versions. (507) (498)

* Introduce `timeout-minutes` in various workflows, mainly to avoid Windows builds hanging for several hours. (503)

* Cast integral-valued arrays to the device's complex type on entry in `_preprocess_state_vector` to ensure the state is correctly represented with floating-point numbers. (501)

* Update `DefaultQubit` to `DefaultQubitLegacy` on Lightning fallback. (500)

* Enums defined in `GateOperation.hpp` start at `1` (previously `0`). `::BEGIN` is introduced in a few places where it was assumed `0` accordingly. (485) `::BEGIN` was later reverted to `0`, keeping the rest of the changes, to fix a compatibility issue with [Catalyst](https://docs.pennylane.ai/projects/catalyst/en/stable/). (#521)

* Enable pre-commit hooks to format all Python files and linting of all Python source files. (485)

Bug fixes

* Re-add support for `pip install pennylane-lightning[gpu]`. (515)

* Switch most Lightning-Qubit default kernels to `LM`. Add `LM::multiQubitOp` tests, failing when targeting out-of-order wires clustered close to `num_qubits-1`. Fix the `LM::multiQubitOp` kernel implementation by introducing a generic `revWireParity` routine and replacing the `bitswap`-based implementation. Mimic the changes fixing the corresponding `multiQubitOp` and `expval` functors in Lightning-Kokkos. (511)

* Fix RTD builds by removing unsupported `system_packages` configuration option. (491)

Contributors

This release contains contributions from (in alphabetical order):

Ali Asadi, Amintor Dusko, Vincent Michaud-Rioux, Lee J. O'Riordan, Shuli Shu

0.32.0

Improvements

* Refactor LKokkos `Measurements` class to use (fast) specialized functors whenever possible. [(481)](https://github.com/PennyLaneAI/pennylane-lightning/pull/481)

* Merge Lightning Qubit and Lightning Kokkos backends in the new repository. [(472)](https://github.com/PennyLaneAI/pennylane-lightning/pull/472)

New features since last release

* The `lightning_kokkos` backend supports Nvidia GPU execution (with Kokkos v4 and CUDA v12). [(477)](https://github.com/PennyLaneAI/pennylane-lightning/pull/477)

* Complete overhaul of repository structure to facilitate integration of multiple backends. Refactoring efforts we directed to improve development performance, and code reuse and decrease overall overhead to propagate changes through backends. The new C++ modular build strategy allows faster test builds restricted to a module. Update CI/CD actions concurrency strategy. Change the minimal Python version to 3.9. [(472)](https://github.com/PennyLaneAI/pennylane-lightning/pull/472)

* Wheels are built with native support for sparse Hamiltonians. [(470)](https://github.com/PennyLaneAI/pennylane-lightning/pull/470)

* Add native support to sparse Hamiltonians in the absence of Kokkos & Kokkos-kernels. [(465)](https://github.com/PennyLaneAI/pennylane-lightning/pull/465)

Breaking changes

* Rename `QubitStateVector` to `StatePrep` in the `LightningQubit` and `LightningKokkos` classes. [(486)](https://github.com/PennyLaneAI/pennylane-lightning/pull/486)

* Modify `adjointJacobian` methods to accept a (maybe unused) reference `StateVectorT`, allowing device-backed simulators to directly access state vector data for adjoint differentiation instead of copying it back-and-forth into `JacobianData` (host memory). [(477)](https://github.com/PennyLaneAI/pennylane-lightning/pull/477)

Documentation

* Integrated new unified docs for Lightning Kokkos and Lightning Qubit packages. [(473)](https://github.com/PennyLaneAI/pennylane-lightning/pull/473)

Bug fixes

* Ensure PennyLane has an `active_return` attribute before calling it. [(483)](https://github.com/PennyLaneAI/pennylane-lightning/pull/483)

* Do no import `sqrt2_v` from `<numbers>` in `Util.hpp` to resolve issue with Lightning-GPU builds. [(479)](https://github.com/PennyLaneAI/pennylane-lightning/pull/479)

* Update the CMake internal references to enable sub-project compilation with affecting the parent package. [(478)](https://github.com/PennyLaneAI/pennylane-lightning/pull/478)

* `apply` no longer mutates the inputted list of operations. [(474)](https://github.com/PennyLaneAI/pennylane-lightning/pull/474)

Contributors

This release contains contributions from (in alphabetical order):

Amintor Dusko, Christina Lee, Vincent Michaud-Rioux, Lee J. O'Riordan

0.31.0

New features since last release

* Update Kokkos support to 4.0.01. [(439)] (https://github.com/PennyLaneAI/pennylane-lightning/pull/439)

Breaking changes

* Update tests to be compliant with PennyLane v0.31.0 development changes and deprecations. [(448)](https://github.com/PennyLaneAI/pennylane-lightning/pull/448)

Improvements

* Remove logic from `setup.py` and transfer paths and env variable definitions into workflow files. [(450)](https://github.com/PennyLaneAI/pennylane-lightning/pull/450)

* Detect MKL or CBLAS if `ENABLE_BLAS=ON` making sure that BLAS is linked as expected. [(449)](https://github.com/PennyLaneAI/pennylane-lightning/pull/449)

Documentation

* Fix LightningQubit class parameter documentation. [(456)](https://github.com/PennyLaneAI/pennylane-lightning/pull/456)

Bug fixes

* Ensure cross-platform wheels continue to build with updates in git safety checks. [(452)](https://github.com/PennyLaneAI/pennylane-lightning/pull/452)

* Fixing Python version bug introduce in [(450)](https://github.com/PennyLaneAI/pennylane-lightning/pull/450)
when `Python_EXECUTABLE` was removed from `setup.py`. [(461)](https://github.com/PennyLaneAI/pennylane-lightning/pull/461)

* Ensure aligned allocator definition works with C++20 compilers. [(438)](https://github.com/PennyLaneAI/pennylane-lightning/pull/438)

* Prevent multiple threads from calling `Kokkos::initialize` or `Kokkos::finalize`. [(439)](https://github.com/PennyLaneAI/pennylane-lightning/pull/439)

Contributors

This release contains contributions from (in alphabetical order):

Vincent Michaud-Rioux, Lee J. O'Riordan, Chae-Yeun Park

0.30.0

New features since last release

* Add MCMC sampler.
[(384)](https://github.com/PennyLaneAI/pennylane-lightning/pull/384)

* Serialize PennyLane's arithmetic operators when they are used as observables
that are expressed in the Pauli basis.
[(424)](https://github.com/PennyLaneAI/pennylane-lightning/pull/424)

Breaking changes

* Lightning now works with the new return types specification that is now default in PennyLane.
See [the PennyLane `qml.enable_return`](https://docs.pennylane.ai/en/stable/code/api/pennylane.enable_return.html?highlight=enable_return) documentation for more information on this change.
[(427)](https://github.com/PennyLaneAI/pennylane-lightning/pull/427)

Instead of creating potentially ragged numpy array, devices and `QNode`'s now return an object of the same type as that
returned by the quantum function.


>>> dev = qml.device('lightning.qubit', wires=1)
>>> qml.qnode(dev, diff_method="adjoint")
... def circuit(x):
... qml.RX(x, wires=0)
... return qml.expval(qml.PauliY(0)), qml.expval(qml.PauliZ(0))
>>> x = qml.numpy.array(0.5)
>>> circuit(qml.numpy.array(0.5))
(array(-0.47942554), array(0.87758256))


Interfaces like Jax or Torch handle tuple outputs without issues:


>>> jax.jacobian(circuit)(jax.numpy.array(0.5))
(Array(-0.87758255, dtype=float32, weak_type=True),
Array(-0.47942555, dtype=float32, weak_type=True))


Autograd cannot differentiate an output tuple, so results must be converted to an array before
use with `qml.jacobian`:


>>> qml.jacobian(lambda y: qml.numpy.array(circuit(y)))(x)

0.29.0

Improvements

* Remove runtime dependency on ninja build system. [(414)](https://github.com/PennyLaneAI/pennylane-lightning/pull/414)

* Allow better integration and installation support with CMake targeted binary builds. [(403)](https://github.com/PennyLaneAI/pennylane-lightning/pull/403)

* Remove explicit Numpy and Scipy requirements. [(412)](https://github.com/PennyLaneAI/pennylane-lightning/pull/412)

* Get `llvm` installation root from the environment variable `LLVM_ROOT_DIR` (or fallback to `brew`). [(413)](https://github.com/PennyLaneAI/pennylane-lightning/pull/413)

* Update AVX2/512 kernel infrastructure for additional gate/generator operations. [(404)](https://github.com/PennyLaneAI/pennylane-lightning/pull/404)

* Remove unnecessary lines for resolving CodeCov issue. [(415)](https://github.com/PennyLaneAI/pennylane-lightning/pull/415)

* Add more AVX2/512 gate operations. [(393)](https://github.com/PennyLaneAI/pennylane-lightning/pull/393)

Bug fixes

* Ensure error raised when asking for out of order marginal probabilities. Prevents the return of incorrect results. [(416)](https://github.com/PennyLaneAI/pennylane-lightning/pull/416)

* Fix Github shields in README. [(402)](https://github.com/PennyLaneAI/pennylane-lightning/pull/402)

Contributors

Amintor Dusko, Vincent Michaud-Rioux, Lee James O'Riordan, Chae-Yeun Park

0.28.2

Bug fixes

* Fix Python module versioning for Linux wheels. [(408)](https://github.com/PennyLaneAI/pennylane-lightning/pull/408)

Contributors

This release contains contributions from (in alphabetical order):

Amintor Dusko

Page 2 of 6

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.