LoQS v1.3
The Logical Qubit Simulator (LoQS) is designed to simulate a few logical qubits with arbitrary noise models and arbitrary quantum and classical operations.
Installation
The following installation instructions can be used on M1/M2 Macs using Anaconda/Miniconda to create a local virtual environment.
conda create -n loqs-env python=3.14
conda activate loqs-env
pip install loqs
# pip install -e . ## for "editable" cloned repo install
There are various optional requirements that are available, including:
parallel: Enables single-node (loky) and SLURM-array (submitit) parallelization over shots and/or programs.submitit's SLURM-array support requires Linux/macOS -- it registers a POSIX-only signal internally and does not work on Windows.mpi: Enables multi-node parallelization over shots and/or programs viampi4py. Requires a working MPI installation (e.g. OpenMPI/MPICH) already present in the environment --pip installalone does not provide one.dev: Allows the use ofblackandflake8prior to committing (see Code Formatting and Linting below).docs: Allows building of the documentation (see Documentation below).quantumsim: Enables the QuantumSim (state) backend.pygsti: Enables the PyGSTi (circuit, model, state) backend.pymatching: Enables the PyMatching (minimum-weight perfect matching) decoder for certain codepacks.stim: Enables the STIM (state) backend.test: Allows testing (see Testing below)visualization: Enables some of the visualization tools inloqs.tools. Note thatpdflatexis also required for full visualization support.
There are several helper "categories" for optional dependencies, including:
backends: Packages needed to enable all backendsnobackends: The complement ofbackends, i.e. all developer packages with no backends (useful for testing)all: All optional dependencies exceptmpi, which requires a real MPI installation and is deliberately excluded so it stays opt-in -- combine explicitly instead, e.g.pip install -e ".[all,mpi]"
To use these, simply modify the last line of the installation instructions. For example:
pip install -e ".[all]"
(where the quotes are only needed if using zsh instead of bash).
For developers who may want an editable version of pyGSTi, you can run:
pip install -e git+https://github.com/sandialabs/pyGSTi.git@v0.9.14#egg=pyGSTi
to get the 0.9.14 release of pyGSTi, which will be located in src.
Alternatively, you can use any other tag or commit hash instead of v0.9.14
if you are working off of a feature branch.
Documentation
This project uses MkDocs and Jupytext-compatible Markdown notebooks under docs/notebooks/ for its documentation and interactive tutorials. In order to build or preview the documentation locally, do at least an installation of loqs[docs].
Local Building & Preview
To build and serve the documentation locally, run:
python docs/serve.py
This will launch a local server typically accessible at http://127.0.0.1:8000/.
More details on the documentation structure and Jupytext workflow are available in docs/DOCS_README.
Interactive Cloud Notebooks (Binder)
The tutorials and examples are configured to be run interactively in the cloud using Binder! You can open any of the tutorial or example notebooks directly in your browser by clicking the "Launch Binder" badges on the generated documentation pages.
Note that the first launch may take up to 5-10 minutes to build the Binder environment.
Contributing Interactive Notebooks
The easiest way to modify and add interactive notebooks is to use loqs-nb-sync, a command-line tool that's automatically installed alongside LoQS when you install the docs extra (pip install ".[docs]").
- Navigate to
docs/notebooks, where all interactive notebooks are kept as Markdown for easy source control. - Generate a working Jupyter notebook via
loqs-nb-sync to-ipynb <target_to_edit>.md. - Edit the notebook, e.g.
jupyter labto start a server, edit, and save. - Sync your edits back to Markdown via
loqs-nb-sync to-md <target_to_edit>.ipynb. - Commit your changes!
Always use loqs-nb-sync for both directions -- converting or syncing these notebooks any other way can leave broken links in the result.
Metadata
Release files for loqs 1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| loqs-1.3.tar.gz | 406.6 kB | With provenance | Details for loqs-1.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| loqs-1.3-py3-none-any.whl | Python 3 | none | any | Details for loqs-1.3-py3-none-any.whl |
Total release size: 881.9 kB
Release files / loqs-1.3.tar.gz
| Download URL | loqs-1.3.tar.gz |
|---|---|
| Size | 406.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9ca1434e3611768edbdaecddbc215c928b5f2f78c853d225e03f8a48b7ca03e8
|
|
BLAKE2b-256 checksum How to use checksums |
0cd396f7f91dc5227e5ba652f1176e4a7154fb382a6862d242b07f813416472c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 23, 2026.
Transparency logRelease files / loqs-1.3-py3-none-any.whl
| Download URL | loqs-1.3-py3-none-any.whl |
|---|---|
| Size | 475.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
204e6033b987353d4728431413f3bf1e27211e8b88de595f85e13ebba2691d06
|
|
BLAKE2b-256 checksum How to use checksums |
65b190e91fc82ce147b06ca968b1b9cbe8c122665330c08e9661d76b88d509bb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 23, 2026.
Transparency logSecurity for loqs 1.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
All 2 files in this release have been uploaded with provenance metadata.
Attestation for loqs-1.3.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 23, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.