Skip to main content

Python bindings for the CUDA Quantum toolkit for heterogeneous quantum-classical workflows.

Project description

Welcome to the CUDA Quantum Python API

CUDA Quantum is a comprehensive framework for quantum programming. It features:

  • A programming model which extends C++ and Python with quantum kernels, enabling high-level programming in familiar languages
  • A high-performance quantum compiler, NVQ++, based on the industry standard low-level virtual machine (LLVM) toolchain
  • Interoperability with all of the leading models and tools for accelerated computing, including CUDA, ISO standard parallelism, OpenMP, and OpenACC
  • The ability to utilize and seamlessly switch between different quantum technologies, including state-of-the-art simulator backends with NVIDIA cuQuantum and a number of different physical quantum processors (QPUs)

The CUDA Quantum Python wheels contain the Python API and core components of CUDA Quantum. For more information about available packages and documentation, see our release notes.

Installing CUDA Quantum

CUDA Quantum Python wheels are available on PyPI.org. To install the latest release, simply run

pip install cuda-quantum

At this time, wheels are distributed for Linux operating systems only. To build the CUDA Quantum Python API from source using pip:

git clone https://github.com/NVIDIA/cuda-quantum.git
cd cuda-quantum && ./scripts/install_prerequisites.sh
pip install .

For more information about building the entire C++ and Python API's, please see the CUDA Quantum documentation.

Running CUDA Quantum

You should now be able to import CUDA Quantum and start building quantum programs in Python!

import cudaq

kernel = cudaq.make_kernel()
qubit = kernel.qalloc()
kernel.x(qubit)
kernel.mz()

result = cudaq.sample(kernel)

Documentation

To see more examples, go to python examples, or check out the Python API reference.

Contributing

There are many ways in which you can get involved with CUDA Quantum. If you are interested in developing quantum applications with CUDA Quantum, our GitHub repository is a great place to get started! For more information about contributing to the CUDA Quantum platform, please take a look at Contributing.md.

License

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

CUDA Quantum is an open source project. The source code is available on GitHub and licensed under Apache License 2.0. CUDA Quantum makes use of the NVIDIA cuQuantum SDK to enable high-performance simulation, which is held to its own respective license.

Feedback

Please let us know your feedback and ideas for the CUDA Quantum platform in the Discussions tab of our GitHub repository, or file an issue. To report security concerns please reach out to cuda-quantum@nvidia.com.

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

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

cuda_quantum-0.4.0-cp311-cp311-manylinux_2_28_x86_64.whl (54.6 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.28+ x86-64

cuda_quantum-0.4.0-cp310-cp310-manylinux_2_28_x86_64.whl (54.6 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.28+ x86-64

cuda_quantum-0.4.0-cp39-cp39-manylinux_2_28_x86_64.whl (54.6 MB view details)

Uploaded CPython 3.9manylinux: glibc 2.28+ x86-64

cuda_quantum-0.4.0-cp38-cp38-manylinux_2_28_x86_64.whl (54.6 MB view details)

Uploaded CPython 3.8manylinux: glibc 2.28+ x86-64

File details

Details for the file cuda_quantum-0.4.0-cp311-cp311-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for cuda_quantum-0.4.0-cp311-cp311-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 9ed67ec9b18d64496c5922a9fc6a78f80b9a27d29c7ad2c151996282ed1ea5d2
MD5 a291936f7fe5d6e7b069e6c922ff4cf2
BLAKE2b-256 262a2cea93a734351429ea3f2cfacc2071c94589efe95c167d29727a4fad0110

See more details on using hashes here.

File details

Details for the file cuda_quantum-0.4.0-cp310-cp310-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for cuda_quantum-0.4.0-cp310-cp310-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 22724366a3d069e51411ca7f476a912473bab1fa01a5dff3a2a2f2741e53c86f
MD5 88632bfdad2396e7ba2ae51184ad7707
BLAKE2b-256 052ae708379414af55454bb745afac06b5df233f7f19f3b393762feb63a83987

See more details on using hashes here.

File details

Details for the file cuda_quantum-0.4.0-cp39-cp39-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for cuda_quantum-0.4.0-cp39-cp39-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 ae2f9cb2721759f2abd392be6f52f8f955c2e234715d51774b7d2307850ac5f5
MD5 a842c47d37f6f7219fa0c4c0f3c6bbcb
BLAKE2b-256 1eebfc440c6490a3a7de2fb3aab3a64ab0712bbdaff01ebd73ba716b78bdcc9e

See more details on using hashes here.

File details

Details for the file cuda_quantum-0.4.0-cp38-cp38-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for cuda_quantum-0.4.0-cp38-cp38-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 def7083b1ace978e283ec75260d34f6e5accc4f951b4826a29171c244f5328af
MD5 066809df15119dbfef2fd4d7c4b5558c
BLAKE2b-256 044ec5be3c0b27b74b53f7385cac6ec912d5f69fb62a02d04067dc50deeafc2d

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