Skip to main content

qollage

Documentation Status GitHub Workflow Status PyPI PyPI - Format Crates.io

Drawing tool for the qoqo quantum toolkit by HQS Quantum Simulations.

Qollage provides the save_circuit and draw_circuit functions that allows users to translate a qoqo circuit into a png image and either save it or display it.
These two functions will create a cache folder named .qollage containing fonts and Typst libraries in the current directory. You are free to delete it but the files will be downloaded again at the next use.
It also provides the circuit_to_typst_str that can be used to generate a string that can be copy pasted in the Typst interpreter if you want to edit the circuit further.
The latest qoqo gates might not be implemented in qollage yet. A circuit containing not supported operations can't be drawn and will result in an error.
If a gate has a string parameter it will be printed inside a typst mathematical expression and the typst symbols will be replaced.
Alphanumerical expressions will be preprocessed, if it doesn't represent any typst symbol it will be escaped by surrounding quotes.
qoqo.operations.RotateX(0, "theta") will be formatted as θ.
qoqo.operations.RotateX(0, "param") will be escaped with quotes and kept as it is.
qoqo.operations.RotateX(0, "\"param\"") will not be accepted because the extra quotes will interfere with the quotes added to escape param.
For more informations see the documentation.
Here is the list of symbols but be aware that not all of them are supported by the font used.

Example:

In a jupyter cell:

from qoqo import Circuit, operations as ops
from qollage import draw_circuit

circuit = Circuit()
circuit += ops.DefinitionBit("ro", 2, True)
circuit += ops.Hadamard(0)
circuit += ops.CNOT(0, 1)
circuit += ops.PauliX(1)
circuit += ops.RotateX(0, "theta")
circuit += ops.MeasureQubit(0, "ro", 0)
circuit += ops.MeasureQubit(1, "ro", 1)

draw_circuit(circuit)

The API documentation is available here.

General Notes

This software is still in the beta stage. Functions and documentation are not yet complete and breaking changes can occur.

Contributing

We welcome contributions to the project. If you want to contribute code, please have a look at CONTRIBUTE.md for our code contribution guidelines.

Metadata

Release files for qollage 0.10.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for qollage 0.10.1
File Size Uploaded
qollage-0.10.1.tar.gz 502.0 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for qollage 0.10.1
File
qollage-0.10.1-cp313-cp313-win_amd64.whl CPython 3.13 CPython 3.13 Windows x86-64 Details
qollage-0.10.1-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.13 CPython 3.13 Linux glibc 2.17+ x86-64 Details
qollage-0.10.1-cp313-cp313-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl CPython 3.13 CPython 3.13 macOS 10.12+ universal2 (ARM64, x86-64), macOS 11.0+ ARM64, macOS 10.12+ x86-64 Details
qollage-0.10.1-cp312-cp312-win_amd64.whl CPython 3.12 CPython 3.12 Windows x86-64 Details
qollage-0.10.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.12 CPython 3.12 Linux glibc 2.17+ x86-64 Details
qollage-0.10.1-cp312-cp312-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl CPython 3.12 CPython 3.12 macOS 10.12+ universal2 (ARM64, x86-64), macOS 10.12+ x86-64, macOS 11.0+ ARM64 Details
qollage-0.10.1-cp311-cp311-win_amd64.whl CPython 3.11 CPython 3.11 Windows x86-64 Details
qollage-0.10.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.11 CPython 3.11 Linux glibc 2.17+ x86-64 Details
qollage-0.10.1-cp311-cp311-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl CPython 3.11 CPython 3.11 macOS 10.12+ universal2 (ARM64, x86-64), macOS 10.12+ x86-64, macOS 11.0+ ARM64 Details
qollage-0.10.1-cp310-cp310-win_amd64.whl CPython 3.10 CPython 3.10 Windows x86-64 Details
qollage-0.10.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.10 CPython 3.10 Linux glibc 2.17+ x86-64 Details
qollage-0.10.1-cp310-cp310-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl CPython 3.10 CPython 3.10 macOS 11.0+ ARM64, macOS 10.12+ universal2 (ARM64, x86-64), macOS 10.12+ x86-64 Details

Total release size: 268.7 MB

Release files / qollage-0.10.1.tar.gz

Download URL qollage-0.10.1.tar.gz
Size 502.0 kB
Tags Source
SHA-256 checksum
How to use checksums
0e06eda8aef5d348f77f99eb38cf13a02f787b95a7c2bcdfafe3e4bae2b01a31
BLAKE2b-256 checksum
How to use checksums
7c24406f2c3404edf55633aaacb4176006fdf0eb1363a17734a220d4c44d3295
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.14

Release files / qollage-0.10.1-cp313-cp313-win_amd64.whl

Download URL qollage-0.10.1-cp313-cp313-win_amd64.whl
Size 17.7 MB
Tags CPython 3.13 Windows x86-64
SHA-256 checksum
How to use checksums
37dce77aa28cabfc7ee48465efa5836f1ba7f6b08f369e25955c43ec59f25d3d
BLAKE2b-256 checksum
How to use checksums
7b67240e08ca05967e42d0f7c6a63415db373640ceb722e2d60bc523c802e301
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.14

Release files / qollage-0.10.1-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL qollage-0.10.1-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 17.1 MB
Tags CPython 3.13 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
885f73569c0a42c83d7292fc969f69ecf902bee9f8eb85654b2937a1a903e549
BLAKE2b-256 checksum
How to use checksums
bc4bb5ec3bb93fee584844f5f4e8c85a4284c4918d783bdaafaa3824ac8e6a5c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.14

