Skip to main content

MIMIQ TensorWeaver: unlicensed mock

This distribution on PyPI is not the TensorWeaver simulator. It is MockTensorWeaver: the same interface, the same arguments, the same MIMIQ data models, and no simulation behind them. Results come back well-formed and empty: all-zero samples, zero amplitudes, fidelity 1.0.

It exists so that code which drives a MIMIQ backend can be tested on a machine with no licence: a CI job can check that its circuits build, that its options are accepted, that its results parse and round-trip, without paying for a simulation it does not care about.

pip install mimiq-tensorweaver

The same build is also published as mimiq-tensorweaver-mock. Use that name when a project declares the licensed package (mimiq-tensorweaver, from QPerfect) and this mock side by side and needs the two to have different names. Install one or the other, never both: they install the same tensorweaver package.

import mimiqcircuits as mc
from tensorweaver import MockTensorWeaver

sim = MockTensorWeaver(bonddim=64)

c = mc.Circuit()
c.push(mc.GateH(), 0)
c.push(mc.GateCX(), 0, 1)
c.push(mc.Measure(), [0, 1], [0, 1])

res = sim.execute(c, nsamples=1000, seed=42)
res.histogram()        # {bs"00": 1000}: a real QCSResults, carrying nothing

MockTensorWeaver takes the same constructor and execute arguments as the licensed TwSimulator and refuses exactly what it refuses, so a configuration that fails here fails there. Swapping between them is an import change.

What this build can and cannot do

It is compiled without the compute kernels. Gate application on the MPS and the MPO, MPO application, compression, the quantum channels and sampling are not in the binary.

What is here is the Matrix Product State itself, and it is the real one:

import tensorweaver as tw

tw.has_kernels()                 # False in this build

mps = tw.MPS.zero_state(8, 32)
mps.recanonicalize(0)            # canonical form, exact QR/LQ sweeps
mps.all_bond_dims()
mps.amplitude([0] * 8)
mps.von_neumann_entropy(2)       # entanglement of a cut, in nats
tw.MPS.deserialize(mps.serialize())

So a state produced by a licensed run can be saved, opened here, inspected, and have its entanglement structure read, without being able to evolve it further. tensorweaver.examples_dir() holds runnable examples; 00_mps_structure and 00_mock_backend work in this build, and the rest show what the licensed one does.

TwSimulator raises on construction here and says so.

The licensed simulator

TensorWeaver is a Matrix Product State quantum circuit simulator for MIMIQ, distributed by QPerfect to licence holders from its own package registry rather than from PyPI.

For access, documentation and support: https://qperfect.io

Metadata

Release files for mimiq-tensorweaver-mock 0.22.4

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

Built distributions (wheels)

Table of built distributions (wheels) for mimiq-tensorweaver-mock 0.22.4
File Interpreter ABI Platform Actions
mimiq_tensorweaver_mock-0.22.4-cp311-abi3-win_amd64.whl CPython 3.11 abi3 Windows x86-64 Details for mimiq_tensorweaver_mock-0.22.4-cp311-abi3-win_amd64.whl
mimiq_tensorweaver_mock-0.22.4-cp311-abi3-manylinux_2_35_x86_64.whl CPython 3.11 abi3 Linux glibc 2.35+ x86-64 Details for mimiq_tensorweaver_mock-0.22.4-cp311-abi3-manylinux_2_35_x86_64.whl
mimiq_tensorweaver_mock-0.22.4-cp311-abi3-macosx_11_0_arm64.whl CPython 3.11 abi3 macOS 11.0+ ARM64 Details for mimiq_tensorweaver_mock-0.22.4-cp311-abi3-macosx_11_0_arm64.whl

Total release size: 3.3 MB

Release files / mimiq_tensorweaver_mock-0.22.4-cp311-abi3-win_amd64.whl

Download URL mimiq_tensorweaver_mock-0.22.4-cp311-abi3-win_amd64.whl
Size 1.2 MB
Tags CPython 3.11 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
3dddf5a102dcfd1a573384a64e8c234f096116dc2b38fcda82e0ccf90d0242c6
BLAKE2b-256 checksum
How to use checksums
8ced5d8c1ddd4f0ab5ae0e348f6cdc194ebc6cd0ed2dde60ad17037f238c6e5f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.16

Release files / mimiq_tensorweaver_mock-0.22.4-cp311-abi3-manylinux_2_35_x86_64.whl

Download URL mimiq_tensorweaver_mock-0.22.4-cp311-abi3-manylinux_2_35_x86_64.whl
Size 1.3 MB
Tags CPython 3.11 Linux glibc 2.35+ x86-64 abi3
SHA-256 checksum
How to use checksums
987b6bd6016629a06b8e486bbf2fc87d407868ca378a11d36650deb2d85707f7
BLAKE2b-256 checksum
How to use checksums
13ec67b8274c570c10655c555cc6c76f349011f2d06f49bcdd047d4e4d9c66a4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.16

Release files / mimiq_tensorweaver_mock-0.22.4-cp311-abi3-macosx_11_0_arm64.whl

Download URL mimiq_tensorweaver_mock-0.22.4-cp311-abi3-macosx_11_0_arm64.whl
Size 822.8 kB
Tags CPython 3.11 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
67d18fbe8460ce6bd2d1b9d84a8f3bd6bbdc0ec945785cddfa92d1da4c685732
BLAKE2b-256 checksum
How to use checksums
da999b306c00ea0db37856a55dc753bb750e27818fa34d8bb19b94af53d224d5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.16

Security for mimiq-tensorweaver-mock 0.22.4

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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A 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.

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