Skip to main content

PennyLane-Lightning plugin

Project description

The Lightning plugin ecosystem provides fast state-vector and tensor-network simulators written in C++.

PennyLane is a cross-platform Python library for quantum machine learning, automatic differentiation, and optimization of hybrid quantum-classical computations. PennyLane supports Python 3.11 and above.

Backends

PennyLane-Lightning high performance simulators include the following backends:

  • lightning.qubit: a fast state-vector simulator written in C++ with optional OpenMP additions and parallelized gate-level SIMD kernels.
  • lightning.kokkos: a state-vector simulator written with Kokkos. It can exploit the inherent parallelism of modern processing units supporting the OpenMP, CUDA or HIP programming models. It also offers distributed state-vector simulation via MPI.
  • lightning.amdgpu: a state-vector simulator specifically for AMD GPUs. This device is an alias of our lightning.kokkos simulator.
  • lightning.gpu: a state-vector simulator based on the NVIDIA cuQuantum SDK. It notably implements a distributed state-vector simulator based on MPI.
  • lightning.tensor: a tensor-network simulator based on the NVIDIA cuQuantum SDK. The supported methods are Matrix Product State (MPS) and Exact Tensor Network (TN).

If you're not sure which simulator to use, check out our PennyLane Performance page.

Installation

The following table summarizes the supported platforms and the primary installation mode:

Linux x86 Linux ARM MacOS ARM Windows
Lightning-Qubit pip pip pip pip
Lightning-Kokkos (OMP) pip pip pip
Lightning-Kokkos (CUDA) source source
Lightning-Kokkos (HIP) source source
Lightning-Kokkos (MPI) source
Lightning-AMDGPU pip source
Lightning-GPU pip pip
Lightning-GPU (MPI) source
Lightning-Tensor pip pip

For Lightning-AMDGPU, pre-built wheels are available for MI300 series GPU for ROCm 7.0 and greater. For older architecture and ROCm versions, please install from source.

To install the latest stable version of these plugins, check out the PennyLane installation guide.

If you wish to install the latest development version, instructions for building from source are also available for each backend.

Docker support

Docker images for the various backends are found on the PennyLane Docker Hub page, where a detailed description about PennyLane Docker support can be found. Briefly, one can build the Docker Lightning images using:

git clone https://github.com/PennyLaneAI/pennylane-lightning.git
cd pennylane-lightning
docker build -f docker/Dockerfile --target ${TARGET} .

where ${TARGET} is one of the following:

  • wheel-lightning-qubit
  • wheel-lightning-gpu
  • wheel-lightning-kokkos-openmp
  • wheel-lightning-kokkos-cuda
  • wheel-lightning-kokkos-rocm

Contributing

We welcome contributions - simply fork the repository of this plugin, and then make a pull request containing your contribution. All contributors to this plugin will be listed as authors on the releases.
We also encourage bug reports, suggestions for new features and enhancements, and even links to cool projects or applications built on PennyLane.

Black & Pylint

