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
import Std.Diagnostics.*;
@EntryPoint()
operation BellState() : Unit {
use qs = Qubit[2];
H(qs[0]);
CNOT(qs[0], qs[1]);
DumpMachine();
ResetAll(qs);
}
BellState()
Telemetry
This library sends telemetry. Minimal anonymous data is collected to help measure feature usage and performance. All telemetry events can be seen in the source file telemetry_events.py.
To disable sending telemetry from this package, set the environment variable QDK_PYTHON_TELEMETRY=none
Support
For more information about the Microsoft Quantum Development Kit, visit https://aka.ms/qdk.
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
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file qsharp-1.25.1-cp310-abi3-win_amd64.whl.
File metadata
- Download URL: qsharp-1.25.1-cp310-abi3-win_amd64.whl
- Upload date:
- Size: 5.8 MB
- Tags: CPython 3.10+, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: RestSharp/106.13.0.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c137c90723b0ea5c3c866a980b4bd54637abfab941065b72794a25ecd2360fa8
|
|
| MD5 |
8cfce4da2c586b4577cc3148fadde9cc
|
|
| BLAKE2b-256 |
bd7c56404efca620931085fa9f81159cb06ffa6944c54e982a20757221ae3547
|
File details
Details for the file qsharp-1.25.1-cp310-abi3-manylinux_2_35_x86_64.whl.
File metadata
- Download URL: qsharp-1.25.1-cp310-abi3-manylinux_2_35_x86_64.whl
- Upload date:
- Size: 5.5 MB
- Tags: CPython 3.10+, manylinux: glibc 2.35+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: RestSharp/106.13.0.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4599dbf7c2267917b9e06e9cf8c82c77ad97df676f3edfdb8931b7d5631d249f
|
|
| MD5 |
5d2fbc96e8e96c35901a2800158b47e1
|
|
| BLAKE2b-256 |
d73d7286c59ef31e2f181917998bde2797e0d78cd9d86b00b3a4df638f93dda4
|
File details
Details for the file qsharp-1.25.1-cp310-abi3-manylinux_2_35_aarch64.whl.
File metadata
- Download URL: qsharp-1.25.1-cp310-abi3-manylinux_2_35_aarch64.whl
- Upload date:
- Size: 5.1 MB
- Tags: CPython 3.10+, manylinux: glibc 2.35+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: RestSharp/106.13.0.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b595f0f578546172a295d386f0ff2a99caeb1aee5f9043e6dd09eba2d9687516
|
|
| MD5 |
da497b68004c0d0ddcdab14a2a73df69
|
|
| BLAKE2b-256 |
57fadef1312c71309f3d7e62dec341d06ee355cc307a26e6ace2c6516e192630
|
File details
Details for the file qsharp-1.25.1-cp310-abi3-macosx_11_0_arm64.whl.
File metadata
- Download URL: qsharp-1.25.1-cp310-abi3-macosx_11_0_arm64.whl
- Upload date:
- Size: 4.5 MB
- Tags: CPython 3.10+, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: RestSharp/106.13.0.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
09da72692ad6cd6d56204e297dc37343b07ba980d4efdb0ff363d5ac6852fba0
|
|
| MD5 |
861b19cc40e9fb5c3d717b25ff45f787
|
|
| BLAKE2b-256 |
f5494908f3810c0f86a4b9c5fff83ada46767d034421f76633f17ab6d7e4eac5
|
File details
Details for the file qsharp-1.25.1-cp310-abi3-macosx_10_12_x86_64.whl.
File metadata
- Download URL: qsharp-1.25.1-cp310-abi3-macosx_10_12_x86_64.whl
- Upload date:
- Size: 4.8 MB
- Tags: CPython 3.10+, macOS 10.12+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: RestSharp/106.13.0.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
978994d25232b08c71219e0f3e5ccf3ca9c716a1556ff214210affc350cc5482
|
|
| MD5 |
5909b8a8e16e26c102bebdc02afc20c6
|
|
| BLAKE2b-256 |
3dd0ba2e7dd1b3f7c7210de002070fa5e90b91b688a42b71fb13707f5b158ca8
|