Skip to main content

Tests Coverage Documentation DOI PyPI Forum License

Catalyst is an experimental package that enables just-in-time (JIT) compilation of hybrid quantum-classical programs.

Catalyst is currently under heavy development — if you have suggestions on the API or use-cases you'd like to be covered, please open an GitHub issue or reach out. We'd love to hear about how you're using the library, collaborate on development, or integrate additional devices and frontends.

Key Features

  • Compile the entire quantum-classical workflow, including any optimization loops.

  • Use Catalyst alongside PennyLane directly from Python. Simply decorate quantum code and hybrid functions with @qjit, leading to significant performance improvements over standard Python execution.

  • Access advanced control flow that supports both quantum and classical instructions.

  • Infrastructure for both quantum and classical compilation, allowing you to compile quantum circuits that contain control flow.

  • Built to be end-to-end differentiable.

  • Support for PennyLane-Lightning high performance simulators, and Amazon Braket devices. Additional hardware support, including QPUs, to come.

Overview

Catalyst currently consists of the following components:

  • Catalyst Compiler.

    The core Catalyst compiler is built using MLIR, with the addition of a quantum dialect used to represent quantum instructions. This allows for a high-level intermediate representation of the classical and quantum components of the program, resulting in advantages during optimization. Once optimized, the compiler lowers the representation down to LLVM + QIR, and a machine binary is produced.

  • Catalyst Runtime.

    The runtime is a C++ runtime with multiple-device support based on QIR that enables the execution of Catalyst-compiled quantum programs. A complete list of all backend devices along with the quantum instruction set supported by these runtime implementations can be found by visiting the runtime documentation.

In addition, we also provide a Python frontend for PennyLane and JAX:

  • PennyLane JAX frontend.

    A Python library that provides a @qjit decorator to just-in-time compile PennyLane hybrid quantum-classical programs. In addition, the frontend package provides Python functions for defining Catalyst-compatible control flow structures, gradient, and mid-circuit measurement.

Installation

Catalyst is officially supported on Linux (x86_64, aarch64) and macOS (arm64, x86_64) platforms, and pre-built binaries are being distributed via the Python Package Index (PyPI) for Python versions 3.10 and higher. To install it, simply run the following pip command:

pip install pennylane-catalyst

If you wish to contribute to Catalyst or develop against our runtime or compiler, instructions for building from source are also available.

Trying Catalyst with PennyLane

To get started using the Catalyst JIT compiler from Python, check out our quick start guide, as well as our various examples and tutorials in our documentation.

For an introduction to quantum computing and quantum machine learning, you can also visit the PennyLane website for tutorials, videos, and demonstrations.

Roadmap

  • Frontend: As we continue to build out Catalyst, the PennyLane frontend will likely be upstreamed into PennyLane proper, providing native JIT functionality built-in to PennyLane. The Catalyst compiler and runtime will remain part of the Catalyst project. If you are interested in working on additional frontends for Catalyst, please get in touch.

  • Compiler: We will continue to build out the compiler stack, and add quantum compilation routines. This includes an API for providing or writing Catalyst-compatible compilation routines. In addition, we will be improving the autodifferentiation support, and adding support for classical autodiff, additional quantum gradients, and quantum-aware optimization methods.

  • Runtime: We will be adding support for more devices, including quantum hardware devices. In addition, we will be building out support for hetereogeneous execution. If you are interested in working on connecting a quantum device with Catalyst, please get in touch.

To get the details right, we need your help — please send us your use cases by starting a conversation, or trying Catalyst out.

Contributing to Catalyst

We welcome contributions — simply fork the Catalyst repository, and then make a pull request containing your contribution.

We also encourage bug reports, suggestions for new features and enhancements.

Support

If you are having issues, please let us know by posting the issue on our GitHub issue tracker.

We also have a PennyLane discussion forum—come join the community and chat with the PennyLane team.

Note that we are committed to providing a friendly, safe, and welcoming environment for all. Please read and respect the Code of Conduct.

Authors

Catalyst is the work of many contributors.

If you are doing research using Catalyst, please cite our paper:

