unitaryfund / mitiq

Mitiq is an open source toolkit for implementing error mitigation techniques on most current intermediate-scale quantum computers.
https://mitiq.readthedocs.io
GNU General Public License v3.0
362 stars 158 forks source link

Support additional noise models #221

Closed rmlarose closed 4 years ago

rmlarose commented 4 years ago

From one of the alpha workshop survey responses:

"What did you have the most difficulty with in using mitiq? I have not tried hard, but using different noise models when in simulation mode seems non-trivial."

"What MUST be changed or added in the current mitiq library? The ability to simulate with user-defined noise models (see above)"

"What COULD be changed or added to enhance the current mitiq library? Noise models :)"

I agree supporting additional noise models beyond depolarizing would be convenient. If we agree, we can discuss how to organize this within the library. I haven't thought much about it, but it should be fairly easy by mimicing the way it is done for depolarizing noise with other channels.

nathanshammah commented 4 years ago

We could create a mitiq.noise.NoiseModel or mitiq.converters.NoiseModel or mitiq.simulators.NoiseModel class that would mainly dispatch noise models and convert them, if the circuit type is changed during mitigation. If we want to avoid adding extra layers, NoiseModel would not be interacted with by the user directly, but he/she would change the underlying circuit properties. Currently, noise models are contained in qiskit, cirq, pyquil. We could begin by focusing on the noise models that are supported by most and create an infrastructure that ports the noise together with the circuit. While the OSS landscape is full of intermediate representation converters, this feature is not present, that I am aware of.

While supporting noise models could be tricky and too cumbersome, what I'd support is anything that fits in a conversion table. Some care would need to be paid with regards to converting processes with the exact coupling constants, but this would be very useful as a user. We could begin with a conversion table between Depolarizing noise/channel and Amplitude noise. Happy to take this on me if we want to proceed.

willzeng commented 4 years ago

Examples of how to do this could be added to the documentation of executors with #229