The multiplicative weights algorithm #
The multiplicative weights (MW) algorithm with learning rate η multiplies the weight of an
expert with loss x by 1 - η x (mwFactor) [AroraHazanKale2012, §2, Figure 1]; this is the
prod algorithm of Cesa-Bianchi, Mansour and Stoltz [CBMS07] and the
Polynomial Weights (PW) algorithm of Blum and Mansour [BlumMansour2007AGT, §4.3.3] (which
coincides with Randomized Weighted Majority on {0, 1} losses [BlumMansour2007AGT, §4.3.2]).
For losses in [-1, 1] and 0 < η ≤ 1 / 2, its total expected loss exceeds the total loss of
every expert i by at most η ∑ t, |ℓ t i| + ln n / η (mw_regret_le,
[AroraHazanKale2012, Theorem 2.1]). Averaging over a distribution on the experts gives the same
bound against mixed strategies (mw_regret_le_stdSimplex, [AroraHazanKale2012, Corollary 2.2]),
with η = √(ln n / T) and T ≥ 4 ln n the regret is at most 2 √(T ln n) (mw_regret_le_sqrt),
and on [0, 1] losses the capped rate η = min √(ln n / T) (1 / 2) achieves 2 √(T ln n) for
every horizon T (mw_regret_le_sqrt_of_mem_Icc, [BlumMansour2007AGT, Theorems 4.5 and 4.6]).
The proof combines the potential inequality sum_log_le_log_card_add with two estimates. The
expected update factor is 1 - η times the expected loss, and log (1 - x) ≤ -x. For the factor of
expert i, log (1 - y) ≥ -y - y ^ 2 for y ≤ 1 / 2 (Real.neg_sub_sq_le_log_one_sub); this
gives the second-order bound η ∑ t, ℓ t i ^ 2 in place of η ∑ t, |ℓ t i| under the one-sided
hypothesis η ℓ ≤ 1 / 2 alone (mw_regret_le_sq). [AroraHazanKale2012, proof of Theorem 2.1] uses
the two convexity bounds (1 - η) ^ x ≤ 1 - η x on [0, 1] and (1 + η) ^ (-x) ≤ 1 - η x on
[-1, 0] instead, followed by the same logarithm estimates at x = ±1.
Main definitions #
Cslib.MachineLearning.OnlineLearning.Experts.mwFactor: the update factor1 - η x.
Main results #
Cslib.MachineLearning.OnlineLearning.Experts.mw_regret_le_sq: the second-order regret bound.Cslib.MachineLearning.OnlineLearning.Experts.mw_regret_le: [AroraHazanKale2012, Theorem 2.1].Cslib.MachineLearning.OnlineLearning.Experts.mw_regret_le_stdSimplex: [AroraHazanKale2012, Corollary 2.2].Cslib.MachineLearning.OnlineLearning.Experts.mw_regret_le_sqrt: regret2 √(T ln n)with the tuned learning rate forT ≥ 4 ln n.Cslib.MachineLearning.OnlineLearning.Experts.prob_regret_le_sqrt_of_mem_Icc,Cslib.MachineLearning.OnlineLearning.Experts.mw_regret_le_sqrt_of_mem_Icc: generic capped-rate2 √(T ln n)wrapper on[0, 1]losses and its Polynomial Weights instantiation withη = min √(ln n / T) (1 / 2)[BlumMansour2007AGT, Theorems 4.5 and 4.6].Cslib.MachineLearning.OnlineLearning.Experts.mw_regret_le_sq_tuned,Cslib.MachineLearning.OnlineLearning.Experts.mw_regret_le_sqrt_loss_add_log: second-order and first-order tuned regret2 √(Q ln n) + 2 ln nfor any upper boundQon∑ t, (ℓ t i)^2or∑ t, ℓ t i[BlumMansour2007AGT, §4.3.2 note, p. 85].Cslib.MachineLearning.OnlineLearning.Experts.mw_gain_regret_le_sq,Cslib.MachineLearning.OnlineLearning.Experts.mw_gain_regret_le_sqrt_add_log: payoff-maximizing Polynomial Weights (1 + η g = mwFactor (-η) g) on[-1, 1]payoffs achieving2 √(Q ln n) + 2 ln nregret [BlumMansour2007AGT, Exercise 4.4, p. 101].
References #
The update factor 1 - η x of the multiplicative weights algorithm with learning rate η
[AroraHazanKale2012, (2.1)].
Second-order regret of multiplicative weights: if 0 < η and η ℓ ≤ 1 / 2 for all
losses, then for every expert i the total expected loss is at most
∑ t, ℓ t i + η ∑ t, ℓ t i ^ 2 + ln n / η. Compare [CBMS07] and
[AroraHazanKale2012, Theorem 2.1].
Regret of multiplicative weights [AroraHazanKale2012, Theorem 2.1]: for losses in
[-1, 1] and 0 < η ≤ 1 / 2, for every expert i,
∑ t, ⟨p t, ℓ t⟩ ≤ ∑ t, ℓ t i + η ∑ t, |ℓ t i| + ln n / η.
Regret against mixed strategies [AroraHazanKale2012, Corollary 2.2]: for losses in
[-1, 1], 0 < η ≤ 1 / 2 and every distribution q on the experts,
∑ t, ⟨p t, ℓ t⟩ ≤ ∑ t, ⟨q, ℓ t + η |ℓ t|⟩ + ln n / η.
Tuned regret of multiplicative weights: for n ≥ 2 experts, losses in [-1, 1] and
T ≥ 4 ln n rounds, MW with learning rate η = √(ln n / T) has regret at most 2 √(T ln n)
against every expert. The condition T ≥ 4 ln n is η ≤ 1 / 2.
Generic capped-rate 2 √(T ln n) external regret wrapper on [0, 1] losses for any
multiplicative update family φ η satisfying (1 + η) L_i^T + ln n / η for 0 < η ≤ 1 / 2.
Tuned regret of multiplicative weights on [0, 1] losses for every horizon
[BlumMansour2007AGT, Theorems 4.5 and 4.6, pp. 85–87]: for losses in [0, 1] and every horizon
T : ℕ, MW with the capped learning rate η = min √(ln n / T) (1 / 2) has regret at most
2 √(T ln n) against every expert i. On {0, 1} losses mwFactor coincides with Randomized
Weighted Majority ((1 - η) ^ ℓ = 1 - η ℓ), so together with mw_regret_le (for binary losses)
and mw_regret_le_sq (for [0, 1] losses) this covers the tuned bounds of Theorems 4.5 and 4.6
without the horizon floor T ≥ 4 ln n of mw_regret_le_sqrt.
Second-order tuned regret of multiplicative weights (O(√(Q ln n) + ln n)):
for losses in [-1, 1] and any upper bound Q ≥ 0 on ∑ t < T, (ℓ t i) ^ 2, choosing the
capped learning rate η = if 4 * ln n < Q then √(ln n / Q) else 1 / 2 (which depends only on n
and Q, not on i or T) gives
∑ t, ⟨p t, ℓ t⟩ ≤ ∑ t, ℓ t i + 2 √(Q ln n) + 2 ln n for every n ≥ 1 and every Q ≥ 0.
First-order (L_min-tuned) regret bound on [0, 1] losses
[BlumMansour2007AGT, §4.3.2 note after Theorem 4.5, p. 85]: for losses in [0, 1] and any upper
bound L ≥ 0 on ∑ t < T, ℓ t i (in particular L = minCumLoss ℓ T), tuning
η = if 4 * ln n < L then √(ln n / L) else 1 / 2 achieves
∑ t, ⟨p t, ℓ t⟩ ≤ ∑ t, ℓ t i + 2 √(L ln n) + 2 ln n.
The additive 2 ln n term is necessary when L < 4 ln n (for instance L = 0), correcting the
omitted + 2 ln N in the parenthetical remark on p. 85.
Payoff-maximizing Polynomial Weights on [-1, 1] payoffs (NRTV Exercise 4.4) #
Second-order external regret for payoff-maximizing Polynomial Weights
[BlumMansour2007AGT, Exercise 4.4, p. 101]: when payoffs g t i lie in [-1, 1] and the learner
multiplies weights by 1 + η * g t i = mwFactor (-η) (g t i) with 0 < η ≤ 1 / 2, for every
expert i the shortfall below expert i's total payoff is at most
η * ∑ t < T, (g t i) ^ 2 + ln n / η.
Tuned O(√(Q_max ln n) + ln n) regret for payoff-maximizing Polynomial Weights
[BlumMansour2007AGT, Exercise 4.4, p. 101]: for payoffs g t i ∈ [-1, 1] and any upper bound
Q ≥ 0 with ∑ t < T, (g t i) ^ 2 ≤ Q (e.g. Q = Q_max^T ≥ Q_k^T for all k), running
Polynomial Weights with weight factor 1 + η * g = mwFactor (-η) g and capped rate
η = if 4 * ln n < Q then √(ln n / Q) else 1 / 2 guarantees
∑ t < T, g t i - ∑ t < T, ⟨p t, g t⟩ ≤ 2 √(Q ln n) + 2 ln n.