JMLR: Workshop and Conference Proceedings vol 23 (2012) 44.1–44.3

25th Annual Conference on Learning Theory

Open Problem: Better Bounds for Online Logistic Regression H. Brendan McMahan

MCMAHAN @ GOOGLE . COM

Google Inc., Seattle, WA

Matthew Streeter

MSTREETER @ GOOGLE . COM

Google Inc., Pittsburgh, PA

Editor: Shie Mannor, Nathan Srebro, Robert C. Williamson

Abstract Known algorithms applied to online logistic regression on a feasible set of L2 diameter D achieve √ regret bounds like O(eD log T ) in one dimension, but we show a bound of O( D + log T ) is possible in a binary 1-dimensional problem. Thus, we pose the following question: Is it possible to achieve a regret bound for online logistic regression that is O(poly(D) log(T ))? Even if this is not possible in general, it would be interesting to have a bound that reduces to our bound in the one-dimensional case. Keywords: online convex optimization, online learning, regret bounds

1. Introduction and Problem Statement Online logistic regression is an important problem, with applications like click-through-rate prediction for web advertising and estimating the probability that an email message is spam. We formalize the problem as follows: on each round t the adversary selects an example (xt , yt ) ∈ Rn × {−1, 1}, the algorithm chooses model coefficients wt ∈ Rn , and then incurs loss `(wt ; xt , yt ) = log(1 + exp(−yt wt · xt )),

(1)

the negative log-likelihood of the example under a logistic model. For simplicity we assume kxt k2 ≤ 1 so that any gradient kO`(wt )k2 ≤ 1. While conceptually any w ∈ Rn could be used as model parameters, for regret bounds we consider competing with a feasible set W = {w | kwk2 ≤ D/2}, the L2 ball of diameter D centered at the origin. Existing algorithms for online convex optimization can immediately be applied. √First-order algorithms like online gradient descent (Zinkevich, 2003) achieve bounds like O(D T ). On a bounded feasible set logistic loss (Eq. (1)) is exp-concave, and so we can use second-order algorithms like Follow-The-Approximate-Leader (FTAL), which has a general bound of O(( α1 + GD)n log T ) (Hazan et al., 2007) when the loss functions are α-exp-concave on the feasible set; we have α = e−D/2 for the logistic loss (see Appendix A), which leads to a bound of O((exp(D) + D)n log T ) in the general case, or O(exp(D) log T ) in the one-dimensional case. The exponen√ tial dependence on the diameter of the feasible set can make this bound worse than the O(D T ) bounds for practical problems where the post-hoc optimal probability can be close to zero or one. We suggest that better bounds may be possible. In the next section, we show that a simple Follow-The-Regularized-Leader (FTRL) algorithm can achieve a much better result, namely c 2012 H.B. McMahan & M. Streeter.

M C M AHAN S TREETER

√ O( D + log T ), for one-dimensional problems where the adversary is further constrained1 to pick xt ∈ {−1, 0, +1}. A single mis-prediction can cost about D/2, and so the additive dependence on the diameter of the feasible set is less than the cost of one mistake. The open question is whether such a bound is achievable for problems of arbitrary finite dimension n. Even the general onedimensional case, where xt ∈ [−1, 1], is not obvious.

2. Analysis in One Dimension We analyze an FTRL algorithm. We can ignore any rounds when xt = 0, and then since only the sign of yt xt matters, we assume xt = 1 and the adversary picks yt ∈ {−1, 1}. The cumulative loss function on P positive examples and N negative examples is c(w; N, P ) = P log(1 + exp(−w)) + N log(1 + exp(w)). Let Nt denote the number of negative examples seen through the t’th round, with Pt the corresponding number of positive examples. We play FTRL, with wt+1 = arg min c(w; Nt + λ, Pt + λ), w

for a constant λ > 0. This is just FTRL with a regularization function r(w) = c(w; λ, λ). Using the FTRL lemma (e.g., McMahan and Streeter (2010, Lemma 1)), we have Regret ≤ r(w∗ ) +

T X

ft (wt ) − ft (wt+1 )

t=1