If you contribute to the Python code, please mind the following. The Python code is formatted with the PEP 8 compliant opinionated formatter Black. We set a line width of a 100 characters. The Python code is statically analyzed with Pylint. We set up a pre-commit hook (see Git hooks) to run both of these on git commit. Please make your best effort to comply with black and pylint before using disabling pragmas (e.g. # pylint: disable=missing-function-docstring).

Authors

Lightning is the work of many contributors.

If you are using Lightning for research, please cite:

@misc{
    asadi2024,
    title={{Hybrid quantum programming with PennyLane Lightning on HPC platforms}},
    author={Ali Asadi and Amintor Dusko and Chae-Yeun Park and Vincent Michaud-Rioux and Isidor Schoch and Shuli Shu and Trevor Vincent and Lee James O'Riordan},
    year={2024},
    eprint={2403.02512},
    archivePrefix={arXiv},
    primaryClass={quant-ph},
    url={https://arxiv.org/abs/2403.02512},
}

Support

If you are having issues, please let us know by posting the issue on our Github issue tracker, or by asking a question in the forum.

License

The Lightning plugins are free and open source, released under the Apache License, Version 2.0.
The Lightning-GPU and Lightning-Tensor plugins make use of the NVIDIA cuQuantum SDK headers to enable the device bindings to PennyLane, which are held to their own respective license.

Acknowledgements

PennyLane Lightning makes use of the following libraries and tools, which are under their own respective licenses:

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pennylane_lightning_gpu-0.44.0.tar.gz (765.8 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

pennylane_lightning_gpu-0.44.0-cp314-cp314-manylinux_2_28_x86_64.whl (913.0 kB view details)

Uploaded CPython 3.14manylinux: glibc 2.28+ x86-64

pennylane_lightning_gpu-0.44.0-cp314-cp314-manylinux_2_28_aarch64.whl (831.9 kB view details)

Uploaded CPython 3.14manylinux: glibc 2.28+ ARM64

pennylane_lightning_gpu-0.44.0-cp313-cp313-manylinux_2_28_x86_64.whl (913.2 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.28+ x86-64

pennylane_lightning_gpu-0.44.0-cp313-cp313-manylinux_2_28_aarch64.whl (831.4 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.28+ ARM64

pennylane_lightning_gpu-0.44.0-cp312-cp312-manylinux_2_28_x86_64.whl (913.3 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.28+ x86-64

pennylane_lightning_gpu-0.44.0-cp312-cp312-manylinux_2_28_aarch64.whl (831.5 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.28+ ARM64

pennylane_lightning_gpu-0.44.0-cp311-cp311-manylinux_2_28_x86_64.whl (913.2 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.28+ x86-64

pennylane_lightning_gpu-0.44.0-cp311-cp311-manylinux_2_28_aarch64.whl (831.3 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.28+ ARM64

File details

Details for the file pennylane_lightning_gpu-0.44.0.tar.gz.

File metadata

  • Download URL: pennylane_lightning_gpu-0.44.0.tar.gz
  • Upload date:
  • Size: 765.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.13

File hashes

Hashes for pennylane_lightning_gpu-0.44.0.tar.gz
Algorithm Hash digest
SHA256 2e22d10855a5877ce99a2daf63f668228fdc78d695a10207d9b448ba697e3167
MD5 7f69c64d06f9c70510f29b9fddd7f461
BLAKE2b-256 ae4ea1123ac233f2badd82fab907080dd36c4b1d356402b1ff580948ae2cf346

See more details on using hashes here.

File details

Details for the file pennylane_lightning_gpu-0.44.0-cp314-cp314-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for pennylane_lightning_gpu-0.44.0-cp314-cp314-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 bfeceddb018dd68af95a021f5aff1e8169aec36410e8d0363f1e2cf5b9dfd472
MD5 14fb55ac8aea03a41e0aac3e17c01d0e
BLAKE2b-256 1c83764511f9cf4b9a8305865a0dbfca0449d4d257fef28bde15b29ca4c1eb66

See more details on using hashes here.

File details

Details for the file pennylane_lightning_gpu-0.44.0-cp314-cp314-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for pennylane_lightning_gpu-0.44.0-cp314-cp314-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 018e9510e6a3cac858ca7caa8390b8cb97d43bb094383a059a71b2626dae6dcd
MD5 f0f9cacb0cc0b337c338a1a9bea4cbdf
BLAKE2b-256 62c461544d20865597702929cb02291b467ea178b0ad0a1644657a0ef3c46cbf

See more details on using hashes here.

File details

Details for the file pennylane_lightning_gpu-0.44.0-cp313-cp313-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for pennylane_lightning_gpu-0.44.0-cp313-cp313-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 9006fb3970dd3fa2a6064a618d1974cc530f2fa6e169fa96f600c668fa7c0f87
MD5 e3cff06443d9fc306d4a30f631f987fb
BLAKE2b-256 00864361f276bcf73feadb7a263fe287d5ea6a24b461be02407c3bb2f2af048f

See more details on using hashes here.

File details

Details for the file pennylane_lightning_gpu-0.44.0-cp313-cp313-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for pennylane_lightning_gpu-0.44.0-cp313-cp313-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 13f0e8c11f61981de29b292d0a05c875b4af67dd97d71dad248ecc44d567402e
MD5 142ab544cd8da354c0b2594a7188dc02
BLAKE2b-256 458345a04d4c27cb67ccfc1364c8659060d16b33b1e2238cde9604a2922d0278

See more details on using hashes here.

File details

Details for the file pennylane_lightning_gpu-0.44.0-cp312-cp312-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for pennylane_lightning_gpu-0.44.0-cp312-cp312-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 056236be420a088d690f72de4e4d22a5af1443bd9b899aca97364db450d1631a
MD5 35459a4b0c939158cfde46b9d0e3cfef
BLAKE2b-256 5c121517dae4e66e3b4823abc9b7e84ff4bc61792bf6856506ac3dbb49884ab0

See more details on using hashes here.

File details

Details for the file pennylane_lightning_gpu-0.44.0-cp312-cp312-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for pennylane_lightning_gpu-0.44.0-cp312-cp312-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 609c0880e263ba77436dc756af25bc9b90f428967e2af85d938ac003afdfb72b
MD5 61e40e02c7d8498dc5a6c3e0b33f1942
BLAKE2b-256 23cf09a7041cccc248d7f4efa57fbff379c86eb68e7132433bee5bf6e38c4c70

See more details on using hashes here.

File details

Details for the file pennylane_lightning_gpu-0.44.0-cp311-cp311-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for pennylane_lightning_gpu-0.44.0-cp311-cp311-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 10350eab6eda4903cbb2272b6cf4a88152b2ccbf5caef2bbdb836a3984d2fc69
MD5 d9abd9432627f2aa2340f3840ba9dc3e
BLAKE2b-256 20e64582c2f4f2be6361817220fd4eba5728923aafc8832e73c8cd629e29b8e1

See more details on using hashes here.

File details

Details for the file pennylane_lightning_gpu-0.44.0-cp311-cp311-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for pennylane_lightning_gpu-0.44.0-cp311-cp311-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 1b196ecd91fc31e6bd1479bc2fb39a9bf7b782ad7e38d4fa4d02486b03f6eee7
MD5 ea7f82435925e6f4ac06f58af98a62ff
BLAKE2b-256 dd40a555d74c3d3f4b5081c149c82453d5366ab0841810109c446473efc28e6d

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page