paraqeet.measurement.goat_over_grape.GOATOverGRAPE#
- class paraqeet.measurement.goat_over_grape.GOATOverGRAPE(measurement, propagation, generators)[source]#
Bases:
NormalizableMeasurement,DifferentiableCombine GRAPE propagation with analytic gradients of GOAT via chain rule.
- Parameters:
measurement (StateTransferFidelityGRAPE) – A StateTransferFidelityGRAPE measurement.
propagation (DifferentiablePropagation) – Propagation method used for the optimization. Used to determine the time grid.
generators (PWCGenerator | list[PWCGenerator]) – A PWCGenerator or a list of PWCGenerators that are used for propagation.
- __init__(measurement, propagation, generators)[source]#
- Parameters:
measurement (StateTransferFidelityGRAPE)
propagation (DifferentiablePropagation)
generators (PWCGenerator | list[PWCGenerator])
Methods
__init__(measurement, propagation, generators)calculate_normalized_scalar(times)Passthrough the measurement.
get_value_and_gradient(times)Compute gradients with GRAPE and use the chain rule to provide the gradients for the optimizer.
measure(times)Sum of plain weighted measurements.
- calculate_normalized_scalar(times)[source]#
Passthrough the measurement.
- Returns:
Returns the normalized weighted sum.
- Return type:
Array
- Parameters:
times (Array | float)