qudit_sim.visualization.plot_amplitude_scan
- qudit_sim.visualization.plot_amplitude_scan(amplitudes, components, threshold=None, amp_scale=FrequencyScale.auto, compo_scale=FrequencyScale.auto, max_poly_order=4, select_components=None)
Plot the result of the amplitude scan.
See the last example in examples/validation/heff.ipynb for how to prepare the inputs to this function.
This function performs polynomial fits to the amplitude dependences of the Pauli components and returns the best-fit parameters as well as adds the fit curves to the plots. Amplitude variable in the polynomials are normalized to O(1) to avoid numerical errors. The third and fourth return values of this function represent the amplitude and component scales used for the normalization.
- Parameters
amplitudes (
numpy.ndarray) – Array of drive amplitudes (assumed real)components (
Sequence) – Returned list of effective Hamiltonian components from find_heff.threshold (
Optional[float]) – Only plot components whose maximum is above this threshold. Defaults to 0.01 * compo_scale.pulsatance_value.amp_scale (
FrequencyScale) – Scale of the drive amplitude.compo_scale (
FrequencyScale) – Scale of the components.max_poly_order (
int) – Maximum polynomial order for fitting the amplitude dependencies of the components.select_components (
Optional[List[Tuple]]) – List of Pauli components to plot.
- Return type
Tuple[Figure,numpy.ndarray,FrequencyScale,FrequencyScale]- Returns
Plot Figure, polynomial coefficients from the fits, list of selected components, and the amplitude and components scale used to normalize the amplitude variable in the polynomials.