def get_parameter_shift(self, idx, shift=(np.pi / 2)):
    'Multiplier and shift for the given parameter, based on its gradient recipe.\n\n        Args:\n            idx (int): parameter index\n\n        Returns:\n            float, float: multiplier, shift\n        '
    recipe = self.grad_recipe[idx]
    multiplier = (0.5 / np.sin(shift))
    a = 1
    default_param_shift = [[multiplier, a, shift], [(- multiplier), a, (- shift)]]
    param_shift = (default_param_shift if (recipe is None) else recipe)
    if hasattr(self.data[idx], 'mult'):
        var_mult = self.data[idx].mult
        for elem in param_shift:
            elem[0] *= var_mult
            if (var_mult != 0):
                elem[2] /= var_mult
    return param_shift
Multiplier and shift for the given parameter, based on its gradient recipe.

Args:
    idx (int): parameter index

Returns:
    float, float: multiplier, shift
def get_parameter_shift(self, idx, shift=(np.pi / 2)):
    'Multiplier and shift for the given parameter, based on its gradient recipe.\n\n        Args:\n            idx (int): parameter index\n\n        Returns:\n            float, float: multiplier, shift\n        '
    recipe = self.grad_recipe[idx]
    multiplier = (0.5 / np.sin(shift))
    a = 1
    default_param_shift = [[multiplier, a, shift], [(- multiplier), a, (- shift)]]
    param_shift = (default_param_shift if (recipe is None) else recipe)
    if hasattr(self.data[idx], 'mult'):
        var_mult = self.data[idx].mult
        for elem in param_shift:
            elem[0] *= var_mult
            if (var_mult != 0):
                elem[2] /= var_mult
    return param_shift