Install¶
That is the whole install. qmlkit depends on NumPy and nothing else — the NumPy backend is the reference implementation, and every core feature works with no optional package present.
Python 3.10 or newer. 3.9 reached end of life in October 2025, and 3.10 is also the highest version SpinQit supports, so it is the overlap that matters.
Extras¶
Each extra adds one capability. None of them is required, and import qmlkit never
imports any of them — a missing SDK produces an install command, not a traceback.
Unlocks QuantumLayer, VQC, VQRegressor, the structured architectures, and
method="backprop".
Adds the Qiskit backend and to_qiskit(), so a circuit can be handed to Qiskit's
own transpiler and visualisation.
SpinQit ships wheels for Python 3.8–3.10 only and pins numpy<2, so the extra is
gated behind an environment marker: on 3.11+ it resolves cleanly to nothing rather
than failing. Use a dedicated 3.10 environment for it.
sklearn enables QSVC/QSVR (which wrap scikit-learn's precomputed-kernel solver)
and viz enables matplotlib plotting helpers.
Check what you have¶
backend_report() prints one line per backend with an install command for the ones
you are missing:
qmlkit backends:
[ok] numpy
[ok] torch
[missing] cirq -> pip install 'qmlkit[cirq]'
[missing] qiskit -> pip install 'qmlkit[qiskit]'
[missing] spinqit -> pip install 'qmlkit[spinqit]'
Set the default with the QMLKIT_BACKEND environment variable, or in code:
From source¶
Verifying an install you did not build¶
If you want to confirm a release is intact — that nothing is missing from the wheel and no optional dependency is secretly required — the repository ships the check it runs in CI: