Installation¶
Cisco's Network-Aware Quantum Compiler is distributed as a prebuilt wheel, provided to you directly. It is not published on PyPI and it cannot be built from source.
Don't have a wheel yet?
Request access at outshift.cisco.com/quantum/quantum-compiler-app. Everything below assumes you already have one.
Closed source, compiled distribution
The SDK ships as a compiled wheel. Several of the partitioning, scheduling and error-correction algorithms are not published, so the wheel is the whole distribution. Everything documented here is callable from it exactly as described, and there is no build step to run.
Requirements¶
| Python | 3.12 or newer recommended |
| OS | macOS and Linux fully supported; Windows with one caveat, below |
| System packages | Graphviz, for DAG and network plots |
The wheel is built per Python version and platform, so use the one matching your interpreter. Its dependencies — Qiskit, NetworkX, matplotlib, OR-Tools, Stim, PyMatching and the rest — resolve from PyPI normally.
Install¶
Create an environment and install the wheel you were given:
For the optional learned embeddings, install the ml extra as well:
That pulls in PyTorch and PyTorch Geometric. They are a large download and nothing in the compile, partition or simulate path imports them, so skip the extra unless you need that part of the API.
Every example in this documentation assumes the environment is active. If you would rather not activate it, the equivalent form works everywhere:
Accept the terms and conditions¶
The SDK can't be used until you accept its Terms & Conditions. Do this once, right after installing the wheel, from a terminal with the environment active:
It prompts:
To use this software, you must accept the Terms & Conditions: https://outshift.cisco.com/legal/quantum-compiler-terms
Do you agree? [y/N]
Answer y (or yes). Anything else, including just pressing Enter, counts
as declining. Your acceptance is recorded, with its time in UTC, in
~/.cisco/quantum/qndk-terms.json, so the prompt doesn't appear again for
that user account, across environments and wheel upgrades. On accepting,
the command confirms:
See the Terms & Conditions: https://outshift.cisco.com/legal/quantum-compiler-terms
Terms accepted on 2026-09-30 21:05:12 UTC.
Running the same command again after accepting doesn't prompt. It shows where the terms are and when you accepted them:
See the Terms & Conditions: https://outshift.cisco.com/legal/quantum-compiler-terms
You already accepted these terms on 2026-09-30 21:05:12 UTC.
Run it from a terminal, not a notebook
The prompt needs interactive input, so it won't run inside Jupyter or
IPython. There it prints
To accept terms, re-run this outside of an IPYTHON environment and
declines. Accept once from a terminal first, and notebooks work from
then on.
Until the terms are accepted, import qndk stops the interpreter and
prints:
Usage of this SDK requires you to accept the Terms and Conditions
This can easily be accomplished 1 time after installation with:
python3 -c 'from qndk import show_terms; show_terms()'
Non-interactive environments such as CI jobs, containers and schedulers can't answer the prompt either, so accept the terms interactively as the same user before running the SDK there.
System dependencies¶
Graphviz¶
Required by every plotting method that lays out a graph — circuit DAGs and network topologies. The Python binding comes with the wheel's dependencies, but the underlying binary does not.
Without it, importing and simulating still work; only the plots fail, with
a graphviz_layout or dot error. See
Troubleshooting.
METIS, on Windows¶
pymetis has no Windows build, so it is declared as a dependency for
non-Windows platforms only. On Windows everything installs and runs, but
MetisPartitioner raises on import. Use KernighanLinPartitioner or
WindowBasedCircuitPartitioner, which are pure Python and always available.
Verify the install¶
Accept the terms and conditions first,
or import qndk exits before anything below runs.
import qndk
from qndk.quantum_network import build_clos, QPUSpec
network = build_clos(
ports_per_switch=4,
qpus_per_rack=2,
qpu_spec=QPUSpec(comp_qubits=4),
)
network.validate()
print("qpus :", len(network.qpu_ids()))
print("switches :", len(network.switch_ids()))
print("compute qubits :", network.total_comp_qubits())
print("comm qubits :", network.total_comm_qubits())
validate() is the important line. It raises on a structurally invalid
network rather than letting a broken topology reach the simulator, so if it
returns quietly the install is sound.
Optional: check the plotting path¶
# fragment: needs Graphviz, opens a window
from qndk.quantum_network import build_clos, QPUSpec
network = build_clos(ports_per_switch=4, qpus_per_rack=2,
qpu_spec=QPUSpec(comp_qubits=4))
network.plot(qubits=True, block=True)
Plotting methods across the SDK share a block argument. It defaults to
False so scripts do not stall; pass block=True when you want the window
to stay up, or call matplotlib.pyplot.show() yourself at the end of a
script that produced several figures.
Getting a wheel¶
Wheels are distributed manually rather than from a package index. Request one at outshift.cisco.com/quantum/quantum-compiler-app. For a build covering a Python version or platform not already offered there, see Support.
Next: Getting Started.