pygsti.drivers.bootstrap.gauge_optimize_models#
- gauge_optimize_models(gs_list, target_model, gate_metric='frobenius', spam_metric='frobenius', plot=True)#
Optimizes the “spam weight” parameter used when gauge optimizing a set of models.
This function gauge optimizes multiple times using a range of spam weights and takes the one the minimizes the average spam error multiplied by the average gate error (with respect to a target model).
- Parameters:
gs_list (list) – The list of Model objects to gauge optimize (simultaneously).
target_model (Model) – The model to compare the gauge-optimized gates with, and also to gauge-optimize them to.
gate_metric ({ "frobenius", "fidelity", "tracedist" }, optional) – The metric used within the gauge optimization to determining error in the gates.
spam_metric ({ "frobenius", "fidelity", "tracedist" }, optional) – The metric used within the gauge optimization to determining error in the state preparation and measurement.
plot (bool, optional) – Whether to create a plot of the model-target discrepancy as a function of spam weight (figure displayed interactively).
- Returns:
The list of Models gauge-optimized using the best spamWeight.
- Return type:
list