ott.geometry.epsilon_scheduler.Epsilon
ott.geometry.epsilon_scheduler.Epsilon#
- class ott.geometry.epsilon_scheduler.Epsilon(target=None, scale_epsilon=None, init=None, decay=None)[source]#
Scheduler class for the regularization parameter epsilon.
An epsilon scheduler outputs a regularization strength, to be used by in a Sinkhorn-type algorithm, at any iteration count. That value is either the final, targeted regularization, or one that is larger, obtained by geometric decay of an initial value that is larger than the intended target. Concretely, the value returned by such a scheduler will consider first the max between
target
andinit * target * decay ** iteration
. If thescale_epsilon
parameter is provided, that value is used to multiply the max computed previously byscale_epsilon
.- Parameters
target (
Optional
[float
]) – the epsilon regularizer that is targeted.scale_epsilon (
Optional
[float
]) – if passed, used to multiply the regularizer, to rescale it.init (
Optional
[float
]) – initial value when using epsilon scheduling, understood as multiple of target value. if passed,int * decay ** iteration
will be used to rescale target.decay (
Optional
[float
]) – geometric decay factor, smaller than 1.
Methods
at
([iteration])Return (intermediate) regularizer value at a given iteration.
done
(eps)- rtype
done_at
(iteration)- rtype
make
(*args, **kwargs)Create or return an Epsilon instance.
Attributes
Return the final regularizer value of scheduler.