FastQSim SDK — submit and manage quantum simulation jobs via OpenQASM 3.0
Project description
fastqsim
FastQSim SDK — submit and manage quantum simulation jobs on the FastQubit platform using OpenQASM 3.0.
Installation
pip install fastqsim
Quick Start
import fastqsim
# Initialise with your pod token (starts with fqp_)
fastqsim.init("fqp_your_pod_token_here")
from fastqsim import FastQSimClient, RunArgs, SimulationType
client = FastQSimClient()
qasm = """
OPENQASM 3.0;
qubit[2] q;
h q[0];
cx q[0], q[1];
measure q;
"""
# Submit a job
job = client.run(RunArgs(
qasm_input=qasm,
shots=1024,
simulation_type=SimulationType.STATEVECTOR,
))
# Poll until done, then fetch result
result = client.get_result(job.id)
print(result.counts) # e.g. {'00': 512, '11': 512}
Simulation Types
| Type | Description |
|---|---|
statevector |
Full state-vector (default) |
density_matrix |
Noisy / open-system simulation |
mps |
Matrix Product State (low-entanglement) |
chp |
Clifford / stabilizer (Clifford gates only) |
API
from fastqsim import (
init, reset, # module-level helpers
FastQSimClient, # main client class
Job, Result, Session, # data types
JobStatus, SimulationType, RunArgs,
# exceptions:
FastQSimError, AuthenticationError, JobFailedError,
JobTimeoutError, ValidationError, QuotaExceededError,
# ... (15 exception types total)
)
FastQSimClient methods
| Method | Description |
|---|---|
client.run(args) |
Submit a job, returns Job |
client.get_result(job_id) |
Fetch result (polls until complete) |
client.cancel(job_id) |
Cancel a queued/running job |
client.get_session() |
Get current session info |
Requirements
- Python >= 3.8
requests >= 2.28
Documentation
Full docs at https://aneeq-ahmed-malik.github.io/QSim/
License
MIT
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 Distribution
Built Distribution
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 fastqsim-0.1.1.tar.gz.
File metadata
- Download URL: fastqsim-0.1.1.tar.gz
- Upload date:
- Size: 19.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
88b1063522e00baece8f555a573170b906d302bd0d5d83b7b94d884766e6ea4e
|
|
| MD5 |
6978035dc173dee4a40ad0d9b3e9b901
|
|
| BLAKE2b-256 |
ab5ab5578b034c56f5dd9ca811b113811a2470c1a9d36b56d5cbbb68ed2c50ea
|
Provenance
The following attestation bundles were made for fastqsim-0.1.1.tar.gz:
Publisher:
publish-fastqsim.yml on Aneeq-Ahmed-Malik/QSim
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
fastqsim-0.1.1.tar.gz -
Subject digest:
88b1063522e00baece8f555a573170b906d302bd0d5d83b7b94d884766e6ea4e - Sigstore transparency entry: 1520169850
- Sigstore integration time:
-
Permalink:
Aneeq-Ahmed-Malik/QSim@492f7469951de72513dd88d01088591a5f98389c -
Branch / Tag:
refs/tags/v0.1.1 - Owner: https://github.com/Aneeq-Ahmed-Malik
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-fastqsim.yml@492f7469951de72513dd88d01088591a5f98389c -
Trigger Event:
push
-
Statement type:
File details
Details for the file fastqsim-0.1.1-py3-none-any.whl.
File metadata
- Download URL: fastqsim-0.1.1-py3-none-any.whl
- Upload date:
- Size: 19.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
31e419213ddafa565ecb0bc9e9e35a5839811dc7b8cb1db4d8e92a936a7f33cd
|
|
| MD5 |
2a864547cd8efd850f34327aadc01e8b
|
|
| BLAKE2b-256 |
3924382c35094e3c265127a6d1d3de8debecac1aee25ea481b803bf8262046dc
|
Provenance
The following attestation bundles were made for fastqsim-0.1.1-py3-none-any.whl:
Publisher:
publish-fastqsim.yml on Aneeq-Ahmed-Malik/QSim
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
fastqsim-0.1.1-py3-none-any.whl -
Subject digest:
31e419213ddafa565ecb0bc9e9e35a5839811dc7b8cb1db4d8e92a936a7f33cd - Sigstore transparency entry: 1520169909
- Sigstore integration time:
-
Permalink:
Aneeq-Ahmed-Malik/QSim@492f7469951de72513dd88d01088591a5f98389c -
Branch / Tag:
refs/tags/v0.1.1 - Owner: https://github.com/Aneeq-Ahmed-Malik
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-fastqsim.yml@492f7469951de72513dd88d01088591a5f98389c -
Trigger Event:
push
-
Statement type: