quantumaudio


Namequantumaudio JSON
Version 0.0.2 PyPI version JSON
download
home_pageNone
Summaryquantumaudio: A Python class implementation for Quantum Representations of Audio in Qiskit. Developed by the quantum computer music team at the Interdisciplinary Centre for Computer Music Research, University of Plymouth, UK
upload_time2023-01-07 16:27:53
maintainerNone
docs_urlNone
authorNone
requires_python>=3.9
licenseNone
keywords quantum qiskit quantum computing quantum computer music audio quantum audio
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # quantumaudio
Quantumaudio Module: A Python package for Quantum Representations of Audio in qubit systems & examples

![PyPI](https://img.shields.io/pypi/v/quantumaudio) ![Read the Docs (version)](https://img.shields.io/readthedocs/quantumaudio/latest?label=API%20docs) ![GitHub](https://img.shields.io/github/license/iccmr-quantum/quantumaudio)

`quantumaudio` is a Python module with class implementations for building quantum circuits that encode and decode audio signals as quantum states. This is primarily aimed for quantum computing simulators, but it *might* also run on real quantum hardware. The main objective is to have a readily available tools for using quantum representations of audio in artistic contexts and for studying future Quantum Signal Processing algorithms for audio.

This package contains class implementations for generating quantum circuits from audio signals, as well as necessary pre and post processing functions. 

It contatins implementations for three representation algorithms cited on the publication above, namely:

- QPAM - Quantum Probability Amplitude Modulation (Simple quantum superposition or "Amplitude Encoding")
- SQPAM - Single-Qubit Probability Amplitude Modulation (similar to [FRQI](https://link.springer.com/article/10.1007/s11128-010-0177-y) quantum image representations)
- QSM - Quantum State Modulation (also known as [FRQA](https://www.researchgate.net/publication/312091720_Flexible_Representation_and_Manipulation_of_Audio_Signals_on_Quantum_Computers) in the literature)

For an introduction to quantum audio please refer to the book chapter [Quantum Representations of Sound: From Mechanical Waves to Quantum Circuits](https://link.springer.com/chapter/10.1007/978-3-031-13909-3_10) by Paulo V. ItaboraĆ­ and Eduardo R. Miranda (draft version [available at ArXiV](https://arxiv.org/pdf/2301.01595.pdf)). The chapter also discusses QPAM, SQPAM and QSM, and glances over methods to implement quantum audio signal processing. 

Additional documentaion is available [here](https://quantumaudio.readthedocs.io/en/latest/) along with a Jupyter Notebook [tutorial](https://quantumaudio.readthedocs.io/en/latest/tutorial.html) showing how the main methods work and general implementation workflow with the package. Additionally, to listen the results, there is a set of [examples](https://github.com/iccmr-quantum/quantumaudio/tree/main/examples_with_supercollider) for interfacing the quantum circuits with [SuperCollider](https://supercollider.github.io/), a powerful synthesis engine for live musical applications.

## Dependencies

The `quantumaudio` package alone has the following dependencies:

- qiskit (the quantum programming framework)
- numpy
- matplotlib
- bitstring (for decoding purposes)
- ipython (for listening purposes inside jupyter notebooks)

For running the [supercollider examples](https://github.com/iccmr-quantum/quantumaudio/tree/main/examples_with_supercollider), additional packages are needed:

- SuperCollider scsynth ([install SuperCollider](https://supercollider.github.io/downloads))
- Cython
- [pyliblo](https://pypi.org/project/pyliblo/)
- [python-supercollider client](https://pypi.org/project/supercollider/) (`pip install supercollider`)

## Installation

This python module is distributed as a package in PyPi. It can be installed in any operating system by using `pip` in a console or terminal:

- Windows
```console
pip install quantumaudio
```
- Mac & Linux
```console
pip3 install quantumaudio
```

Optionally, you can download the latest [release](https://github.com/iccmr-quantum/quantumaudio/releases), which also contains the examples and tutorial notebooks.

It is possible to install the additional python dependencies for running the supercollider examples automatically, by running the installation command with the `[examples]` optional dependencies:

- Windows
```console
pip install quantumaudio[examples]
```
- Mac & Linux
```console
pip3 install quantumaudio[examples]
```

## Jupyter Notebook Examples
Ideally, you would `pip install` the package in your own python environment and then download the latest example/tutorial files from the [releases](https://github.com/iccmr-quantum/quantumaudio/releases) page.

### NOTE
There is a known bug when installing `pyliblo` packages through `pip install quantumaudio[examples]` in some systems. A temporary workaround is shown [here](https://github.com/iccmr-quantum/quantumaudio/issues/4).

## Usage

To learn how to use this module, refer to the [tutorial](https://quantumaudio.readthedocs.io/en/latest/tutorial.html) notebook.

Both the tutorial and supercollider examples were written as [Jupyter Notebooks](https://jupyter.org/install) that can be read inside this repo, or run in your local Jupyter Notebook server.

## Feedback and Getting help
Please open a [new issue](https://github.com/iccmr-quantum/quantumaudio/issues/new), to help improve the code. They are most welcome.

You may gain insight by learning more about [Qiskit](https://qiskit.org/learn) and [SuperCollider](https://supercollider.github.io/examples). We also strongly reccomend the reading of the [Quantum Representations of Sound](https://link.springer.com/chapter/10.1007/978-3-031-13909-3_10) book chapter for a better understanding of quantum representations of audio.

## API Reference

Most methods and functions in the module contain docstrings for better understanding the implementation. This API documentation is available and readable [here](https://quantumaudio.readthedocs.io/en/latest/).

## Contributing

Clone/Fork this repo and help contributing to the code! Pull Requests are very welcome. You can also contact the [main author](https://github.com/Itaborala) to exchange ideas (highly reccomended). Make sure to install the `[dev]` and `[doc]` optional dependencies for running necessary [pytests](https://github.com/iccmr-quantum/quantumaudio/blob/main/quantumaudio/test_quantumaudio.py).

## Acknowledgements

This repo was created by the quantum computer music team at the [Interdisciplinary Centre for Computer Music Research (ICCMR)](https://www.plymouth.ac.uk/research/iccmr), University of Plymouth, UK. [Paulo ItaboraĆ­](https://itabora.space) is the lead developer.

See also the [QuTune Project](https://iccmr-quantum.github.io/) repository for other resources developed by the ICCMR group. 

`quantumaudio` has an [MIT license](https://github.com/iccmr-quantum/quantumaudio/blob/main/LICENSE). If you use this code in your research or art, please cite it according to the [citation file](https://github.com/iccmr-quantum/quantumaudio/blob/main/CITATION.cff).

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "quantumaudio",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.9",
    "maintainer_email": null,
    "keywords": "quantum,qiskit,quantum computing,quantum computer music,audio,quantum audio",
    "author": null,
    "author_email": "Paulo Vitor Itabora\u00ed <paulo.itaborai@plymouth.ac.uk>",
    "download_url": "https://files.pythonhosted.org/packages/73/94/08569948086d2bd12106ce9e0df8d25fd9024c79c3266a66bd39a96140a8/quantumaudio-0.0.2.tar.gz",
    "platform": null,
    "description": "# quantumaudio\nQuantumaudio Module: A Python package for Quantum Representations of Audio in qubit systems & examples\n\n![PyPI](https://img.shields.io/pypi/v/quantumaudio) ![Read the Docs (version)](https://img.shields.io/readthedocs/quantumaudio/latest?label=API%20docs) ![GitHub](https://img.shields.io/github/license/iccmr-quantum/quantumaudio)\n\n`quantumaudio` is a Python module with class implementations for building quantum circuits that encode and decode audio signals as quantum states. This is primarily aimed for quantum computing simulators, but it *might* also run on real quantum hardware. The main objective is to have a readily available tools for using quantum representations of audio in artistic contexts and for studying future Quantum Signal Processing algorithms for audio.\n\nThis package contains class implementations for generating quantum circuits from audio signals, as well as necessary pre and post processing functions. \n\nIt contatins implementations for three representation algorithms cited on the publication above, namely:\n\n- QPAM - Quantum Probability Amplitude Modulation (Simple quantum superposition or \"Amplitude Encoding\")\n- SQPAM - Single-Qubit Probability Amplitude Modulation (similar to [FRQI](https://link.springer.com/article/10.1007/s11128-010-0177-y) quantum image representations)\n- QSM - Quantum State Modulation (also known as [FRQA](https://www.researchgate.net/publication/312091720_Flexible_Representation_and_Manipulation_of_Audio_Signals_on_Quantum_Computers) in the literature)\n\nFor an introduction to quantum audio please refer to the book chapter [Quantum Representations of Sound: From Mechanical Waves to Quantum Circuits](https://link.springer.com/chapter/10.1007/978-3-031-13909-3_10) by Paulo V. Itabora\u00ed and Eduardo R. Miranda (draft version [available at ArXiV](https://arxiv.org/pdf/2301.01595.pdf)). The chapter also discusses QPAM, SQPAM and QSM, and glances over methods to implement quantum audio signal processing. \n\nAdditional documentaion is available [here](https://quantumaudio.readthedocs.io/en/latest/) along with a Jupyter Notebook [tutorial](https://quantumaudio.readthedocs.io/en/latest/tutorial.html) showing how the main methods work and general implementation workflow with the package. Additionally, to listen the results, there is a set of [examples](https://github.com/iccmr-quantum/quantumaudio/tree/main/examples_with_supercollider) for interfacing the quantum circuits with [SuperCollider](https://supercollider.github.io/), a powerful synthesis engine for live musical applications.\n\n## Dependencies\n\nThe `quantumaudio` package alone has the following dependencies:\n\n- qiskit (the quantum programming framework)\n- numpy\n- matplotlib\n- bitstring (for decoding purposes)\n- ipython (for listening purposes inside jupyter notebooks)\n\nFor running the [supercollider examples](https://github.com/iccmr-quantum/quantumaudio/tree/main/examples_with_supercollider), additional packages are needed:\n\n- SuperCollider scsynth ([install SuperCollider](https://supercollider.github.io/downloads))\n- Cython\n- [pyliblo](https://pypi.org/project/pyliblo/)\n- [python-supercollider client](https://pypi.org/project/supercollider/) (`pip install supercollider`)\n\n## Installation\n\nThis python module is distributed as a package in PyPi. It can be installed in any operating system by using `pip` in a console or terminal:\n\n- Windows\n```console\npip install quantumaudio\n```\n- Mac & Linux\n```console\npip3 install quantumaudio\n```\n\nOptionally, you can download the latest [release](https://github.com/iccmr-quantum/quantumaudio/releases), which also contains the examples and tutorial notebooks.\n\nIt is possible to install the additional python dependencies for running the supercollider examples automatically, by running the installation command with the `[examples]` optional dependencies:\n\n- Windows\n```console\npip install quantumaudio[examples]\n```\n- Mac & Linux\n```console\npip3 install quantumaudio[examples]\n```\n\n## Jupyter Notebook Examples\nIdeally, you would `pip install` the package in your own python environment and then download the latest example/tutorial files from the [releases](https://github.com/iccmr-quantum/quantumaudio/releases) page.\n\n### NOTE\nThere is a known bug when installing `pyliblo` packages through `pip install quantumaudio[examples]` in some systems. A temporary workaround is shown [here](https://github.com/iccmr-quantum/quantumaudio/issues/4).\n\n## Usage\n\nTo learn how to use this module, refer to the [tutorial](https://quantumaudio.readthedocs.io/en/latest/tutorial.html) notebook.\n\nBoth the tutorial and supercollider examples were written as [Jupyter Notebooks](https://jupyter.org/install) that can be read inside this repo, or run in your local Jupyter Notebook server.\n\n## Feedback and Getting help\nPlease open a [new issue](https://github.com/iccmr-quantum/quantumaudio/issues/new), to help improve the code. They are most welcome.\n\nYou may gain insight by learning more about [Qiskit](https://qiskit.org/learn) and [SuperCollider](https://supercollider.github.io/examples). We also strongly reccomend the reading of the [Quantum Representations of Sound](https://link.springer.com/chapter/10.1007/978-3-031-13909-3_10) book chapter for a better understanding of quantum representations of audio.\n\n## API Reference\n\nMost methods and functions in the module contain docstrings for better understanding the implementation. This API documentation is available and readable [here](https://quantumaudio.readthedocs.io/en/latest/).\n\n## Contributing\n\nClone/Fork this repo and help contributing to the code! Pull Requests are very welcome. You can also contact the [main author](https://github.com/Itaborala) to exchange ideas (highly reccomended). Make sure to install the `[dev]` and `[doc]` optional dependencies for running necessary [pytests](https://github.com/iccmr-quantum/quantumaudio/blob/main/quantumaudio/test_quantumaudio.py).\n\n## Acknowledgements\n\nThis repo was created by the quantum computer music team at the [Interdisciplinary Centre for Computer Music Research (ICCMR)](https://www.plymouth.ac.uk/research/iccmr), University of Plymouth, UK. [Paulo Itabora\u00ed](https://itabora.space) is the lead developer.\n\nSee also the [QuTune Project](https://iccmr-quantum.github.io/) repository for other resources developed by the ICCMR group. \n\n`quantumaudio` has an [MIT license](https://github.com/iccmr-quantum/quantumaudio/blob/main/LICENSE). If you use this code in your research or art, please cite it according to the [citation file](https://github.com/iccmr-quantum/quantumaudio/blob/main/CITATION.cff).\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "quantumaudio: A Python class implementation for Quantum Representations of Audio in Qiskit. Developed by the quantum computer music team at the Interdisciplinary Centre for Computer Music Research, University of Plymouth, UK",
    "version": "0.0.2",
    "split_keywords": [
        "quantum",
        "qiskit",
        "quantum computing",
        "quantum computer music",
        "audio",
        "quantum audio"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "7f0db9dce30cc29daf21317879977e901d711914934c2ae4b6ab23d24394ff64",
                "md5": "2344ffa062ce2f4b7ceb361a3050dd03",
                "sha256": "268674b532937a094800f0ac24b862aee66ad5053d08af7ee9d806b9721b0442"
            },
            "downloads": -1,
            "filename": "quantumaudio-0.0.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "2344ffa062ce2f4b7ceb361a3050dd03",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.9",
            "size": 14192,
            "upload_time": "2023-01-07T16:27:43",
            "upload_time_iso_8601": "2023-01-07T16:27:43.275611Z",
            "url": "https://files.pythonhosted.org/packages/7f/0d/b9dce30cc29daf21317879977e901d711914934c2ae4b6ab23d24394ff64/quantumaudio-0.0.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "739408569948086d2bd12106ce9e0df8d25fd9024c79c3266a66bd39a96140a8",
                "md5": "272a9e17741405088e95ed9df200fc19",
                "sha256": "ecf4c38340d9059ed8a723c94c0c30123cf7c54cd79d45395d10d1bc75ed0bbf"
            },
            "downloads": -1,
            "filename": "quantumaudio-0.0.2.tar.gz",
            "has_sig": false,
            "md5_digest": "272a9e17741405088e95ed9df200fc19",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.9",
            "size": 2058177,
            "upload_time": "2023-01-07T16:27:53",
            "upload_time_iso_8601": "2023-01-07T16:27:53.427528Z",
            "url": "https://files.pythonhosted.org/packages/73/94/08569948086d2bd12106ce9e0df8d25fd9024c79c3266a66bd39a96140a8/quantumaudio-0.0.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-01-07 16:27:53",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "lcname": "quantumaudio"
}
        
Elapsed time: 0.02940s