Skip to main content

A package for GRAPE with feedback

Project description

feedbackGRAPE

This is the main repository for the feedbackGRAPE package (under development), eventually offering:

  • vectorized, GPU-enabled, differentiable simulations of driven dissipative quantum systems via jax
  • efficient quantum optimal control (gradient-ascent pulse engineering, GRAPE)
  • including feedback (using the newly developed feedbackGRAPE approach)

Think of parallelized, highly efficient qutip with feedback control.

Installation

To install dependencies necessary for the package
pip install -U -r requirements.txt
To install dependencies necessary for testing, linting, formating, ...
pip install -U -r requirements_dev.txt
To be able to render the jupyter notebooks, make sure to install pandoc, in conda the command is:
conda install conda-forge::pandoc
To be able to run your code on GPUs please make sure to install jax[cuda12] using the following command:
pip install -U "jax[cuda12]==0.5.2" or
pip install -U -r requirements_gpu.txt

Documentation

For Development: Enter the command cd docs then make html and then open index.html in docs/build/html with Live Server to take a look at the Documentaion.

Testing

Simply type pytest. This would also generate a coverage report.

checking for dynamically typed errors

Simply type mypy feedback_grape. This would give you type checking errors if any.

linting and formating

For Linting ruff check
For Formating ruff format

Before Commiting and Pushing

Simply type tox. This would test the code on different environments.

References

FeedbackGRAPE was introduced in Porotti, Peano, Marquardt, PRX Quantum 4, 030305 (2023). It enables the addition of feedback to GRAPE-style numerical quantum optimal control, important for modern tasks like quantum state stabilization or quantum error correction. In addition, it is formulated in such a way that the use of neural networks and modern autodifferentiation frameworks is easy. See a first full-fledged application to the Gottesman-Kitaev-Preskill bosonic code quantum error correction in Puviani et al, Phys. Rev. Lett. 134, 020601 (2025). Both of these papers come with github repositories, but with code specialized to the examples and use cases: rporotti/feedback_grape and Matteo-Puviani/GQF. The purpose of the framework offered in this repository here is to make it very easy for everyone to do the same for their own problems, with minimum overhead.

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

feedback_grape-0.0.1.tar.gz (39.0 kB view details)

Uploaded Source

Built Distribution

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

feedback_grape-0.0.1-py3-none-any.whl (31.2 kB view details)

Uploaded Python 3

File details

Details for the file feedback_grape-0.0.1.tar.gz.

File metadata

  • Download URL: feedback_grape-0.0.1.tar.gz
  • Upload date:
  • Size: 39.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for feedback_grape-0.0.1.tar.gz
Algorithm Hash digest
SHA256 ed3319aaa68b4652c20cce568e2e05108c3ebb052cd2946df1fe54895af90e91
MD5 40000a0ec051d40ad52fe06272b2c20b
BLAKE2b-256 07f712e31e540bd27b39983ce692298b9a0761650e4d23f207e86faf4b9bc967

See more details on using hashes here.

Provenance

The following attestation bundles were made for feedback_grape-0.0.1.tar.gz:

Publisher: publish_to_pypi.yml on YousefElbrolosy/feedbackGRAPE

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file feedback_grape-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: feedback_grape-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 31.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for feedback_grape-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 eb560bee4e1f687827393b3bb3e2d08b287c0ab95b39da60b26b96c31adbbaae
MD5 13b5456400473d7e2307cdc61c8f15a1
BLAKE2b-256 a834aa71e6ba0820c24e86945af8195ececdfc130e52b392df93c519a9d288a1

See more details on using hashes here.

Provenance

The following attestation bundles were made for feedback_grape-0.0.1-py3-none-any.whl:

Publisher: publish_to_pypi.yml on YousefElbrolosy/feedbackGRAPE

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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