Pytket-offline-display
This pytket extension package provides offline circuit rendering functionality.
To use, first install the package with pip:
pip install pytket-offline-display
Then replace the usual pytket.circuit.display import with pytket.extensions.offline_display. For example:
from pytket.extensions.offline_display import render_circuit_jupyter
from pytket import Circuit
circ = Circuit(2,2)
circ.H(0)
circ.CX(0,1)
circ.measure_all()
render_circuit_jupyter(circ)
If you want to control the default options, you can instead load a configurable instance. (Note that this requires pytket >= 1.15)
from pytket.extensions.offline_display import get_circuit_renderer
circuit_renderer = get_circuit_renderer()
circuit_renderer.set_render_options(zx_style=False) # set the default options.
circuit_renderer.dark_mode = True # You can also set them directly.
circuit_renderer.render_circuit_jupyter(circ)
Release files for pytket-offline-display 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| pytket_offline_display-0.1.1.tar.gz | 37.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| pytket_offline_display-0.1.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 260.3 kB
Release files / pytket_offline_display-0.1.1.tar.gz
| Download URL | pytket_offline_display-0.1.1.tar.gz |
|---|---|
| Size | 37.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
939072eaa3218616e05dae82549e42be16d9e5cfa69e753e2c31cac00bb77db4
|
|
BLAKE2b-256 checksum How to use checksums |
bc8f6673454f0ad4237dea646e44d917adf27784184e555cac235dd569365515
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Release files / pytket_offline_display-0.1.1-py3-none-any.whl
| Download URL | pytket_offline_display-0.1.1-py3-none-any.whl |
|---|---|
| Size | 222.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
1b14dba3deff7474c49bcb2e56eb745d6edadef9807429514abd692b1294e0ae
|
|
BLAKE2b-256 checksum How to use checksums |
938c787b30c7fb43cdd95622058379da0e24fc7c6581c2397816d1d8096e6ca9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|