qiboteam / qibocal

Quantum calibration, characterization and validation module for Qibo.
https://qibo.science
Apache License 2.0
32 stars 6 forks source link

tomography with swept parameters #1043

Open jevillegasdatTII opened 4 days ago

jevillegasdatTII commented 4 days ago

Is it possible to have a tomography routine (single qubits and 2 qubits) that allows sweeping a parameter in one of the gates implemented in the circuit?

This would allow us to run arbitrary experiments in some of the gates that need measuring in multiple projections to be properly characterized. Now running multiple topographies and manually gathering the data (or in a for-loop) takes hours but could be done in minutes using sweepers.

alecandido commented 3 days ago

@jevillegasdatTII in principle, I see no problem. The only reason making it suboptimal is that it would very "tailored" for a specific use case.

If this can be done much faster, I would not oppose to have a temporary protocol doing that.

However, for a proper solution, I would propose to move the tomography definition in Qibo (rather than as a protocol on its own in Qibocal), and then implement this protocol "externally", and plug it in a Qibocal script, in which you define your circuit by composing the one you're interested in with the tomography procedure, and define a sweeper on the parameter you're interested in, to be passed during the acquisition (with a custom routine, either as a plugin, or as a standalone acquisition, cf. #878).

Still, it would remain an issue, since you can not currently sweep a parameter in a circuit (not even within Qibocal, it's a Qibolab limitation). To do this, we will soon expose compilation, such that you can generate pulses out of a circuit (in a simple way, but outside the Qibolab backend for Qibo), and make sure you can target the pulse you're interested in automatically (without manually tracing where the parameter you wish has been compiled to).

I'm sorry, but at this last part should be addressed in order to make your request possible. And I fear it's also the most complex part (and it should be addressed in Qibolab).