A reader and writer for the circuit text and the detector error model text that keep every instruction's tag, its arguments as written and every kind of target (records, Pauli targets, inverted results, sweep bits, products), blocks as blocks. The frame simulator now reads through it: tags reach the mechanisms their noise makes, observables take Pauli targets in sampling and in the model, detectors keep their coordinates. A model is written with its coordinates, tags and each decomposed mechanism's parts, and read back to the same model, blocks unrolled and detector shifts applied. A conformance set of circuits and models the crate writes and of hand-written ones, each held to its counts, its model and a byte-for-byte round trip, with the refusals. Co-Authored-By: Claude Opus 5.5 <[email protected]>
10 lines
217 B
Text
10 lines
217 B
Text
detector(0, 0, 0) D0
|
|
detector(1, 0, 0) D1
|
|
error[y](0.001) D0 D1 ^ D2 L0
|
|
repeat 3 {
|
|
error(0.002) D0 ^ D1
|
|
error[meas](0.003) D0 D2
|
|
detector(0, 0, 1) D2
|
|
shift_detectors(0, 0, 1) 2
|
|
}
|
|
logical_observable L1
|