# PyQuafu
Python toolkit for submitting quantum circuits on the superconducting quantum computing cloud [Quafu](http://quafu.baqis.ac.cn/).
## Introduction
PyQuafu is developed for the users of [Quafu](http://quafu.baqis.ac.cn/) 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](http://quafu.baqis.ac.cn/).
## Installation
You can directly install via PyPI,
```
pip install pyquafu
```
or build from source
```
pip install -r requirements.txt
python setup.py install
```
## GPU support
To install PyQuafu with GPU-based circuit simulator, you need build from the source and make sure that [CUDA Toolkit](https://developer.nvidia.com/cuda-downloads) is installed. You can run
```
python setup.py install -DUSE_GPU=ON
```
to install the GPU version. If you further have [cuQuantum](https://developer.nvidia.com/cuquantum-sdk) installed, you can install PyQuafu with cuQuantum support.
```
python setup.py install -DUSE_GPU=ON -DUSE_CUQUANTUM=ON
```
## Document
Please see the website [docs](https://scq-cloud.github.io/).
## Note
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 https://github.com/abess-team/abess/issues/310).
## Examples
### 1.quantum_rl
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.
## Authors
This project is developed by the quantum cloud computing team at the Beijing Academy of Quantum Information Sciences.
Raw data
{
"_id": null,
"home_page": "https://github.com/ScQ-Cloud/pyquafu",
"name": "pyquafu",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.8",
"maintainer_email": "",
"keywords": "",
"author": "ssli",
"author_email": "ssli@iphy.ac.cn",
"download_url": "",
"platform": null,
"description": "# PyQuafu\n\nPython toolkit for submitting quantum circuits on the superconducting quantum computing cloud [Quafu](http://quafu.baqis.ac.cn/). \n\n\n## Introduction\n\nPyQuafu is developed for the users of [Quafu](http://quafu.baqis.ac.cn/) 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](http://quafu.baqis.ac.cn/). \n\n## Installation\n\nYou can directly install via PyPI,\n\n```\npip install pyquafu \n```\n \nor build from source\n\n```\npip install -r requirements.txt\npython setup.py install\n```\n\n## GPU support\nTo install PyQuafu with GPU-based circuit simulator, you need build from the source and make sure that [CUDA Toolkit](https://developer.nvidia.com/cuda-downloads) is installed. You can run\n\n```\npython setup.py install -DUSE_GPU=ON\n```\nto install the GPU version. If you further have [cuQuantum](https://developer.nvidia.com/cuquantum-sdk) installed, you can install PyQuafu with cuQuantum support.\n```\npython setup.py install -DUSE_GPU=ON -DUSE_CUQUANTUM=ON\n```\n\n\n## Document\nPlease see the website [docs](https://scq-cloud.github.io/).\n\n## Note\nIf 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 https://github.com/abess-team/abess/issues/310).\n\n## Examples\n\n### 1.quantum_rl\n\nThe example shows quantum reinforcement learning interacts with Quafu to solve CartPole environment. \n\nRefer to https://github.com/enchanted123/quantum-RL-with-quafu for more details.\n\n## Authors\nThis project is developed by the quantum cloud computing team at the Beijing Academy of Quantum Information Sciences.\n",
"bugtrack_url": null,
"license": "Apache-2.0 License",
"summary": "Python toolkit for Quafu-Cloud",
"version": "0.3.6",
"project_urls": {
"Homepage": "https://github.com/ScQ-Cloud/pyquafu"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "601c97a0bd7354cace20eb9d00408011a07f6f5f19b99cfd6f0d7e0f86414e4c",
"md5": "2aad6f41eb7358c6fadc7a1c6b4c510a",
"sha256": "4c3173abb0488843284c1613b4007bf07b73b2cb4c2903adb3143777e0c42ff3"
},
"downloads": -1,
"filename": "pyquafu-0.3.6-cp310-cp310-macosx_10_9_x86_64.whl",
"has_sig": false,
"md5_digest": "2aad6f41eb7358c6fadc7a1c6b4c510a",
"packagetype": "bdist_wheel",
"python_version": "cp310",
"requires_python": ">=3.8",
"size": 181161,
"upload_time": "2023-10-28T08:24:24",
"upload_time_iso_8601": "2023-10-28T08:24:24.351499Z",
"url": "https://files.pythonhosted.org/packages/60/1c/97a0bd7354cace20eb9d00408011a07f6f5f19b99cfd6f0d7e0f86414e4c/pyquafu-0.3.6-cp310-cp310-macosx_10_9_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "221941a428a4b0aeca7eaf34c57b8ba872e8d04cffc08146b925178b035f266e",
"md5": "8bc8d4f5b0a8bdf1cb77e12b03209b0a",
"sha256": "f4e6d8b6e0bd5835515abbe2fb6ee0e91014014a84d8243dc88be97a62712825"
},
"downloads": -1,
"filename": "pyquafu-0.3.6-cp310-cp310-macosx_11_0_arm64.whl",
"has_sig": false,
"md5_digest": "8bc8d4f5b0a8bdf1cb77e12b03209b0a",
"packagetype": "bdist_wheel",
"python_version": "cp310",
"requires_python": ">=3.8",
"size": 170909,
"upload_time": "2023-10-28T08:24:18",
"upload_time_iso_8601": "2023-10-28T08:24:18.142749Z",
"url": "https://files.pythonhosted.org/packages/22/19/41a428a4b0aeca7eaf34c57b8ba872e8d04cffc08146b925178b035f266e/pyquafu-0.3.6-cp310-cp310-macosx_11_0_arm64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "560305ddb547df33641a122e55ba6d946e25f377e7ea1664fc66396bd01fefc8",
"md5": "8d36db90963f3f75607f9ba883c05353",
"sha256": "3f69e6ee9e25cf4a7bb74751be734094e870eb2f2af650f09652cf0a66b76bc8"
},
"downloads": -1,
"filename": "pyquafu-0.3.6-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
"has_sig": false,
"md5_digest": "8d36db90963f3f75607f9ba883c05353",
"packagetype": "bdist_wheel",
"python_version": "cp310",
"requires_python": ">=3.8",
"size": 307662,
"upload_time": "2023-10-28T08:23:42",
"upload_time_iso_8601": "2023-10-28T08:23:42.558858Z",
"url": "https://files.pythonhosted.org/packages/56/03/05ddb547df33641a122e55ba6d946e25f377e7ea1664fc66396bd01fefc8/pyquafu-0.3.6-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "bc4de7c3ebac5ce8249103da6410501630bf503118e51f168204324902bdc4c2",
"md5": "2f0a5def42ebba12506008591370563b",
"sha256": "88349326a3a09d0337dc2d98601628661d37674884c9cfca2540f616b42a8a3f"
},
"downloads": -1,
"filename": "pyquafu-0.3.6-cp310-cp310-win_amd64.whl",
"has_sig": false,
"md5_digest": "2f0a5def42ebba12506008591370563b",
"packagetype": "bdist_wheel",
"python_version": "cp310",
"requires_python": ">=3.8",
"size": 196859,
"upload_time": "2023-10-28T08:24:55",
"upload_time_iso_8601": "2023-10-28T08:24:55.677418Z",
"url": "https://files.pythonhosted.org/packages/bc/4d/e7c3ebac5ce8249103da6410501630bf503118e51f168204324902bdc4c2/pyquafu-0.3.6-cp310-cp310-win_amd64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "4292e8f52d048bbcc01b71a7cdb6735dfd640235c90bd37647c18b67e43f7c66",
"md5": "67aa8896d4fa143dc69c135fb51ddf94",
"sha256": "094d6320babae2f6ec61bc0108c5f858f767d310383a5e8aed45b3b3616a54ff"
},
"downloads": -1,
"filename": "pyquafu-0.3.6-cp311-cp311-macosx_10_9_x86_64.whl",
"has_sig": false,
"md5_digest": "67aa8896d4fa143dc69c135fb51ddf94",
"packagetype": "bdist_wheel",
"python_version": "cp311",
"requires_python": ">=3.8",
"size": 181162,
"upload_time": "2023-10-28T08:25:47",
"upload_time_iso_8601": "2023-10-28T08:25:47.874305Z",
"url": "https://files.pythonhosted.org/packages/42/92/e8f52d048bbcc01b71a7cdb6735dfd640235c90bd37647c18b67e43f7c66/pyquafu-0.3.6-cp311-cp311-macosx_10_9_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "e21a231a53c97c6c38f5d6b7c77385e2f308f8cde9d2f126af9247ff40d727a2",
"md5": "522ca0a5461ae12f0b0a213479130730",
"sha256": "3a311a9d23d8114151202396a56df23154e5a561801de53cee213828126dfceb"
},
"downloads": -1,
"filename": "pyquafu-0.3.6-cp311-cp311-macosx_11_0_arm64.whl",
"has_sig": false,
"md5_digest": "522ca0a5461ae12f0b0a213479130730",
"packagetype": "bdist_wheel",
"python_version": "cp311",
"requires_python": ">=3.8",
"size": 170900,
"upload_time": "2023-10-28T08:23:54",
"upload_time_iso_8601": "2023-10-28T08:23:54.465262Z",
"url": "https://files.pythonhosted.org/packages/e2/1a/231a53c97c6c38f5d6b7c77385e2f308f8cde9d2f126af9247ff40d727a2/pyquafu-0.3.6-cp311-cp311-macosx_11_0_arm64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "f8e0f219672cd8ada2f1a144b4d511c4c992c04dccafa5ede99a559f8eb99b7d",
"md5": "2e659db068478ae107bf0085168ff520",
"sha256": "4a585a83641a81eb317f00cbaec254aea4a621bccb91efcec4ccb29b495d03ce"
},
"downloads": -1,
"filename": "pyquafu-0.3.6-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
"has_sig": false,
"md5_digest": "2e659db068478ae107bf0085168ff520",
"packagetype": "bdist_wheel",
"python_version": "cp311",
"requires_python": ">=3.8",
"size": 307618,
"upload_time": "2023-10-28T08:23:44",
"upload_time_iso_8601": "2023-10-28T08:23:44.259004Z",
"url": "https://files.pythonhosted.org/packages/f8/e0/f219672cd8ada2f1a144b4d511c4c992c04dccafa5ede99a559f8eb99b7d/pyquafu-0.3.6-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "bf8cbe3da845aeb0a6c2791909a9be587675d9a5d79d2f4891cf2039c376e208",
"md5": "af0e5b04f79a2f4fec803d2b7194b427",
"sha256": "8562b2a662df2a2e021b46be1ac44b6d276f5970bf5a7443656dca72df7010aa"
},
"downloads": -1,
"filename": "pyquafu-0.3.6-cp311-cp311-win_amd64.whl",
"has_sig": false,
"md5_digest": "af0e5b04f79a2f4fec803d2b7194b427",
"packagetype": "bdist_wheel",
"python_version": "cp311",
"requires_python": ">=3.8",
"size": 196893,
"upload_time": "2023-10-28T08:24:52",
"upload_time_iso_8601": "2023-10-28T08:24:52.314716Z",
"url": "https://files.pythonhosted.org/packages/bf/8c/be3da845aeb0a6c2791909a9be587675d9a5d79d2f4891cf2039c376e208/pyquafu-0.3.6-cp311-cp311-win_amd64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "c82635bc2122269501112783d27d09c7432eb07ec0c2619101e8eb6adba12b2d",
"md5": "274978079f6c719918583483b6fa0f68",
"sha256": "faa45cdda1f1bd7ee841184f52412bcc65fb4e013b2f1358d5591cd4fb9f4886"
},
"downloads": -1,
"filename": "pyquafu-0.3.6-cp38-cp38-macosx_10_9_x86_64.whl",
"has_sig": false,
"md5_digest": "274978079f6c719918583483b6fa0f68",
"packagetype": "bdist_wheel",
"python_version": "cp38",
"requires_python": ">=3.8",
"size": 181137,
"upload_time": "2023-10-28T08:26:38",
"upload_time_iso_8601": "2023-10-28T08:26:38.921044Z",
"url": "https://files.pythonhosted.org/packages/c8/26/35bc2122269501112783d27d09c7432eb07ec0c2619101e8eb6adba12b2d/pyquafu-0.3.6-cp38-cp38-macosx_10_9_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "9ee1ddb1929bc27cced0389b91df8ca2f6aacadf9fc0ab6c94f074b06c60ef21",
"md5": "80f440305f01f5ad976a2688c78fafcb",
"sha256": "bc84db955978d556d53db0d6e4a0e4882a0bd5e9c217a437de79df9010978598"
},
"downloads": -1,
"filename": "pyquafu-0.3.6-cp38-cp38-macosx_11_0_arm64.whl",
"has_sig": false,
"md5_digest": "80f440305f01f5ad976a2688c78fafcb",
"packagetype": "bdist_wheel",
"python_version": "cp38",
"requires_python": ">=3.8",
"size": 170833,
"upload_time": "2023-10-28T08:24:16",
"upload_time_iso_8601": "2023-10-28T08:24:16.608068Z",
"url": "https://files.pythonhosted.org/packages/9e/e1/ddb1929bc27cced0389b91df8ca2f6aacadf9fc0ab6c94f074b06c60ef21/pyquafu-0.3.6-cp38-cp38-macosx_11_0_arm64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "7d3eda34afad20781c87b7ed70541ba135355a26a3fa057d2ae2184f996cbc14",
"md5": "2cf06f3c61fb0836ae1eef364b4f033e",
"sha256": "501ccbf0b070fa8f416f152ade25f1d721113217e090d5861cb9efc9947561dd"
},
"downloads": -1,
"filename": "pyquafu-0.3.6-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
"has_sig": false,
"md5_digest": "2cf06f3c61fb0836ae1eef364b4f033e",
"packagetype": "bdist_wheel",
"python_version": "cp38",
"requires_python": ">=3.8",
"size": 307477,
"upload_time": "2023-10-28T08:23:47",
"upload_time_iso_8601": "2023-10-28T08:23:47.854808Z",
"url": "https://files.pythonhosted.org/packages/7d/3e/da34afad20781c87b7ed70541ba135355a26a3fa057d2ae2184f996cbc14/pyquafu-0.3.6-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "7fb028c5e4ee8a89a856f252254084ae358b24483ddc19669785565361dfea4a",
"md5": "ff17a1305d44afbaf94c25380beae1e3",
"sha256": "aa0ddf6bfc311e9e458f83625ca1527b0690ac8fa07063527f344d87c1a739b9"
},
"downloads": -1,
"filename": "pyquafu-0.3.6-cp38-cp38-win_amd64.whl",
"has_sig": false,
"md5_digest": "ff17a1305d44afbaf94c25380beae1e3",
"packagetype": "bdist_wheel",
"python_version": "cp38",
"requires_python": ">=3.8",
"size": 196603,
"upload_time": "2023-10-28T08:25:48",
"upload_time_iso_8601": "2023-10-28T08:25:48.188749Z",
"url": "https://files.pythonhosted.org/packages/7f/b0/28c5e4ee8a89a856f252254084ae358b24483ddc19669785565361dfea4a/pyquafu-0.3.6-cp38-cp38-win_amd64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "8f0d351592f5db108069b92fa69874b6f78cd409f5d967ce771284301ed03ff3",
"md5": "7a033ea71d664b058c2fd7b6f7a5e30b",
"sha256": "97172514e34338fe30bcdc19ef71deeb93880567ac488812648251b730f42e2a"
},
"downloads": -1,
"filename": "pyquafu-0.3.6-cp39-cp39-macosx_10_9_x86_64.whl",
"has_sig": false,
"md5_digest": "7a033ea71d664b058c2fd7b6f7a5e30b",
"packagetype": "bdist_wheel",
"python_version": "cp39",
"requires_python": ">=3.8",
"size": 181286,
"upload_time": "2023-10-28T08:26:36",
"upload_time_iso_8601": "2023-10-28T08:26:36.034266Z",
"url": "https://files.pythonhosted.org/packages/8f/0d/351592f5db108069b92fa69874b6f78cd409f5d967ce771284301ed03ff3/pyquafu-0.3.6-cp39-cp39-macosx_10_9_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "8e8c6a50a44d0349ee83e431182cb2304f195633e49106fc98aa3d6e0a5a0c12",
"md5": "4a6bf82794f12ef41c9bc0da7b52123c",
"sha256": "8569def353a02b5930266766cc9852bc02708a24803bd0674a20a6b5d9dab872"
},
"downloads": -1,
"filename": "pyquafu-0.3.6-cp39-cp39-macosx_11_0_arm64.whl",
"has_sig": false,
"md5_digest": "4a6bf82794f12ef41c9bc0da7b52123c",
"packagetype": "bdist_wheel",
"python_version": "cp39",
"requires_python": ">=3.8",
"size": 170976,
"upload_time": "2023-10-28T08:24:24",
"upload_time_iso_8601": "2023-10-28T08:24:24.838348Z",
"url": "https://files.pythonhosted.org/packages/8e/8c/6a50a44d0349ee83e431182cb2304f195633e49106fc98aa3d6e0a5a0c12/pyquafu-0.3.6-cp39-cp39-macosx_11_0_arm64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "9c3648db11e19698f0228bea150455fc6fefc663f40ac8579402483f537d375a",
"md5": "2d03b6fb6f23e71973d6b9178ead1594",
"sha256": "0df20e99f6822dc65fe9231951404a06de1807a3900e2c7ede627c9bec349530"
},
"downloads": -1,
"filename": "pyquafu-0.3.6-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
"has_sig": false,
"md5_digest": "2d03b6fb6f23e71973d6b9178ead1594",
"packagetype": "bdist_wheel",
"python_version": "cp39",
"requires_python": ">=3.8",
"size": 307708,
"upload_time": "2023-10-28T08:23:43",
"upload_time_iso_8601": "2023-10-28T08:23:43.700072Z",
"url": "https://files.pythonhosted.org/packages/9c/36/48db11e19698f0228bea150455fc6fefc663f40ac8579402483f537d375a/pyquafu-0.3.6-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "930791042033eb38fce666ae3c7bf354f17354e0509ddfac8610ff90f84a1055",
"md5": "aa622942dd3b2fb59d86152ae4dad8fe",
"sha256": "8ac59860bcc717b447343522a6d9ba59c2ef3c636897c977391a69569a94fecd"
},
"downloads": -1,
"filename": "pyquafu-0.3.6-cp39-cp39-win_amd64.whl",
"has_sig": false,
"md5_digest": "aa622942dd3b2fb59d86152ae4dad8fe",
"packagetype": "bdist_wheel",
"python_version": "cp39",
"requires_python": ">=3.8",
"size": 196721,
"upload_time": "2023-10-28T08:25:00",
"upload_time_iso_8601": "2023-10-28T08:25:00.671219Z",
"url": "https://files.pythonhosted.org/packages/93/07/91042033eb38fce666ae3c7bf354f17354e0509ddfac8610ff90f84a1055/pyquafu-0.3.6-cp39-cp39-win_amd64.whl",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-10-28 08:24:24",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "ScQ-Cloud",
"github_project": "pyquafu",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"requirements": [
{
"name": "ipython",
"specs": [
[
">=",
"8.14.0"
]
]
},
{
"name": "matplotlib",
"specs": [
[
">=",
"3.5.2"
]
]
},
{
"name": "networkx",
"specs": [
[
">=",
"2.6.3"
]
]
},
{
"name": "numpy",
"specs": [
[
">=",
"1.20.3"
]
]
},
{
"name": "requests",
"specs": [
[
">=",
"2.26.0"
]
]
},
{
"name": "scipy",
"specs": [
[
">=",
"1.8.1"
]
]
},
{
"name": "setuptools",
"specs": [
[
">=",
"58.0.4"
]
]
},
{
"name": "sparse",
"specs": [
[
">=",
"0.13.0"
]
]
},
{
"name": "scikit-build",
"specs": [
[
">=",
"0.16.1"
]
]
},
{
"name": "pybind11",
"specs": [
[
">=",
"2.10.3"
]
]
},
{
"name": "graphviz",
"specs": [
[
">=",
"0.14.2"
]
]
},
{
"name": "ply",
"specs": [
[
"~=",
"3.11"
]
]
},
{
"name": "Pillow",
"specs": [
[
"~=",
"10.0.0"
]
]
}
],
"lcname": "pyquafu"
}