qvm
qvm copied to clipboard
Teach simulator about the different "layers" of execution
It Would Be Nice (TM) if the API to the QVM allowed access to the various "layers" of tensor factors in the execution. The QVM ought to understand (for noise/programmatic/etc) that
H 0
H 1
are logically in the same "layer".
Maybe start with a function
MAP-LAYERS (f instructions &key strategy)
where f : [Instructions] -> ()
, instructions : [instruction]
, and strategy
is from at least {:trivial, :greedy}
.
:trivial
would just map one instruction at a time. :greedy
would be "circuit-style" earliest first based off of resource.
This could be plugged into the middle of RUN
and TRANSITION
as a middle-man, maybe TRANSITION-COMMUTING-GROUP
which gives implementers freedom in how transition is run while remaining true to QAM semantics.