Q# Python Bindings
Project description
Q# Language Support for Python
Q# is an open-source, high-level programming language for developing and running quantum algorithms.
The qsharp
package for Python provides interoperability with the Q# interpreter, making it easy
to simulate Q# programs within Python.
Installation
To install the Q# language package, run:
pip install qsharp
Usage
First, import the qsharp
module:
import qsharp
Then, use the %%qsharp
cell magic to run Q# directly in Jupyter notebook cells:
%%qsharp
open Microsoft.Quantum.Diagnostics;
@EntryPoint()
operation BellState() : Unit {
use qs = Qubit[2];
H(qs[0]);
CNOT(qs[0], qs[1]);
DumpMachine();
ResetAll(qs);
}
BellState()
Support
For more information about the Azure Quantum Development Kit, visit https://aka.ms/AQ/Documentation.
Contributing
Q# welcomes your contributions! Visit the Q# GitHub repository at [https://github.com/microsoft/qsharp] to find out more about the project.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distributions
Hashes for qsharp-1.6.0-cp37-abi3-win_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a0e768d36bfd0522f820bc770254f596b08a6412c4c5be4cb254f55d026c3a35 |
|
MD5 | eceb11879e98c6f99e8f6eaae9878e2f |
|
BLAKE2b-256 | 6e2c231c741c080903cbea868eae333a473cdcd96b80c6d223051cb90b8cbe43 |
Hashes for qsharp-1.6.0-cp37-abi3-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c9e3eb245187d68a1b589b66e1225e51a24df989de0c0282ed9ef6cb437686d7 |
|
MD5 | 86f223a1b6a6de128c88ecbd80a9f397 |
|
BLAKE2b-256 | 525629830843fe4bd5ceb93c35142234080c1d12a2f67ea9c04e9c45401314f0 |
Hashes for qsharp-1.6.0-cp37-abi3-manylinux_2_31_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | efdb7178ae9147ac55afd57f0cf2850b6b8a588dcc4bbcb3661f40cc37ac386e |
|
MD5 | 73b8c974ffda329e5f4203ac12c248c1 |
|
BLAKE2b-256 | 16f2d60cd3f6b61e668b4f068900bd8059cb17583923a15edd06de14efd93a3b |
Hashes for qsharp-1.6.0-cp37-abi3-manylinux_2_31_aarch64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d79eeb0b349dfa60293e8766577628a0c0be0bb77f1aa7ff46c4ac595cc17d70 |
|
MD5 | e92d049560da30cf86b0a758c90ce574 |
|
BLAKE2b-256 | 389a499be47107696bf2a4d312d6b1ef9f205d531f31aa893f443c56715b1c44 |
Hashes for qsharp-1.6.0-cp37-abi3-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 71b1f085b58f2ff41d9db775e865e277119b5ef4a1a2600872a3a63a6bd1ab1c |
|
MD5 | 55f856a305c18107e2faeaefa78ff78e |
|
BLAKE2b-256 | c5f128e4a4b06c230f3e7ab0a3d584c7e7716200d6a0325221073ea51858c13b |