Open marekgluza opened 2 months ago
Thanks @marekgluza for opening the issue. Our approach in order to go from voltages to probabilities is to perform a single shot classification experiment, which consists in generating a sequence of 0s and a sequence of 1s and then perform a fit in the IQ plane to classify 0s and 1s. Would it be possible in your case to adopt the same strategy?
Thank you, @andrea-pasquale, for your response. We currently use a similar strategy for calibrating single-shot experiments. Our proposed feature addresses the arbitrary magnitude obtained using the SEQUENTIAL
averaging method, where the Rabi oscillations already provide a clear sine curve from which we can infer expectation values of $1$ and $-1$.
This feature will:
SEQUENTIAL
averaging mode, sweep the arbitrary magnitude of the readout for $\ket{0}$ and $\ket{1}$ for each qubit over time (alternatively, find the min and max of a Rabi pulse on each qubit).SEQUENTIAL
readouts, standardizing them from $-1$ to $1$ instead of a raw range (e.g., from 56000 to 62000).Implementing this feature would be straightforward and intuitive. It will be particularly useful when running multiple qubits using SEQUENTIAL
readout, making it easier to interpret qubit behavior from the processed output.
For example, the 3-qubit CR plots that Marek mentioned might show Q3 oscillating from $\ket{0}$ to $\ket{1}$, or from $\ket{0}$ to $\ket{+}$, but this is not evident from the raw measurement values:
I have make a proof of concept code at this new branch, that can be run and tested on our hardware at NTU. Would it be reasonable to add this to qibocal?
Thanks @khanhuyengiang for the reply.
I think that this is the behavior intended for magnitude
given that there is no post-processing applied.
I had a quick look at the code and I understand the idea. It is not the standard procedure but I believe that it could work.
Regarding this normalization, in qibocal we also provide a Rabi protocol where the output is already normalized https://github.com/qiboteam/qibocal/blob/main/src/qibocal/protocols/rabi/amplitude.py. We can do this by retrieving samples from the instrument:
https://github.com/qiboteam/qibocal/blob/4c23ced7d5ee1e93d758e75179308a9d13c6da90/src/qibocal/protocols/rabi/amplitude.py#L94-L114
Could this work for you? I think that the outcome should be pretty much the same :)
When we execute a![rabi_exc_time_X_pulse_start](https://github.com/qiboteam/qibocal/assets/6939096/53681964-3e83-418f-afbf-e89f524fb706)
qibolab.Pulse
and retrieve the readout magnitudeplatform.execute_pulse_sequence(ps, opts)[q7_ro.serial].magnitude
we getProposed feature:
magnitude
for output visualizationplatform.execute_pulse_sequence(ps, opts)[q7_ro.serial].minmax_cal_Z_expectation_value
which would normalize the magnitudes ofq7
and output data $\in [-1,1]$Expected output:
Potential use example: Last week we have run cross-resonance driving on q1,q2,q3 and the script provides output data for magnitudes which are stored and we get![three_CR_010_201](https://github.com/qiboteam/qibocal/assets/6939096/6f490360-eadb-422e-bb7d-612b700abe1c)
The problem: Without autocalibration storing the output of a dedicated run of Rabi oscillation for each of the involved qubits then we have no estimate whether the minima of these readout traces of coupled qubits are hitting their respective $|1\rangle$ value or not. In the coupled case the evolution of initial $|0,0,0\rangle$ might not reach $\langle Z_k(t)\rangle =-1$ but just from this plot we don't know what was he minimal expectation value. (The data in the plot is useless if we don't have access to the min-max of each of the qubits because without min-max we don't know how to stretch and move the data for each qubit; should be automated anyway.)
@scarrazza can you add me and @khanhuyengiang to the qibocal team?