Name | bosonic-qiskit JSON |
Version |
13.1
JSON |
| download |
home_page | None |
Summary | National Quantum Initiative Co-design Center for Quantum Advantage bosonic Qiskit simulator |
upload_time | 2024-11-13 23:34:52 |
maintainer | None |
docs_url | None |
author | None |
requires_python | >=3.9 |
license | Copyright 2022 Battelle Memorial Institute Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
keywords |
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
# Bosonic Qiskit
NQI C2QA project to simulate hybrid boson-qubit systems within QisKit.
## Install
Use a Python virtual environment to install compatible version of QisKit.
```bash
git clone https://github.com/C2QA/bosonic-qiskit.git
cd bosonic-qiskit
./install-dependencies.sh
```
### Dependency Version Compatibility
The Bosonic Qiskit software has not been extensively tested with different versions of its [dependencies](requirements.txt); however, some success has been achieved with both newer and older versions of Qiskit. Do note that some features require newer versions. For example, the noise modelling requires Qiskit v0.34.2+. Using older versions will cause `ModuleNotFoudError` at runtime.
## Activate Virtual Environment
Before using Bosonic Qiskit, first install the depencies (as above) and then activate the Python virtual environment.
```bash
cd <path/to/bosonic-qiskit>
source venv/bin/activate
```
## Tutorials
Jupyter Notebook tutorials can be found in the [tutorials](tutorials) folder. JupyterLab is a dependency found in [requirements.txt](requirements.txt), so after installing and activating the virtual environment, to run the tutorials simply start Jupyter with `jupyter lab` and then navigate to the desired tutorial.
See our paper presented at IEEE HPEC 2022 on [arXiv](https://arxiv.org/abs/2209.11153) for more information on using bosonic-qiskit.
## How to add gates
The code is structured to separate generation of the operator matrices from creating instances of QisKit Gate.
The first step in adding a new gate is to develop software to build a unitary operator matrix. These matrices must be unitary in order for QisKit to simulate them. Non unitary matrices will fail during simulation. Existing operator matrices are built in the CVOperators class found in [operators.py](c2qa/operators.py). Included in CVOperators are functions to build the bosonic creation and annihilation operators based on a provided cutoff. The order of the data in your operators must match the order of the qumodes (QisKit qubits) sent in as QisKit gate parameters found in [circuit.py](c2qa/circuit.py), as described next.
Once you've written software to build the operator matrix, a new function is added to the CVCircuit class found in [circuit.py](c2qa/circuit.py). This class extends the QisKit QuantumCircuit class to add the bosonic gates available in this library. The previusly defined operators are parameterized by user input, as needed, and appended to the QuantumCircuit as unitary gates. The CVCircuit class includes functions to easily make your new gates conditional based on a control qubit.
See examples of software building new gates in the previously mentioned [operators.py](c2qa/operators.py) and [circuit.py](c2qa/circuit.py). Examples using the library's gates can be found in both the PyTest [test cases](tests) and Jupyter Notebook [tutorials](tutorials) folders
## Available Gates
Current gates available for simulation are documented at https://c2qa.github.io/bosonic-qiskit/c2qa.circuit.CVCircuit.html
Raw data
{
"_id": null,
"home_page": null,
"name": "bosonic-qiskit",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.9",
"maintainer_email": null,
"keywords": null,
"author": null,
"author_email": "Tim Stavenger <timothy.stavenger@pnnl.gov>",
"download_url": "https://files.pythonhosted.org/packages/eb/48/1471a7ab62aad48d775e6ef56e520c67aefecb01a90fc9898cff3dbb6492/bosonic_qiskit-13.1.tar.gz",
"platform": null,
"description": "# Bosonic Qiskit\n\nNQI C2QA project to simulate hybrid boson-qubit systems within QisKit.\n\n## Install\n\nUse a Python virtual environment to install compatible version of QisKit.\n\n```bash\ngit clone https://github.com/C2QA/bosonic-qiskit.git\ncd bosonic-qiskit\n./install-dependencies.sh\n```\n\n### Dependency Version Compatibility\n\nThe Bosonic Qiskit software has not been extensively tested with different versions of its [dependencies](requirements.txt); however, some success has been achieved with both newer and older versions of Qiskit. Do note that some features require newer versions. For example, the noise modelling requires Qiskit v0.34.2+. Using older versions will cause `ModuleNotFoudError` at runtime.\n\n## Activate Virtual Environment\n\nBefore using Bosonic Qiskit, first install the depencies (as above) and then activate the Python virtual environment.\n\n```bash\ncd <path/to/bosonic-qiskit>\nsource venv/bin/activate\n```\n\n## Tutorials\n\nJupyter Notebook tutorials can be found in the [tutorials](tutorials) folder. JupyterLab is a dependency found in [requirements.txt](requirements.txt), so after installing and activating the virtual environment, to run the tutorials simply start Jupyter with `jupyter lab` and then navigate to the desired tutorial.\n\nSee our paper presented at IEEE HPEC 2022 on [arXiv](https://arxiv.org/abs/2209.11153) for more information on using bosonic-qiskit.\n\n## How to add gates\n\nThe code is structured to separate generation of the operator matrices from creating instances of QisKit Gate. \n\nThe first step in adding a new gate is to develop software to build a unitary operator matrix. These matrices must be unitary in order for QisKit to simulate them. Non unitary matrices will fail during simulation. Existing operator matrices are built in the CVOperators class found in [operators.py](c2qa/operators.py). Included in CVOperators are functions to build the bosonic creation and annihilation operators based on a provided cutoff. The order of the data in your operators must match the order of the qumodes (QisKit qubits) sent in as QisKit gate parameters found in [circuit.py](c2qa/circuit.py), as described next.\n\nOnce you've written software to build the operator matrix, a new function is added to the CVCircuit class found in [circuit.py](c2qa/circuit.py). This class extends the QisKit QuantumCircuit class to add the bosonic gates available in this library. The previusly defined operators are parameterized by user input, as needed, and appended to the QuantumCircuit as unitary gates. The CVCircuit class includes functions to easily make your new gates conditional based on a control qubit.\n\nSee examples of software building new gates in the previously mentioned [operators.py](c2qa/operators.py) and [circuit.py](c2qa/circuit.py). Examples using the library's gates can be found in both the PyTest [test cases](tests) and Jupyter Notebook [tutorials](tutorials) folders\n\n## Available Gates\n\nCurrent gates available for simulation are documented at https://c2qa.github.io/bosonic-qiskit/c2qa.circuit.CVCircuit.html\n",
"bugtrack_url": null,
"license": "Copyright 2022 Battelle Memorial Institute Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ",
"summary": "National Quantum Initiative Co-design Center for Quantum Advantage bosonic Qiskit simulator",
"version": "13.1",
"project_urls": {
"Homepage": "https://github.com/C2QA/bosonic-qiskit",
"Issues": "https://github.com/C2QA/bosonic-qiskit/issues"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "eb7e298e6ba7b6a231bbab05b0e370dc49849de13c363069ccf75eae6fe8366f",
"md5": "e184932485138f35eb61659b63c98b66",
"sha256": "9b7515a16435c88ec234137893f299d2a1c2803e7ebfbc7186d4ee6b068db306"
},
"downloads": -1,
"filename": "bosonic_qiskit-13.1-py3-none-any.whl",
"has_sig": false,
"md5_digest": "e184932485138f35eb61659b63c98b66",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.9",
"size": 37851,
"upload_time": "2024-11-13T23:34:50",
"upload_time_iso_8601": "2024-11-13T23:34:50.831196Z",
"url": "https://files.pythonhosted.org/packages/eb/7e/298e6ba7b6a231bbab05b0e370dc49849de13c363069ccf75eae6fe8366f/bosonic_qiskit-13.1-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "eb481471a7ab62aad48d775e6ef56e520c67aefecb01a90fc9898cff3dbb6492",
"md5": "10a7b740a8fc802d6eab95b7171cac9f",
"sha256": "76647c7cf69060e60bbf0a31890093cdacef138dbdd6e6f52455630dabc150fe"
},
"downloads": -1,
"filename": "bosonic_qiskit-13.1.tar.gz",
"has_sig": false,
"md5_digest": "10a7b740a8fc802d6eab95b7171cac9f",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.9",
"size": 47142,
"upload_time": "2024-11-13T23:34:52",
"upload_time_iso_8601": "2024-11-13T23:34:52.499835Z",
"url": "https://files.pythonhosted.org/packages/eb/48/1471a7ab62aad48d775e6ef56e520c67aefecb01a90fc9898cff3dbb6492/bosonic_qiskit-13.1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-11-13 23:34:52",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "C2QA",
"github_project": "bosonic-qiskit",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"requirements": [],
"lcname": "bosonic-qiskit"
}