State Vector emulation interface: `run_callback.` 758
In this release, we are pleased to present a new feature for Bloqade emulation of the `bloqade. python()` backend, called [`run_callback`](https://bloqade.quera.com/latest/reference/bloqade/ir/routine/bloqade/#bloqade.ir.routine.bloqade.BloqadePythonRoutine.run_callback). This callback function gives you access to the state-vector data via the [`StateVector`](https://bloqade.quera.com/latest/reference/bloqade/emulate/ir/state_vector/#bloqade.emulate.ir.state_vector.StateVector) object. This callback must have at least three arguments. The first three are the state vector, the second is the parameters of the particular task given as a named tuple, and the third argument is the Hamiltonian object used to generate the evolution for that specific task. The callback is called after running the emulation for each task given by the program's assignments.
The `StateVector` object contains a method called [`local_trace`](https://bloqade.quera.com/latest/reference/bloqade/emulate/ir/state_vector/#bloqade.emulate.ir.state_vector.StateVector.local_trace), which calculates the trace of an operator over the one- and two-site densities matrices. The Hamiltonian object has some method for calculating mean and variance of the energy given a particular `StateVector` and can even be involved at different times.
A caveat to remember: if you select `multiprocessing=True` when calling `run_callback` if your callback function updates any objects from within the callback function, e.g., has "side effects," you might get a race condition, or the function may not update the values as expected. This is because each call is run on another Python process that will not be able to update global variables and will contain copies of objects from the main process.
Other changes
1. 772 Removing implementation of QuEra backend to a private package, Access to QuEra's internal API will only be given on an individual basis.
2. 776 Adding the option to filter or not filter out shots that were not perfectly filled.
3. 771 Improving test coverage for `bloqade.tasks` module.
4. 769 A bug where the level coupling was not used to hash the operators in the `CompileCache` for the Bloqade emulator, which meant that if the hyperfine and rydberg both had the same spatial modulation, the second operator would not be stored.