where ft (w) = `(w; xt , yt ). It is easy to verify that r(w) ≤ λ(|w| + 2 log 2). It remains to bound ft (wt ) − ft (wt+1 ). Fix a round t. For compactness, we write N = Nt−1 and P = Pt−1 . Suppose that yt = −1, so Nt = N + 1 and Pt = P (the case when yt+1 = +1 is analogous). Since ft is convex, by definition ft (w) ≥ ft (wt ) + gt (w − wt ) where gt = Oft (wt ). Taking w = wt+1 and re-arranging, we have ft (wt ) − ft (wt+1 ) ≤ gt (wt − wt+1 ) ≤ |gt ||wt − wt+1 |. It is easy to verify that |gt | ≤ 1, and also that  wt = log

P +λ N +λ

 .

Since yt = −1, wt+1 < wt , and so 

   P +λ P +λ |wt − wt+1 | = log − log N +λ N +1+λ = log(N + 1 + λ) − log(N + λ)   1 1 = log 1 + ≤ . N +λ N +λ

1. Constraining the adversary in this way is reasonable in many applications. For example, re-scaling each xt so kxt k2 = 1 is a common pre-processing step, and many problems also are naturally featurized by xt,i ∈ {0, 1}, where xt,i = 1 indicates some property i is present on the t’th example.

44.2

O PEN P ROBLEM : O NLINE L OGISTIC R EGRESSION

Thus, if we let T − = {t | yt = −1}, we have X

ft (wt ) − ft (wt+1 ) ≤

t∈T −

NT X N =0

NT 1 1 X 1 1 ≤ + ≤ + log(NT ) + 1. N +λ λ N λ N =1

Applying a similar argument to rounds with positive labels and summing over the rounds with positive and negative labels independently gives Regret ≤ λ(|w∗ | + 2 log 2) + log(PT ) + log(NT ) +

2 + 2. λ

Note log(PT ) + log(NT ) ≤ 2 log T . We wish to compete with w∗ where |w∗ | ≤ D/2, so we can choose λ = √ 1 which gives D/2

√ Regret ≤ O( D + log T ).

References Elad Hazan, Amit Agarwal, and Satyen Kale. Logarithmic regret algorithms for online convex optimization. Mach. Learn., 69, December 2007. H. Brendan McMahan and Matthew Streeter. Adaptive bound optimization for online convex optimization. In COLT, 2010. Martin Zinkevich. Online convex programming and generalized infinitesimal gradient ascent. In ICML, 2003.

Appendix A. The Exp-Concavity of the Logistic Loss Theorem 1 The logistic loss function `(wt ; xt , yt ) = log(1 + exp(−yt wt · xt )), from Eq. (1), is α-exp-concave with α = exp(−D/2) over set W = {w | kwk2 ≤ D/2} when kxt k2 ≤ 1 and yt ∈ {−1, 1}. Proof Recall that a function ` is α-exp-concave if O2 exp(−α`(w))  0. When `(w) = g(w · x) for x ∈ Rn , we have O2 exp(−α`(w)) = O2 f 00 (z)xx> , where f (z) = exp(−αg(z)). For the logistic loss, we have g(z) = log(1 + exp(z)) (without loss of generality, we consider a negative example), and so f (z) = (1 + exp(z))−α . Then, f 00 (z) = αez (1 + ez )−α−2 (αez − 1). We need the largest α such that f 00 (z) ≤ 0, given a fixed z. We can see by inspection that α = 0 is a zero. Since ez (1 + ez )−α−2 > 0, from the term (αez − 1) we conclude α = e−z is the largest value of α where f 00 (z) ≤ 0. Note that z = wt · xt , and so |z| ≤ D/2 since kxt k2 ≤ 1, and so taking the worst case over wt ∈ W and xt with kxt k2 ≤ 1, we have α = exp(−D/2).

44.3

Open Problem: Better Bounds for Online Logistic Regression

tion for web advertising and estimating the probability that an email message is spam. We formalize the problem as follows: on each round t the adversary ...

224KB Sizes 1 Downloads 144 Views

Recommend Documents

Logistic Regression - nicolo' marchi
These scripts set up the dataset for the problems and make calls to functions that you will write. .... 1.2.3 Learning parameters using fminunc. In the previous ...

t-Logistic Regression
All code is written in Matlab, and for the linear SVM we use the Matlab .... The red (dark) bars (resp. cyan (light) bars) indicate the frequency of ξ assigned to .... Software available at http://www.kyb.mpg.de/bs/people/fabee/universvm. html. 9 ..

[PDF] Applied Logistic Regression
of correlated outcome data A wealth of additional material for topics ranging from Bayesian methods to assessing model fit Rich data sets from real-world studies ...

bayesian multinomial logistic regression for author ...
be identified. We encode the fact that a document belongs to a class (e.g. an author) k ∈ {1,...,K} by a .... classification problems from the Irvine archive using multinomial logistic regression with an L1 penalty (equivalent .... the lasso regres

predictive modeling using logistic regression sas course notes pdf ...
Page 1 of 1. predictive modeling using logistic regression sas course notes pdf. predictive modeling using logistic regression sas course notes pdf. Open. Extract.

SAY, STAY, STRIVE: An Ordered Logistic Regression ...
the company offering on-site personal services such as ATMs, dry cleaners, banking ..... Next to Communication, Compensation is the variable with the biggest ...

SAY, STAY, STRIVE: An Ordered Logistic Regression ...
... (n.d.) Stata annotated output: Ordered logistic regression. Retrieved February 1, 2008, from http://www.ats.ucla.edu/stat/stata/output/stata_ologit_output.htm.