GEM Suite
[!NOTE] This repository is under active development and the code here should not be considered stable. This is not an officially supported IBM Quantum software.
The GEM (Generation of Entanglement by Measurement) protocol prepares a quantum state across many qubits using an efficient, measurement-based protocol. Generally, it is technical challenge to achieve this on current generation quantum devices because most preparation protocols are vulnerable to imperfections in gates and to noise. The protocol that realizes the Nishimori transition, also understood as a fault-tolerant threshold, is a constant depth method that demonstrates how measurement-based state preparation might be used on large-scale quantum devices exceeding a few hundred qubits. Through injecting coherent errors, the GEM experiment provides an estimate for how far below the error correction threshold a device is operating.
All technical details are available on arXiv: https://arxiv.org/abs/2309.02863
Because of the computationally intensive subroutine responsible for decoding the measurement outcomes, this library is mostly implemented in Rust programming language for performance. The core library is interfaced with Qiskit Experiments via PyO3 to produce experiment circuits with the Qiskit model and analyze the results. We support two minimum weight perfect matching decoders; pymatching and fusion-blossom.
This library is designed to work with, but not limited only to, IBM Quantum processors.
Installation
This package can be installed with pip using the command
pip install gem-suite
Example
In the GEM protocol, an atomic unit of the experiment is a plaquette, which is a collection of multiple qubits. For the case of IBM Quantum processors with heavy hexagonal lattices, a single plaquette contains 12 qubits and a single IBM Eagle processor has 18 plaquettes. This is an efficient compact representation of a quantum processor with a few hundred qubits. We anticipate very minor changes to this representation when scaling up to larger devices.
We can partly reproduce experiments in the publication with a few lines of code using the Qiskit Experiments framework.
from gem_suite.experiments import GemExperiment
from qiskit_ibm_runtime import QiskitRuntimeService
backend = QiskitRuntimeService().backend("ibm_cusco")
gem_exp = GemExperiment(plaquettes=range(18), backend=backend)
exp_data = gem_exp.run().block_for_results()
Please see our example notebook for the complete workflow.
License
Metadata
Release files for gem-suite 0.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| gem_suite-0.2.0.tar.gz | 41.8 kB | Details |
Built distributions (wheels)
| File | Reset | |||
|---|---|---|---|---|
| gem_suite-0.2.0-cp310-abi3-win_amd64.whl | CPython 3.10 | abi3 | Windows x86-64 | Details |
| gem_suite-0.2.0-cp310-abi3-win32.whl | CPython 3.10 | abi3 | Windows x86-32 | Details |
| gem_suite-0.2.0-cp310-abi3-musllinux_1_2_x86_64.whl | CPython 3.10 | abi3 | Linux musl 1.2+ x86-64 | Details |
| gem_suite-0.2.0-cp310-abi3-manylinux_2_28_x86_64.whl | CPython 3.10 | abi3 | Linux glibc 2.28+ x86-64 | Details |
| gem_suite-0.2.0-cp310-abi3-macosx_11_0_arm64.whl | CPython 3.10 | abi3 | macOS 11.0+ ARM64 | Details |
Total release size: 3.2 MB
Release files / gem_suite-0.2.0.tar.gz
| Download URL | gem_suite-0.2.0.tar.gz |
|---|---|
| Size | 41.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7981b19d60b38bbaf9574ffce3c279d8d13793fb4fc8dd8c1691b44eb9409e40
|
|
BLAKE2b-256 checksum How to use checksums |
89c4c49b59381f67d7ecba37819b1a80b2320dd8710b65b298369278abcc5c23
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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 Sep 11, 2026.
Transparency logRelease files / gem_suite-0.2.0-cp310-abi3-win_amd64.whl
| Download URL | gem_suite-0.2.0-cp310-abi3-win_amd64.whl |
|---|---|
| Size | 528.1 kB |
| Tags | CPython 3.10 Windows x86-64 abi3 |
|
SHA-256 checksum How to use checksums |
4caea2afca0317ecb3dd06fac45336c4da029abe4d1185e189d2bb509993ea76
|
|
BLAKE2b-256 checksum How to use checksums |
fdf3751fa7417b328bb8a1abda72ff9e11a53e326bfdde11db3a5fefcc6191a4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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 Sep 11, 2026.
Transparency logRelease files / gem_suite-0.2.0-cp310-abi3-win32.whl
| Download URL | gem_suite-0.2.0-cp310-abi3-win32.whl |
|---|---|
| Size | 505.3 kB |
| Tags | CPython 3.10 Windows x86-32 abi3 |
|
SHA-256 checksum How to use checksums |
44cb15e2d4c199f2cc1c18f8390cea79d6914e014d3d109bc01cd7455edf93b3
|
|
BLAKE2b-256 checksum How to use checksums |
2dcf70dab75dd61f651633b981b141e00afb46ff9b9239ab7cfca3688cbb4222
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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 Sep 11, 2026.
Transparency logRelease files / gem_suite-0.2.0-cp310-abi3-musllinux_1_2_x86_64.whl
| Download URL | gem_suite-0.2.0-cp310-abi3-musllinux_1_2_x86_64.whl |
|---|---|
| Size | 788.0 kB |
| Tags | CPython 3.10 Linux musl 1.2+ x86-64 abi3 |
|
SHA-256 checksum How to use checksums |
fa88214ce4c54759e66979c605a8a1934dea2780fd32ae55d092d09c1a8f52b3
|
|
BLAKE2b-256 checksum How to use checksums |
4589ce1e3f3c999c11d49fb2df3a0d3e489bc65cc93ac4f1f2613caaeade908e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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 Sep 11, 2026.
Transparency logRelease files / gem_suite-0.2.0-cp310-abi3-manylinux_2_28_x86_64.whl
| Download URL | gem_suite-0.2.0-cp310-abi3-manylinux_2_28_x86_64.whl |
|---|---|
| Size | 764.3 kB |
| Tags | CPython 3.10 Linux glibc 2.28+ x86-64 abi3 |
|
SHA-256 checksum How to use checksums |
5fc7d5e058d706b1572fc6f1706ba88d8a1c97fbafcb05875e5a5989141fe3fe
|
|
BLAKE2b-256 checksum How to use checksums |
6374fba97f40f0cbf4ef0522d4a4789f6ca7df603d2eedb13505697111874fbb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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 Sep 11, 2026.
Transparency logRelease files / gem_suite-0.2.0-cp310-abi3-macosx_11_0_arm64.whl
| Download URL | gem_suite-0.2.0-cp310-abi3-macosx_11_0_arm64.whl |
|---|---|
| Size | 618.5 kB |
| Tags | CPython 3.10 abi3 macOS 11.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
fda0935fe90ba22e5c69e2bea0113b63935571a35de48d72ae62897dbe7c16bc
|
|
BLAKE2b-256 checksum How to use checksums |
1ad48b718f055d2f1fd2a9aef5241159fa3563f2fa6c8d97336fbf3fbf3d861b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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 Sep 11, 2026.
Transparency log