[![Unitary Fund](https://img.shields.io/badge/Supported%20By-UNITARY%20FUND-brightgreen.svg?style=for-the-badge)](http://unitary.fund)
# QuNetSim
![QuNetSim Tests](https://github.com/tqsd/QuNetSim/workflows/QuNetSim%20Tests/badge.svg)
QuNetSim is a quantum-enabled network simulator that adds common quantum networking tasks like teleportation, superdense coding, sharing EPR pairs, etc. With QuNetSim, one can design and test robust quantum network protocols under various network conditions.
## Installation and Documentation
See https://tqsd.github.io/QuNetSim/ for documentation. To install the latest release via pip:
```
pip install qunetsim
```
## Quick Start Guide
### Templater
The QuNetSim pip package comes with a templater. After installing the library, simply type `template` and follow the instructions. A template QuNetSim example will be generated.
### Quick Example
```
from qunetsim.components import Host, Network
network = Network.get_instance()
network.start()
alice = Host('Alice')
bob = Host('Bob')
alice.add_connection(bob.host_id)
bob.add_connection(alice.host_id)
alice.start()
bob.start()
network.add_hosts([alice, bob])
# Block Alice to wait for qubit arrive from Bob
alice.send_epr(bob.host_id, await_ack=True)
q_alice = alice.get_epr(bob.host_id)
q_bob = bob.get_epr(alice.host_id)
print("EPR is in state: %d, %d" % (q_alice.measure(), q_bob.measure()))
network.stop(True)
```
## Contributing
Feel free to contribute by adding Github issues and pull requests. Adding test cases for any contributions is a requirement for any pull request to be merged.
## Citation
```
@article{diadamo2020qunetsim,
title={QuNetSim: A Software Framework for Quantum Networks},
author={DiAdamo, Stephen and N{\"o}tzel, Janis and Zanger, Benjamin and Be{\c{s}}e, Mehmet Mert},
journal={IEEE Transactions on Quantum Engineering},
year={2021},
doi={10.1109/TQE.2021.3092395}
}
```
Raw data
{
"_id": null,
"home_page": "https://github.com/tqsd/QuNetSim",
"name": "qunetsim",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.6",
"maintainer_email": "",
"keywords": "quantum,networks,simulator,internet,QuNetSim",
"author": "Stephen DiAdamo, Janis N\u00f6tzel, Benjamin Zanger, Mert Mehmet Bese",
"author_email": "stephen.diadamo@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/2e/77/31079e8fbed081ae53f05c5de93b2a838360d9a0e0e10373bc6a336bc15d/qunetsim-0.1.3.post1.tar.gz",
"platform": null,
"description": "[![Unitary Fund](https://img.shields.io/badge/Supported%20By-UNITARY%20FUND-brightgreen.svg?style=for-the-badge)](http://unitary.fund)\n# QuNetSim \n\n![QuNetSim Tests](https://github.com/tqsd/QuNetSim/workflows/QuNetSim%20Tests/badge.svg)\n\nQuNetSim is a quantum-enabled network simulator that adds common quantum networking tasks like teleportation, superdense coding, sharing EPR pairs, etc. With QuNetSim, one can design and test robust quantum network protocols under various network conditions.\n\n## Installation and Documentation\n\nSee https://tqsd.github.io/QuNetSim/ for documentation. To install the latest release via pip:\n```\npip install qunetsim\n```\n\n## Quick Start Guide\n\n### Templater\n\nThe QuNetSim pip package comes with a templater. After installing the library, simply type `template` and follow the instructions. A template QuNetSim example will be generated. \n\n### Quick Example\n\n```\nfrom qunetsim.components import Host, Network\n\nnetwork = Network.get_instance()\nnetwork.start()\n\nalice = Host('Alice')\nbob = Host('Bob')\n\nalice.add_connection(bob.host_id)\nbob.add_connection(alice.host_id)\n\nalice.start()\nbob.start()\n\nnetwork.add_hosts([alice, bob])\n\n# Block Alice to wait for qubit arrive from Bob\nalice.send_epr(bob.host_id, await_ack=True)\nq_alice = alice.get_epr(bob.host_id)\nq_bob = bob.get_epr(alice.host_id)\n\nprint(\"EPR is in state: %d, %d\" % (q_alice.measure(), q_bob.measure()))\nnetwork.stop(True)\n```\n\n## Contributing \n\nFeel free to contribute by adding Github issues and pull requests. Adding test cases for any contributions is a requirement for any pull request to be merged. \n\n## Citation\n```\n@article{diadamo2020qunetsim,\n title={QuNetSim: A Software Framework for Quantum Networks},\n author={DiAdamo, Stephen and N{\\\"o}tzel, Janis and Zanger, Benjamin and Be{\\c{s}}e, Mehmet Mert},\n journal={IEEE Transactions on Quantum Engineering},\n year={2021},\n doi={10.1109/TQE.2021.3092395}\n}\n```\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "A Quantum Network Simulation Framework",
"version": "0.1.3.post1",
"split_keywords": [
"quantum",
"networks",
"simulator",
"internet",
"qunetsim"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "522e98e3cd67d83dc7bfaedfb309385e6bdd5d75a3f2ff0582753e23577e08d3",
"md5": "5ca76838b30e07cf00e22d6ba2f4b4d1",
"sha256": "7b482fe6814741b2bee24e56e976e9dadc3ce47d7b4285380748b6f15964b3d4"
},
"downloads": -1,
"filename": "qunetsim-0.1.3.post1-py3-none-any.whl",
"has_sig": false,
"md5_digest": "5ca76838b30e07cf00e22d6ba2f4b4d1",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.6",
"size": 60533,
"upload_time": "2023-04-20T10:00:48",
"upload_time_iso_8601": "2023-04-20T10:00:48.638524Z",
"url": "https://files.pythonhosted.org/packages/52/2e/98e3cd67d83dc7bfaedfb309385e6bdd5d75a3f2ff0582753e23577e08d3/qunetsim-0.1.3.post1-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "2e7731079e8fbed081ae53f05c5de93b2a838360d9a0e0e10373bc6a336bc15d",
"md5": "712a87243e1596ac51d3a3ce3d171d98",
"sha256": "313e5e27f3bd75d2175d328493d8f7c0324daedea8671924a1468f299e977a73"
},
"downloads": -1,
"filename": "qunetsim-0.1.3.post1.tar.gz",
"has_sig": false,
"md5_digest": "712a87243e1596ac51d3a3ce3d171d98",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.6",
"size": 45470,
"upload_time": "2023-04-20T10:00:51",
"upload_time_iso_8601": "2023-04-20T10:00:51.054857Z",
"url": "https://files.pythonhosted.org/packages/2e/77/31079e8fbed081ae53f05c5de93b2a838360d9a0e0e10373bc6a336bc15d/qunetsim-0.1.3.post1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-04-20 10:00:51",
"github": true,
"gitlab": false,
"bitbucket": false,
"github_user": "tqsd",
"github_project": "QuNetSim",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"requirements": [],
"lcname": "qunetsim"
}