Online Learning Without Prior Information
Ashok Cutkosky, Kwabena Boahen
Problem Definition and Prior Work
The case in which we have no bound on either or is common in practice. A standard pragmatic approach to this lack of information is to simply make a guess for these parameters and then apply an algorithm that uses the guess as input, but this approach is theoretically unsound in online learning, and rather laborious and inelegant in general. We explore lower bounds and algorithms that adapt to the unknown quantities in a principled way in this paper.
Where no information is given, we prove that there is a frontier of matching lower and upper bounds on that trades-off a term with a term along two dimensions, which we parametrize by and .The square root is missing from the exponential term because we improved the lower bound given in Cutkosky and Boahen (2016) (see Section 3). Along the first dimension, the exponential penalty is reduced to for any at the expense of rescaling the regret’s term to . Along the second dimension, the logarithm’s power in the term is reduced to for any at the expense of increasing the exponential penalty to . We prove the lower bounds by constructing a specific adversarial loss sequence, and we prove the upper bounds by providing a family of algorithms whose regret matches the lower bound frontier for any and .
Notation and Setup
We will focus all of our lower bounds in Section 3 and algorithms in Section 5 on the case in which the domain is an entire Hilbert space, so that has infinite diameter and no boundary. This case is very common in practical optimization optimization problems encountered in machine learning, in which any constraints are often only implicitly enforced via regularization. Our objective is to design lower bounds and algorithms such that depends on , , and without prior knowledge of these parameters.
A Frontier of Lower Bounds
In this section we give our frontier of lower bounds for online optimization without prior information. First we describe our adversarial loss sequence and lower bound frontier along the dimension, and then we extend the argument to obtain the full two dimensional frontier parametrized by both and .
The cost that an algorithm pays when faced with the adversarial sequence is stated formally in the following Theorem.
where , and .
The first inequality in this bound demonstrates that it is impossible to guarantee sublinear regret without prior information while maintaining dependence on and ,it is possible to guarantee sublinear regret in exchange for dependence, see Orabona and Pál (2016b) but the second inequality provides hope that if the loss sequence is limited to small jumps in , then we might be able to obtain sublinear regret. Specifically, from the first inequality, observe that in order to bring the exponential term to lower than , the value of needs to be at least , which causes the non-exponential term to become . However, the second inequality emphasizes that our high regret is the result of a large jump in the value of , so that we might expect to do better if there are no such large jumps. Our upper bounds are given in the form of algorithms that guarantee regret matching the second inequality of this lower bound for any , showing that we can indeed do well without prior information so long as does not increase too quickly.
2 Trade-offs in the Logarithmic exponent γ𝛾\gamma
To extend the frontier to the dimension, we modify our adversarial sequence by setting instead of . This results in a penalty that is exponential in , which we express as a multiple of . Since , we are getting a larger exponential penalty even though the adversarial subgradients have decreased in size, illustrating that decreasing the logarithmic factor is very expensive.
The full frontier is stated formally in the following Theorem.
where and .
Again, the first inequality tells us that adversarial sequences can always deny the algorithm sublinear regret and the second inequality says that so long as grows slowly, we can still hope for sublinear regret. This time, however, the second inequality appears to blow up when . In this case, regardless of and so the value of is never very large, keeping the exponent in the second inequality less than 1 so that the singularity in the exponent does not send the bound to infinity. This singularity at tells us that the adversary does not need to be “very adversarial” in order to force us to experience exponential regret.
To gain some more intuition for what happens at , consider a model in which the adversary must commit ahead of time to some (which corresponds to picking ), unknown to the optimization algorithm, such that for all . When a bound is known to the algorithm ahead of time, then it is possible to achieve regret (e.g. see Orabona and Pál (2016a)). However, note that when , committing to an appropriate would not prevent an adversary from using the sequence of Theorem 2. Therefore, Theorem 2 tells us that algorithms which achieve regret are inherently very fragile because if the bound is incorrect (which happens for large enough ), then the adversary can force the algorithm to suffer regret for arbitrarily large .
Continuing with the model in which the adversary must commit to some unknown ahead of time, suppose we are satisfied with regret for some . In this case, after some (admittedly possibly very large) number of iterations, the exponential term in the second inequality no longer grows with , and the adversarial strategy of Theorem 2 is not available because this strategy requires a choice of that depends on . Therefore an algorithm that guarantees regret matching the second inequality for some and will obtain an asymptotic dependence on that is only .
These lower bounds show that there is a fundamental frontier of tradeoffs the between parameters and and the exponential penalty. Now we proceed to derive algorithms that match any point on the frontier without prior information.
Regret Analysis without Information
In this section we provide the tools used to derive algorithms whose regret matches the lower bounds in the previous section. Our algorithms make use of the Follow-the-Regularized-Leader (FTRL) framework, which is an elegant and intuitive way to design online learning algorithms (see Shalev-Shwartz (2011); McMahan (2014) for detailed discussions). After seeing the loss of the online learning game, an FTRL algorithm chooses a function (called a regularizer), and picks according to:
Careful choice of regularizers is obviously crucial to the success of such an algorithm, and in the following we provide simple conditions on sufficient for FTRL to achieve optimal regret without prior information. Our analysis generalizes many previous works for online learning with unconstrained (e.g. Orabona (2013, 2014); Cutkosky and Boahen (2016)) in which regret bounds were proved via arduous ad-hoc constructions. Further, our techniques improve the regret bound in the algorithm that does not require prior information of Cutkosky and Boahen (2016). We note that an alternative set of conditions on regularizers was given in Orabona and Pál (2016a) via an elegant reduction to coin-betting algorithms, but this prior analysis requires a known bound on .
Our regularizers take the form for some fixed function and numbers and . The value specifies the corresponding tradeoff parameter in the lower-bound frontier, while the function specifies the value of . The values for and do not depend on or , but are carefully chosen functions of the observed gradients that guarantee the desired asymptotics in the regret bound.
Prior analyses of FTRL often make use of strongly-convex regularizers to simplify regret analysis, but it turns out that strongly-convex regularizers cannot match our lower bounds. Fortunately, there is a simple generalization of strong-convexity that will suffice for our purposes. This generalized notion is very similar to a dual version of the “local smoothness” condition used in Orabona (2013). We define this generalization of strong-convexity below.
We’ll usually just write -strongly convex instead of -strongly convex since our definition is purely a generalization of the standard one. We will also primarily make use of the special case .
2 Adaptive regularizers
Now we present a few definitions that will allow us to easily construct sequences of regularizers that achieve regret bounds without information. Intuitively, we require that our regularizers grow super-linearly in order to ensure that always has a minimal value. However, we do not want to grow quadratically because this will result in regret. The formal requirements on the shape of are presented in the following definition:
For any , there exists a such that for all .
is called a -adaptive regularizer. We also define the useful auxiliary function and by mild abuse of notation, we define .
We will use adaptive regularizers as building blocks for our FTRL regularizers , so it is important to have examples of such functions. We will provide some tools for finding adaptive regularizers in Section 5, but to keep an example in mind for now, we remark that is a -adaptive regularizer where is the norm.
The following definition specifies the sequences and which we use to turn an adaptive regularizer into the regularizers used for our FTRL algorithms:
Let be a norm and be the dual norm (). Let be a sequence of subgradients and set . Define the sequences and recursively by:
Suppose is a -adaptive regularizer and . Define
Now without further ado, we give our regret bound for FTRL using these regularizers.
Suppose is a -adaptive regularizer and is some arbitrary sequence of subgradients. Let , and let be defined as in Definition 5.
Then FTRL with regularizers achieves regret
This bound consists of three terms, the first of which will correspond to the term in our lower bounds and the last of which will correspond to the exponential penalty. The middle term is a constant independent of and . To unpack a specific instantiation of this bound, consider the example adaptive regularizer . For this choice of , we have so that the first term in the regret bound matches the term in our lower bound with . Roughly speaking, , so that and the quantity matches the exponential penalty in our lower bound. In the following section we formalize this argument and exhibit a family of adaptive regularizers that enable us to design algorithms whose regret matches any desired point on the lower bound frontier.
Optimal Algorithms
In this section we construct specific adaptive regularizers in order to obtain optimal algorithms using our regret upper bound of Theorem 6. The results in the previous section hold for arbitrary norms, but from this point on we will focus on the norm. Our regret upper bound expresses regret in terms of the function . Inspection of the bound shows that if is exponential in , and , then our upper bound will match (the second inequality in) our lower bound frontier. The following Collary formalizes this observation.
If is an -adaptive regularizer such that
then for any , FTRL with regularizers yields regret
We call regularizers that satisfy these conditions -optimal.
With this Corollary in hand, to match our lower bound frontier we need only construct a -optimal adaptive regularizer for all . Constructing adaptive regularizers is made much simpler with Proposition 8 below. This proposition allows us to design adaptive regularizers in high dimensional spaces by finding simple one-dimensional functions. It can be viewed as taking the place of arguments in prior work (McMahan and Orabona, 2014; Orabona and Pál, 2016a; Cutkosky and Boahen, 2016) that reduce high dimensional problems to one-dimensional problems by identifying a “worst-case” direction for each subgradient .
Let be the norm . Let be a three-times differentiable function from the non-negative reals to the reals that satisfies
.
Then is a -adaptive regularizer.
Now we are finally ready to derive our first optimal regularizer:
Let be the norm. Let . Then is a -optimal, -adaptive regularizer.
We can use Proposition 8 to prove this with a few simple calculations:
Now the conclusion of the Proposition is immediate from Proposition 8 and inspection of the above equations.
A simple application of Corollary 7 shows that FTRL with regularizers matches our lower bound with for any desired .
In fact, the result of Proposition 9 is a more general phenomenon:
Let be the norm. Given , set . Then is a -optimal, -adaptive regularizer.
Since , and so satisfies the first four conditions of Proposition 8. It remains to characterize and , which we do by finding lower and upper bounds on :
where the inequality follows since , which can be verified by differentiating both sides. Therefore . This lower-bound implies
which gives us the last condition in Proposition 8, as well as the first condition for -optimality.
This implies which gives us the second condition for -optimality.
Thus, by applying Theorem 6 to the regularizers of Proposition 10, we have a family of algorithms that matches our family of lower-bounds up to constants. The updates for these regularizers are extremely simple:
The guarantees of Theorem 6 do not make any assumptions on how is chosen, so that we could choose using prior knowledge if it is available. For example, if a bound on is known, we can set . This reduces the exponentiated quantity to a constant, leaving a regret of . This bound holds without requiring a bound on . Thus our algorithms open up an intermediary realm in which we have no bounds on or , and yet we can leverage some other information to avoid the exponential penalty.
FreeRex
Now we explicitly describe an algorithm, along with a fully worked-out regret bound. The norm used in the following is the norm (), and our algorithm uses the adaptive regularizer . Similar calculations could be performed for arbitrary using the regularizers of Proposition 10, but we focus on the because it allows for simpler and tighter analysis through our closed-form expression for . Since we do not require any information about the losses, we call our algorithm FreeRex for Information-free Regret via exponential updates.
The regret of FreeRex (Algorithm 1) is bounded by
Define . Then is a -adaptive regularizer by Proposition 9. Therefore we can immediately apply Theorem 6 to obtain
where we’ve defined .
From Proposition 19 (part 2) we have . We also have , so we are left with
Now it remains to bound and . From our expression for , we have
Substituting the value , we conclude
From which the result follows by substituting in our expression for .
As a specific example, for we numerically evaluate the bound to get
Conclusions
We have presented a frontier of lower bounds on the worst-case regret of any online convex optimization algorithm without prior information. This frontier demonstrates a fundamental trade-off at work between and terms. We also present some easy-to-use theorems that allow us to construct algorithms that match our lower bound for any chosen and . Note that by virtue of not requiring prior information, our algorithms are nearly hyperparameter-free. They only require the essentially unavoidable trade-off parameters and . Since our analysis does not make assumptions about the loss functions or comparison point , the parameters and can be freely chosen by the user. Unlike other algorithms that require or , there are no unknown constraints on these parameters.
Although we answer some important questions, there is still much to do in online learning without prior information. For example, it is possible to obtain regret without prior information (Orabona and Pál, 2016b), so it should be possible to extend our lower-bound frontier beyond . Further, it would be valuable to further characterize the conditions for which the adversary can guarantee regret that is exponential in . We showed that one such condition is that there must be a large jump in the value of , but there may very well be others. Fully characterizing these conditions should allow us design algorithms that smoothly interpolate between “nice” environments that do not satisfy the conditions and fully adversarial ones that do.
Finally, while our analysis allows for the use of arbitrary norms, we focus our examples on the norm. It may be interesting to design adaptive regularizers with respect to a more diverse set of norms, or to extend our theory to encompass time-changing norms.
References
Appendix A Lower Bound Proof
Before getting started, we need one technical observation:
and set . Then for all sufficiently large ,
For sufficiently large , this quantity is positive and increasing in . Therefore for sufficiently large ,
where the third inequality holds only for sufficiently large .
Now we prove Theorem 2, restated below. Theorem 1 is an immediate consequence of Theorem 2, so we do not prove it seperately. See 2
Let . Let , and set Suppose is such that
For all , .
For all , (by Proposition 12).
We consider the quantity . There are two cases, either the is less than 1, or it is not.
Case 1:
Set . Then clearly
Now observe that we have chosen carefully so that
where we have used to insert factors of where appropriate.
Observing that for all , we can also easily conclude (using properties 3 and 5 of ):
Case 2:
By definition of , there exists some and such that and for all , .
Suppose for contradiction that for all . Then for all ,
Since the second term does not depend on , this implies that for sufficiently large , , which contradicts our choice of . Therefore for some .
Let be the the smallest index such that . Since for , we have
where we have used property 1 of to conclude .
where we have used in the last line. Now we use the fact that (by property 6 of ) to write
where we have used the fourth assumption on in the last line.
Since we are considering , we can always insert arbitrary multiples of :
Now we relate the quantity in the exponent to . We have and so that
Now observe that so that we have
Further, since for all , condition 5 on tells us that
Therefore we can put everything together to get
Appendix B FTRL regret
We prove a general bound on the regret of FTRL. Our bound is not fundamentally tighter than the many previous analyses of FTRL, but we decompose the regret in a new way that makes our analysis much easier. We make use of “shadow regularizers”, that can be used to characterize regret more easily. Our bound bears some similarity in form to the adaptive online mirror descent bound of (Orabona et al., 2014) and the analysis of FTRL with varying regularizers of (Cutkosky and Boahen, 2016).
We define for and . We’ll use the symbols as intermediate variables in our proof in an attempt to keep the algebra cleaner. By definition of , for all we have
Summing this inequality across all we have
Now we substitute our values of for and to obtain
Appendix C Facts About Strong Convexity
In this section we prove some basic facts about our generalized strong convexity.
is -strongly convex for any convex function .
is -strongly convex for any .
Suppose and . Let . Then is -strongly convex.
Let and let and . Then . By convexity and strongly convexity respectively we have:
so that adding these equations shows that is -strongly convex.
This follows immediately by multiplying the defining equation for strong convexity of by .
Let and let . Then .
Note that for any linear function , if is -strongly convex, then is also -strongly convex.
We show that the following lemma from (McMahan, 2014) about strongly-convex functions continues to hold under our more general definition. The proof of this lemma (and the next) are identical to the standard ones, but we include them here for completeness.
Suppose and are arbitrary convex functions such that is -strongly convex. Let and and let . Then
Since , we have and so by definition of strong convexity we have
Now let . Consider the function . Then we must have and so by strong-convexity again we have
Finally, we have an analog of a standard way to check for strong-convexity:
Appendix D Proof of Theorem 8
First we prove a proposition that allows us to generate a strongly convex function easily:
Where the last line follows since for all . Since , is always decreasing for positive and so we have
for all . Therefore we can apply Proposition 16 to conclude that is -strongly convex.
Now we prove Proposition 8, restated below: See 8
It’s clear that so the first condition for being an adaptive regularizer is satisfied.
Next we will show that so that we can apply Proposition 17. It suffices to show
Clearly this identity holds for . Differentiating the right-hand-side of the equation, we have
since and . Thus is non-decreasing and so must always be non-negative.
Therefore, by Proposition 17, is -strongly convex. Also, since , when so that satisfies the second condition for being an adaptive regularizer.
Finally, observe that implies by definition that for any there exists a such that whenever . Therefore we immediately see that for all so that the third condition is satified.
Appendix E Proof of Theorem 6
First we define new regularizers analagously to that we will use in conjunction with Theorem 13:
Given a norm and a sequence of subgradients , define and as in Definition 5, and define . We define recursively by:
Further, given a and a non-decreasing sequence of positive numbers , define by:
Throughout the following arguments we will assume and are the sequences defined in Definitions 5 and 18.
The next proposition establishes several identities that we will need in proving our bounds.
Suppose is a -adaptive regularizer, and be some sequence of subgradients. Then the following identities hold:
Let be such that for and for . There exists some subgradient of at , which with mild abuse of notation we call , such that:
Let be such that for and for . Then we can write . From this it follws that there is some subgradient of at , which we refer to (by mild abuse of notation) as such that
Note that we must appeal to a subgradient rather than the actual gradient in order to encompass the case that is on the boundary of .
Now we are ready to prove the various parts of the Proposition.
By definition of and we have
where in the last line we used the fact that to conclude that .
For the other direction, we have two cases:
.
.
Case 1 :
where in the last line we used the fact that .
Case 2 :
Now we follow the exact same argument as in Case 1 to show , which proves the desired result.
We proceed by induction for both claims. The statements are clear for . Suppose
Then observe that by the induction hypothesis, and . Therefore , proving the first claim.
The induction step for the second claim follows from the observations:
so that as desired.
Let be the indicator of the set - if and otherwise. Observe that . Observe that .
Now the third equation follows from Lemma 15, setting and . Then by inspection of the definitions of and , we have and . Further, by Corollary 14, is -strongly convex. We can re-write and in terms of by simply replacing the s with s and removing the s. Now we use the facts noted at the beginning of the proof:
Applying these identities with Lemma 15 we have:
And we divide by to conclude the desired identity.
Using the already-proved parts 1 and 3 of this Proposition and definition of dual norm, we have
The fifth part of the Proposition follows directly from part 3 by the definition of dual norm.
Case 1 : In this case we have
Case 2 :
Suppose a -adaptive regularizer and is some sequence of subgradients. We use the terminology of Definition 5. Recall that we define and . Suppose either of the follow holds:
and .
and .
As in Proposition 19, we use to simply mean some particular subgradient of at .
Case 1: and :
By definition of adaptive regularizer (part 2), we must have since . Therefore .
By definition of , when we can apply Proposition 19 (parts 1 and 5) to obtain
We remark that in the calculations above, we showed
Case 2 , and :
Again, by definition of adaptive regularizer (part 2), we must have since . Therefore . Let be as in Proposition 19 part 4. Oberve that and are both in , so that we have and . Then we have:
Now by definition of , when we have
The next theorem is a general fact about adaptive regularizers that is useful for controlling :
Let’s differentiate: . Thus it suffices to show
But this follows immediately from the definition of subgradient, since .
Suppose is a -adaptive regularizer and is an arbitrary sequence of subgradients (possibly chosen adaptively). Using the terminology of Definition 5,
This follows from the fact that , and property 4 of an adaptive regularizer ( is a non-decreasing function of ). By Proposition 19 (part 1), we have . Therefore:
Suppose is a -adaptive regularizer and is an arbitrary sequence of subgradients (possibly chosen adaptively). We use the regularizers of Definition 5. Recall that we define and . Define
By Lemma 20, whenever either or we must have
When , then we have . Thus when and , by Proposition 19 (part 5), we have
Therefore when we have (using Proposition 19 part 1):
so that we can improve our conditional bound to:
When both and are less than than then we also have
Let be a sequence of non-negative numbers such that . Then
We proceed by induction on . For the base case, we observe that . Suppose . Then we have
The next lemma establishes some identities analogous to the bounds , and . These are useful for dealing with increasing in our regret bounds.
Using part 1 from Proposition 19, and observing that , we have
For the second part of the lemma, we observe that for ,
Similarly, we also have so that
where in the last line we have used .
Combining these two calculations, we have
Let be the indices such that , and define . We will show that for any with ,
We’ll prove by induction that equation (2) holds for all . Suppose it holds for some . Then by concavity of , we have
To finish the induction, we show that . We factor out the non-negative quantity , and then observe that since (and in particular, for any ).
Therefore equation (2) holds for all , so that we have
so that equation (1) holds. Now we write (using the convention that if ):
where in the last step we have observed that by definition of , for all and used Lemma 24.
Since , we immediately recover the lower bound on . The upper bound follows from Proposition 19 (part 2), which states
Now we’re ready to prove Theorem 6, which we restate for reference: See 6
Using Theorem 13 and Lemmas 22 and 23, our regret is bounded by
Now using Lemma 25 we can simplify this to
Finally, observe that each value of in the sum is at least twice the previous value, so that by Lemma 24 we conclude
Finally, we observe that (by Lemma 26), , which gives the first inequality in the Theorem statement.
Using the fact that (from Proposition 19 part 2), we have and it is clear that , so that we recover the second inequality as well.