Release files / qollage-0.10.1-cp313-cp313-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl

Download URL qollage-0.10.1-cp313-cp313-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl
Size 32.3 MB
Tags CPython 3.13 macOS 10.12+ universal2 (ARM64, x86-64) macOS 10.12+ x86-64 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
b83ba82a0f1cb9eef1b543bfe874923c6b81c8f7396637f2bf2ecedf9eb855a9
BLAKE2b-256 checksum
How to use checksums
1285e4c5158b2dfa5524859470674a5ef94e5b9dea70d1ff9c934e423ae49c6b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.14

Release files / qollage-0.10.1-cp312-cp312-win_amd64.whl

Download URL qollage-0.10.1-cp312-cp312-win_amd64.whl
Size 17.7 MB
Tags CPython 3.12 Windows x86-64
SHA-256 checksum
How to use checksums
2a6e65c7c18f3cb7e00b2d1dd1c8737759139c8aff461f5c98c42c6196b59128
BLAKE2b-256 checksum
How to use checksums
8079361d57b58c4625bc28881df39bb240e2297c2c412bf61fa38c8ad0938f22
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.14

Release files / qollage-0.10.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL qollage-0.10.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 17.1 MB
Tags CPython 3.12 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
02906499beefb0529d417e5c7a9368c1cf5b844b29942f1d2e000ac86db587dc
BLAKE2b-256 checksum
How to use checksums
a36363f0580ff4b20c7f44cb5fe1dc3166e8abcc8366d2aa690ed737e1cef24e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.14

Release files / qollage-0.10.1-cp312-cp312-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl

Download URL qollage-0.10.1-cp312-cp312-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl
Size 32.3 MB
Tags CPython 3.12 macOS 10.12+ universal2 (ARM64, x86-64) macOS 10.12+ x86-64 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
abe63d450efbb73cce6fded417954ca63434603bdbea5c020486e7c5fc8dbc63
BLAKE2b-256 checksum
How to use checksums
b501d4164e04f749c9f2d347811bee1d21ae1364494935bb3580b299c0972ca3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.14

Release files / qollage-0.10.1-cp311-cp311-win_amd64.whl

Download URL qollage-0.10.1-cp311-cp311-win_amd64.whl
Size 17.7 MB
Tags CPython 3.11 Windows x86-64
SHA-256 checksum
How to use checksums
58b0920ed71510f91d583fbb9b07c09b2fe0a7611a38f813d8843bec4bf14750
BLAKE2b-256 checksum
How to use checksums
642150b41dc04315db647d2b15d33059dd19ac43d935f53051928be2c7fb67ed
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.14

Release files / qollage-0.10.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL qollage-0.10.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 17.1 MB
Tags CPython 3.11 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
8ac720c2c49c50a1329f0dc04e5b8ddfd35cb57fa1b12863293bf00a64f804c3
BLAKE2b-256 checksum
How to use checksums
a33f6507ffc6b2314c25940bcc13308208157c953eeecda44ef7385c631bb6bd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.14

Release files / qollage-0.10.1-cp311-cp311-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl

Download URL qollage-0.10.1-cp311-cp311-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl
Size 32.2 MB
Tags CPython 3.11 macOS 10.12+ universal2 (ARM64, x86-64) macOS 10.12+ x86-64 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
167a1aff4ecdbe65da2a8f5d73093479044d25a04e59f80f0c910c859f0144a0
BLAKE2b-256 checksum
How to use checksums
3c229f49a842b3c65bd3ddb71857a8b2a1db81b7d6060ebd5b518e95c347ed5d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.14

Release files / qollage-0.10.1-cp310-cp310-win_amd64.whl

Download URL qollage-0.10.1-cp310-cp310-win_amd64.whl
Size 17.7 MB
Tags CPython 3.10 Windows x86-64
SHA-256 checksum
How to use checksums
b3b3f95e2d003bd61a4326752ababc9a49c3b7b02b953ed43c7fa0b7633d1ba4
BLAKE2b-256 checksum
How to use checksums
4262b074d87c89cb5196bdb68de18e178fbc0a9229232d27e585a194f1c7968d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.14

Release files / qollage-0.10.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL qollage-0.10.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 17.1 MB
Tags CPython 3.10 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
f6c30a8a09ea31845549e56a3d2e87ef64228e10baa76628b6e045e7cc07ce69
BLAKE2b-256 checksum
How to use checksums
f90bb32c5cb7fe67cf479603e6020040a51fe5885d19a6e1379936340cd74bc5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.14

Release files / qollage-0.10.1-cp310-cp310-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl

Download URL qollage-0.10.1-cp310-cp310-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl
Size 32.2 MB
Tags CPython 3.10 macOS 10.12+ universal2 (ARM64, x86-64) macOS 10.12+ x86-64 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
100b7dbdd834a3427db4a73eef47783e7b0e2453b4f54ec860618cf139ae90d2
BLAKE2b-256 checksum
How to use checksums
7a435ace21110ec645c681d051d7e2a2d69a3f49243a6a3f8255eaac0d2836da
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.14

Release history Release notifications | RSS feed

This release

0.10.1 This release

13 release files

0.9.1

13 release files

0.9.0

13 release files

0.7.0

21 release files

0.6.0

19 release files

0.4.3

16 release files

0.4.1

19 release files

0.4.0

21 release files

0.2.1

23 release files

0.2.0

16 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page