What Happened
First Problem ran examples/maxcut/runner.py and
printed a partition, a cut weight, and an energy. This page is an index:
it names the five moves that run made, in order, and points at the page
that covers each one in full, rather than explaining them again here.
Toolchain Map has its own diagram of the same
pipeline, if a picture is what you want first.
Five Moves, One Command
- A problem became three programs.
build_probleminexamples/maxcut/runner.pydescribes Max-Cut once, in Python, with thexqcpDSL;problem.compile()turned it into an encoder, a verifier, and a decoder, sharing no state. Three Programs covers why there are three and not one, and walks this exact run step by step. - The encoder ran and built a model. Quadratic Models covers the Hamiltonian it built, specialised to this graph’s weights.
- A solver minimised it.
dwave-cpu, the default backend, ran simulated annealing over the model and returned a sample. Backends covers the other four solvers this same model could have gone to instead, unchanged. - The verifier checked the sample and computed its energy
independently.
energy: -354was not relayed from the solver; see Quadratic Models: Energy for that computation. - The decoder turned the sample into
partition. See Outputs and Decoding for what a decoder can read and what it hands back.
--interpreter rust in the previous page swapped which machine ran steps
2, 4, and 5. Three Programs
covers what is and is not guaranteed to match between the two
interpreters when that swap happens.
Where to Go From Here
- Toolchain Map – every piece named above, in one table, with what each hands to the next.
- Modelling – write your own
Probleminstead of reading someone else’s; builds on a second running example, Knapsack, from the first input declaration onward. - Running Programs – drive an already-compiled
program from Python yourself, the way
runner.pydoes internally. - Solving Overview – the five solvers behind step 3, and what each needs installed before you can reach it.
- Using the Examples – turn Max-Cut, or any of the other thirteen examples, into a problem of your own.