Initiating a run
Running your algorithm on one of the available backends is initiated by clicking on the
RUN button at the top right of the screen. A popup window will appear that shows you:
- The backend that has been selected for this experiment
- The number of qubits used in this experiment
- Information about a simulation error model (when applicable)
- Information whether simulation optimization will be used or not
- The name of the current experiment (can be changed by the user)
- The number of shots of this experiment (can be changed by the user)
Executing algorithms on a hardware backend
In the current version of QI we only provide access to simulation backends. Hardware backends are not being made publicly available at this moment.
When you run a quantum algorithm on a hardware backend the algorithm must be finalized with a measurement on one or more qubits in order to get the results of the measurement into the binary register. In most cases you will have to execute multiple shots in order to get some statistics on your measurement and to reduce the effects the decoherence, leakage, and control imperfections. On a hardware backend, when you execute N shots of your algorithm, all shots will be executed in succession. For each shot, the final measurements will be stored in the binary register and written to the raw data file, see displaying and downloading your results. The histogram will show the probability distribution of each state of the binary register.
Executing algorithms on a simulation backend
Quantum Inspire provides different simulation backends, depending on your needs and on your account privileges. Make sure you select the backend which best fits the requirements of your algorithm in order to optimize overall turn-around time.
When you execute your algorithm on a simulation backend it is usually unnecessary to execute multiple shots of the same algorithm. In this case Quantum Inspire will use simulation optimization to produce the results more quickly. This can only be done when there are no measurement instructions in your algorithm and no error model is used. Please refer to the section on simulation optimization to understand the difference between deterministic and non-deterministic algorithms; when optimization will be applied; how you can influence this decision; and what the number of shots implies for these situations.
To understand how simulation optimization works with the SDK, experienced users should refer to the Advanced user guide.
Selecting the number of shots
When no simulation optimization can be used the algorithm will be executed N times. When simulation optimization is used, no randomization will be applied when N=1. In all other cases randomization with N virtual shots will be applied.
When a simulation is put in the queue of a backend, a copy of the current code of the algorithm is stored with the result of the execution. This way you can compare different versions of your project quickly (e.g. with error model and without error model). More on this in managing your projects.