q-optimize / c3

Toolset for control, calibration and characterization of physical systems
https://c3-toolset.readthedocs.io/
Apache License 2.0
66 stars 36 forks source link

Process multiple qiskit circuits in the same experiment #199

Closed lazyoracle closed 2 years ago

lazyoracle commented 2 years ago

Describe the missing feature

Currently jobs submitted to the qiskit interface can only contain a single circuit. Even if the qiskit experiment object has more than one circuit, the same is ignored in the present implementation.

Describe the solution you'd like

It should be possible to submit multiple distinct qiskit circuits in a single job as part of the experiment object. These circuits should be run on the simulator and the results returned in the qiskit result object using the standard API.

Describe alternatives you've considered

See for example how the calibration runs in the Full Loop are extremely slow because each ORBIT circuit is submitted as a separate job

Additional context

It is important to also note here that currently the qiskit interface recomputes the propagators every time a job is submitted and run. There needs to be a check to ensure that propagators are recomputed only when model or signal parameters have been updated or when a recompute is manually triggered by the user. It might be prudent to have the default setting be "recomputation for every new job" once the "multi-circuit-experiment" section has been implemented. It is fair to assume that all circuits in an experiment object have the same set of model/signal parameters and do not need a propagator recomputation during the course of execution of the experiment.