Python toolkit for submitting quantum circuits on the superconducting quantum computing cloud Quafu.
PyQuafu is developed for the users of Quafu to construct, compile and execute quantum circuits on real quantum devices. One can use PyQuafu to interact with different quantum backends provides by the experimental group of Quafu.
You can directly install via PyPI,
pip install pyquafu
or build from source
pip install -r requirements.txt
python setup.py install
Note that we visualize DAG(directed acyclic graph) through python package graphviz
. And if you need it, make sure Graphviz software being installed on your system. Refer to graphviz · PyPI for installation guidance.
To install PyQuafu with GPU-based circuit simulator, you need build from the source and make sure that CUDA Toolkit is installed. You can run
python setup.py install -DUSE_GPU=ON
to install the GPU version. If you further have cuQuantum installed, you can install PyQuafu with cuQuantum support.
python setup.py install -DUSE_GPU=ON -DUSE_CUQUANTUM=ON
Please see the website docs.
If you are using an Apple silicon Mac and meet the error "illegal hardware instruction", please confirm whether you have updated to the arm64 version of Anaconda (see abess-team/abess#310).
The example shows quantum reinforcement learning interacts with Quafu to solve CartPole environment.
Refer to https://github.com/enchanted123/quantum-RL-with-quafu for more details.
This project is developed by the quantum cloud computing team at the Beijing Academy of Quantum Information Sciences and Shandong Yunhai Guochuang Innovative Technology Co., Ltd.