@article{
  Ittah2024,
  doi = {10.21105/joss.06720},
  url = {https://doi.org/10.21105/joss.06720},
  year = {2024},
  publisher = {The Open Journal},
  volume = {9},
  number = {99},
  pages = {6720},
  author = {David Ittah and Ali Asadi and Erick Ochoa Lopez and Sergei Mironov and Samuel Banning and Romain Moyard and Mai Jacob Peng and Josh Izaac},
  title = {Catalyst: a Python JIT compiler for auto-differentiable hybrid quantum programs},
  journal = {Journal of Open Source Software}
}

License

Catalyst is free and open source, released under the Apache License, Version 2.0.

Acknowledgements

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

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.

PennyLane_Catalyst-0.10.0-cp312-abi3-manylinux_2_28_x86_64.whl (65.4 MB view details)

Uploaded CPython 3.12+manylinux: glibc 2.28+ x86-64

PennyLane_Catalyst-0.10.0-cp312-abi3-manylinux_2_28_aarch64.whl (64.9 MB view details)

Uploaded CPython 3.12+manylinux: glibc 2.28+ ARM64

PennyLane_Catalyst-0.10.0-cp312-abi3-macosx_13_0_x86_64.whl (63.1 MB view details)

Uploaded CPython 3.12+macOS 13.0+ x86-64

PennyLane_Catalyst-0.10.0-cp312-abi3-macosx_13_0_arm64.whl (56.8 MB view details)

Uploaded CPython 3.12+macOS 13.0+ ARM64

PennyLane_Catalyst-0.10.0-cp311-cp311-manylinux_2_28_x86_64.whl (65.5 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.28+ x86-64

PennyLane_Catalyst-0.10.0-cp311-cp311-manylinux_2_28_aarch64.whl (65.0 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.28+ ARM64

PennyLane_Catalyst-0.10.0-cp311-cp311-macosx_13_0_x86_64.whl (63.1 MB view details)

Uploaded CPython 3.11macOS 13.0+ x86-64

PennyLane_Catalyst-0.10.0-cp311-cp311-macosx_13_0_arm64.whl (56.8 MB view details)

Uploaded CPython 3.11macOS 13.0+ ARM64

PennyLane_Catalyst-0.10.0-cp310-cp310-manylinux_2_28_x86_64.whl (65.5 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.28+ x86-64

PennyLane_Catalyst-0.10.0-cp310-cp310-manylinux_2_28_aarch64.whl (65.0 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.28+ ARM64

PennyLane_Catalyst-0.10.0-cp310-cp310-macosx_13_0_x86_64.whl (63.1 MB view details)

Uploaded CPython 3.10macOS 13.0+ x86-64

PennyLane_Catalyst-0.10.0-cp310-cp310-macosx_13_0_arm64.whl (56.8 MB view details)

Uploaded CPython 3.10macOS 13.0+ ARM64

File details

Details for the file PennyLane_Catalyst-0.10.0-cp312-abi3-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for PennyLane_Catalyst-0.10.0-cp312-abi3-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 00f3f255e205a95854c0a83895379f33528aedaaf3b386afd8ac65f300730a03
MD5 2fef53fbf7975fc056b5c86d5fd477db
BLAKE2b-256 8321c1e4203c799f8b20ac898a04762202c963e862a122be162da174849068de

See more details on using hashes here.

File details

Details for the file PennyLane_Catalyst-0.10.0-cp312-abi3-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for PennyLane_Catalyst-0.10.0-cp312-abi3-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 9a1b34b1b922cb91a5da0671b911e3a4c33e03c1269d4c0f36b9a511e19c2d96
MD5 adc69da4b0919bb6b712a483cbfd52f3
BLAKE2b-256 8eb56d3b3cc002cb25bc9e5dec74dbc0df4ffc9f00ee56ec3db4e9ad0b876286

See more details on using hashes here.

File details

Details for the file PennyLane_Catalyst-0.10.0-cp312-abi3-macosx_13_0_x86_64.whl.

File metadata

File hashes

Hashes for PennyLane_Catalyst-0.10.0-cp312-abi3-macosx_13_0_x86_64.whl
Algorithm Hash digest
SHA256 5cd40fe9177895acd7ce6533e09ec4591d95450f619c580d4da9041ea66290eb
MD5 57f512a1156db97e1993105bc67ebc59
BLAKE2b-256 f37c847d9ab00327dca6e0ac26b2bb548fa0e901a2daf0a01e1de9e857e5aa4c

See more details on using hashes here.

File details

Details for the file PennyLane_Catalyst-0.10.0-cp312-abi3-macosx_13_0_arm64.whl.

File metadata

File hashes

Hashes for PennyLane_Catalyst-0.10.0-cp312-abi3-macosx_13_0_arm64.whl
Algorithm Hash digest
SHA256 98e4d88403c907169bde62e03ac71c30779366dfbed821ab55392223330cba95
MD5 c60af64d50279c9c4846209ac6481d4e
BLAKE2b-256 6af0f9a3487d5835e3ce6f75870024da19c6788006a099dab08818c0566c0b83

See more details on using hashes here.

File details

Details for the file PennyLane_Catalyst-0.10.0-cp311-cp311-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for PennyLane_Catalyst-0.10.0-cp311-cp311-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 49090111e111d5a126f82158b47c8b2ef1de4640efd8c86a18dbadbbe6b9e7f8
MD5 744157d60e78e949b2f11552faab30d0
BLAKE2b-256 accd92bb4396c9e6bb4145a9ef56305f018dc9db786dc93efd7ad276de9e8470

See more details on using hashes here.

File details

Details for the file PennyLane_Catalyst-0.10.0-cp311-cp311-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for PennyLane_Catalyst-0.10.0-cp311-cp311-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 041a22b5668340bdaf1cad479ba6c9495d1947abaecb471dbc0d433a4ad7a066
MD5 efa220dd668136b935113bf3daf23e45
BLAKE2b-256 35e522dac386e1404cd8d597139c3eb51a25e89cc70a0774a04b7620aa0a0f6a

See more details on using hashes here.

File details

Details for the file PennyLane_Catalyst-0.10.0-cp311-cp311-macosx_13_0_x86_64.whl.

File metadata

File hashes

Hashes for PennyLane_Catalyst-0.10.0-cp311-cp311-macosx_13_0_x86_64.whl
Algorithm Hash digest
SHA256 4ee6d691a00da586e3b6cd845e05063284e01e9db724e36cb79cb787435f44a5
MD5 a0c0fa72b80c8a79708996165571e02e
BLAKE2b-256 e003fb1187414e8c6900eb6ec578442bfae7c3b8d2dd368622214098d5e9510b

See more details on using hashes here.

File details

Details for the file PennyLane_Catalyst-0.10.0-cp311-cp311-macosx_13_0_arm64.whl.

File metadata

File hashes

Hashes for PennyLane_Catalyst-0.10.0-cp311-cp311-macosx_13_0_arm64.whl
Algorithm Hash digest
SHA256 54da27797abd94e54599f0fdcc61e28dac47fef6a2b09b9bc643b1d4b2f43e8a
MD5 2ed6690afeb4379ca724357147b30db5
BLAKE2b-256 8c2397744faa9917d10e624ac9db3a519c95a9b3f2cf731902c916ddd113d409

See more details on using hashes here.

File details

Details for the file PennyLane_Catalyst-0.10.0-cp310-cp310-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for PennyLane_Catalyst-0.10.0-cp310-cp310-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 744be1cb016b15c9a51bbc1b8ccb7fe4d11526d55b7782b8fc1533aef6c62998
MD5 152623171a2a0ab3d0f5c94264f6ede0
BLAKE2b-256 3810c8dbf10e5421a8ad56caedec300a4a105f30005d8a0e4ee4bea32b9bfa7b

See more details on using hashes here.

File details

Details for the file PennyLane_Catalyst-0.10.0-cp310-cp310-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for PennyLane_Catalyst-0.10.0-cp310-cp310-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 76e6a0609893bb58aa8a77123de23dde1883014fd7c0e552c3706def11e71c17
MD5 cb5813e0404d88ed3741dd144814f27b
BLAKE2b-256 7e44833aa31d49a20400feffb2670d58212face9878a1914ab0d292dd6545157

See more details on using hashes here.

File details

Details for the file PennyLane_Catalyst-0.10.0-cp310-cp310-macosx_13_0_x86_64.whl.

File metadata

File hashes

Hashes for PennyLane_Catalyst-0.10.0-cp310-cp310-macosx_13_0_x86_64.whl
Algorithm Hash digest
SHA256 ee6bf5cbce1bc8b3f01d97d5cd99901e820cfa4a89131ec9707f282cc74c5179
MD5 9177851cd4de6bc3d0fcaa2b760e9909
BLAKE2b-256 1c89b41a48a151df4a9247e454d09b76c2668140dbab520766f88d72ed68db96

See more details on using hashes here.

File details

Details for the file PennyLane_Catalyst-0.10.0-cp310-cp310-macosx_13_0_arm64.whl.

File metadata

File hashes

Hashes for PennyLane_Catalyst-0.10.0-cp310-cp310-macosx_13_0_arm64.whl
Algorithm Hash digest
SHA256 fb4e2c8f32cdbb0f327b0912ee5a14dc16a35d76156f1c99967129978a2bcd70
MD5 1f23854dd4482b3e342eb40c988c1141
BLAKE2b-256 93175a84c3937b49718a83a2046a3bef69d2e66f36c46a78cd6bb596ad4a45a1

See more details on using hashes here.

Release history Release notifications | RSS feed

0.15.0

6 files

0.14.1

6 files

0.14.0

6 files

0.13.0

6 files

0.12.0

9 files

0.11.0

12 files

This release

0.10.0 This release

12 files

0.9.0

12 files

0.8.1

16 files

0.7.0

16 files

0.6.0

12 files

0.5.0

12 files

0.4.1

9 files

0.3.2

9 files

0.2.1

4 files

0.1.2

1 file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page