Incremental Learning-to-Learn with Statistical Guarantees
Giulia Denevi, Carlo Ciliberto, Dimitris Stamos, Massimiliano Pontil
INTRODUCTION
Learning-to-learn (LTL) or meta learning aims at finding an algorithm that is best suited to address a class of learning problems (tasks). These tasks are sampled from an unknown meta distribution and are only partially observed via a finite collection of training examples, see and references therein. This problem plays a large role in artificial intelligence in that it can improve the efficiency of learning from human supervision. In particular, substantial improvement over “learning in isolation” (also known as independent task learning) is to be expected when the sample size per task is small, a setting which naturally arises in many applications .
LTL is particularly appealing when considered from an online or incremental perspective. In this setting, which is sometimes referred to as lifelong learning (see, e.g. ), the tasks are observed sequentially – via corresponding sets of training examples – from a common environment and we aim to improve the learning ability of the underlying algorithm on future yet-to-be-seen tasks from the same environment. Practical scenarios of lifelong learning are wide ranging, including computer vision , robotics , user modelling and many more.
Although LTL is naturally suited for the incremental setting, surprisingly theoretical investigations are lacking. Previous studies, starting from the seminal paper by Baxter , have almost exclusively considered the setting in which the tasks are given in one batch , that is, the meta algorithm processes multiple datasets from the environment jointly and only once as opposed to sequentially and indefinitely. The papers present results in an online framework which applies to a finite number of tasks using different performance measures. Perhaps most related to our work is , where the authors consider a general PAC-Bayesian approach to lifelong learning based on the exponentially weighted aggregation procedure. Unfortunately, this approach is not efficient for large scale applications as it entails storing the entire sequence of datasets during the meta learning process. LTL also bears strong similarity to multitask learning (MTL) and much work has been done on the theoretical study of both batch and online multitask learning algorithms. However multitask learning aims to solve the different – and perhaps less challenging – problem of learning well on a prescribed set of tasks (the learned model is tested on the same tasks used during training) whereas LTL aims to extrapolate to new tasks.
The principal contribution of this paper is to propose an incremental approach to learning-to-learn and to analyse its statistical guarantees. This incremental approach is appealing in that it efficiently processes one dataset at the time, without the need to store previously encountered datasets. We study in detail the case of linear representation learning, in which an underlying learning algorithm receives in input a sequence of datasets and incrementally updates the data representation so as to better learn future tasks. Following previous work on LTL , we measure the performance of the incremental meta algorithm by the transfer risk, namely the average error obtained by running the underlying algorithm with the learned representation, over tasks sampled from the meta distribution.
Specifically, in this work we choose the underlying algorithm to be Ridge Regression parameterized by a positive semidefinite matrix. The incremental LTL approach we propose aims at optimizing the future empirical error incurred by Ridge Regression over a class of linear representations. For this purpose, we propose to apply Projected Stochastic Subgradient Algorithm (PSSA). We show that the objective function of the resulting meta algorithm is convex and we give a non-asymptotic convergence rate for the algorithm in high probability. A remarkable feature of our learning bound is that it is comparable to previous bounds for batch LTL. Our proof technique leverages previous work on learning-to-learn with tools from online convex optimization, see and references therein.
The paper is organized as follows. In Sec. 2, we review the LTL problem and describe in detail the case of linear feature learning with Ridge Regression. In Sec. 3, we present our incremental meta algorithm for linear feature learning. Sec. 4 contains our bound on the excess transfer risk for the proposed algorithm and in Sec. 5 we compare the bound to a previous bound for the batch setting. In Sec. 6, we report preliminary numerical experiments for the proposed algorithm and, finally, Sec. 7 summarizes the paper and highlight directions of future research.
PROBLEM FORMULATION
A well-established approach to tackle the learning problem is offered by regularized empirical risk minimization. This corresponds to the family of algorithms such that, for any ,
where is a feature map, is the Hilbert space of functions such that for any and
denotes the empirical risk of function on the set .
Since for any linear feature map there exists a PSD matrix such that Eq. (2) and Eq. (4) are equivalent, in the following we will refer to as the representation used by algorithm .
2 Learning to Learn DD
A natural question is how to choose a good representation for a given family of related learning problems. In this work we consider the approach of learning it from data. In particular, following the seminal work of , we consider a setting where we are provided with an increasing number of tasks and our goal is to find a joint representation such that the corresponding algorithm is suited to address all such learning problems. The underlying assumption is that all tasks that we observe share a common structure that algorithm can leverage in order to achieve better prediction performance.
More formally, we assume that the tasks we observe are independently sampled from a meta distribution on the set of probability measures on . According to the literature on the topic (see e.g. ) we refer to the meta distribution as the environment and we identify each task sampled from by its corresponding distribution , from which we are provided with a training dataset of points sampled independently from . While it is possible to consider a more general setting, for simplicity in this work we study the case where for each task we sample the same number of training points. In line with the independent task learning setting, the goal of a “learning to learn” algorithm is therefore to find the best parameter minimizing the so-called transfer risk
over a set of candidate representations.
The term is the expected risk that the corresponding algorithm , when trained on the dataset , would incur on average with respect to the distribution of tasks induced by . That is, to compute the transfer risk, we first draw a task and a corresponding -sample from , we then apply the learning algorithm to obtain an estimator and finally we measure the risk of this estimator on the distribution .
The problem of minimizing the transfer risk in Eq. (5) given a finite number of training datasets sampled from the corresponding tasks , has been subject of thorough analysis in the literature . Most work has been focused on the so-called “batch” setting, where all such training datasets are provided at once. However, by its nature, LTL is an ongoing (possibly never ending) process, with training datasets observed a few at the time. In such a scenario the meta algorithm should allow for an evolving representation , which improves over time as new datasets are observed. In the following we propose a meta algorithm to learn online with respect to the tasks, allowing us to transfer past experience about the environment in an efficient manner, without requiring the memorization of training data, which could be prohibitive in large scale applications. We will study the theoretical guarantees of the proposed algorithm and compare it to its batch counterpart in terms of both statistical and empirical performance.
3 Connection with Multitask Learning
LTL is strongly related to multitask learning (MTL) and in fact, as we will see later for the algorithm in Eq. (4), approaches developed for MTL can be used as inspiration to design algorithms for LTL. In multi-task learning a fixed number of tasks is provided up front and, given datasets , each sampled from its corresponding distribution, the goal is to find a joint representation incurring a small average expected risk . In this sense, the main difference between LTL and MTL is that the former aims to guarantee good prediction performance on future tasks, while the latter goal is to guarantee good prediction performance on the same tasks used to train .
A well-established approach to MTL is multitask feature learning . This method consists in solving the optimization problem
where is the interior of , namely the set of PSD invertible matrices with trace strictly smaller than . This leads to the equivalent problem
ONLINE LEARNING-TO-LEARN
Motivated by the above connection with multitask learning, we propose an online LTL approach to approximate the solution of the learning problem
over the set introduced in Eq. (7). We consider the setting in which we are provided with a stream of independent datasets , each sampled from an individual task distribution and our goal is to find an estimator in that improves incrementally as the number of observed tasks increases.
A key observation motivating the online procedure proposed in this work, is that in the independent task learning setting, standard results from learning theory (see e.g. ) allow one to control the statistical performance of regularized empirical risk minimization, providing bounds on the generalization error of as
where is a decreasing function converging to as , while is a measure of complexity of , which is large for more “expressive” representations and smaller otherwise.
Eq. (11) suggests us to use the empirical risk as a proxy for the expected risk . Therefore, we introduce the so-called future empirical risk ,
which in the sequel, introducing the shorthand notation for any PSD matrix , will be rewritten as
Problem (14) can be approached with stochastic optimization strategies. Such methods proceed by sequentially sampling a point (dataset in this case) and performing an update step. In recent years, stochastic optimization, finding its origin in the Stochastic Approximation method by Robbins and Monro , has been effectively used to deal with large scale applications. We refer to for a more comprehensive discussion about this topic. We therefore propose to apply Projected Stochastic Subgradient Algorithm (PSSA) , to solve the optimization problem in Eq. (14). The candidate representation coincides in this case with the mean after iterations and it is known as Polyak-Ruppert averaging scheme in the optimization literature. Algorithm 1 reports the application of PSSA to when is convex on the set of PSD matrices. It requires iteratively: sampling a dataset , performing a step in the direction of a subgradient of at the current point, and projecting onto the set (which can be done in a finite number of iterations, see 16 in Appendix E ). Note that in this case, since the function is convex, there is no ambiguity in the definition of the subdifferential (see e.g. ) and we can rely on the convergence of Algorithm 1 to a global minimum of over for a suitable choice of step-sizes, as discussed in Sec. 4.
2 LTL with Ridge Regression
Plugging this solution in the definition of , a direct computation yields that
is convex on the set of PSD matrices.
is -Lipschitz w.r.t. the Frobenius norm.
is -Lipschitz w.r.t. the Frobenius norm.
The proposition above establishes the convexity of Problem (13) for the case of the square loss. This fact is important in that it guarantees no ambiguity in applying Algorithm 1 to our setting and moreover, since is differentiable, Algorithm 1 becomes a Projected Stochastic Gradient Algorithm.
THEORETICAL ANALYSIS
In this section, we study the statistical properties of Algorithm 1 for the case of the square loss. Below we report the main result of this work, which characterizes the non-asymptotic behavior of the estimator produced by Algorithm 1 with respect to a minimizer . To present our results we introduce the matrix
denoting the covariance of the input data, obtained by averaging over all input marginals sampled from . This quantity plays a key role in identifying the environments for which it is favorable to adopt a LTL strategy instead of solving the tasks independently, see for a discussion. We also denote with the operator norm of , which corresponds to the largest singular value.
with probability at least with respect to the independent sampling of tasks and training sets for any .
In Sec. 5, we will compare Thm. 2 with the statistical bounds available for state of the art LTL batch procedures. We will see that the statistical behaviour of these two approaches is essentially equivalent, with Online LTL being more appealing given the lower requirements in terms of both number of computations and memory.
In the rest of this section we give a sketch of the proof for Thm. 2. Proofs of intermediate results are reported in the appendix.
The statistical analysis of Algorithm 1 hinges upon the following decomposition for the excess transfer risk of the estimator :
where the matrix denotes a minimizer of the future empirical risk over , that is, .
Eq. (4.1) decomposes in a uniform generalization error, implicitly encoding the complexity of the class of algorithms parameterized by and an excess future empirical risk, measuring the discrepancy between the estimator and the minimizer of . In the following we describe how to bound these two terms.
2 Bounding the Uniform Generalization Error
Results providing generalization bounds for the class of regularized empirical risk minimization algorithms considered in this work are well known. The following result, which is taken from , leverages an explicit estimate of the generalization bound introduced in Sec. 3.1 for independent task learning (see Eq. (11)) to obtain a uniform bound over the class of algorithms parametrized by .
For completeness, we report the proof of this proposition in Appendix B.3.
3 Bounding the Excess Future Empirical Risk
Providing bounds for the excess future empirical risk introduced in Eq. (4.1) consists in studying the convergence rates of Algorithm 1 to the minimum of over in high probability with respect to the sample of tasks from and datasets from for any .
To this end, we leverage classical results from the online learning literature . In online learning, the performance of an online algorithm returning a sequence over trials is measured in terms of its regret, which in the context of this work corresponds to
Differently from the statistical setting considered in this work, in the online setting no assumption is made about the data generation process of , which could be even adversely generated. Therefore, an algorithm that is able to solve the online problem (i.e. if its regret vanishes as ) can be also expected to solve the corresponding problem in the statistical setting. This is indeed the case for Algorithm 1, for which the following lemma provides a non-asymptotic regret bound.
This lemma is a corollary of Prop. 1 combined with classical results on regret bounds for Projected Online Subgradient Algorithm . We refer the reader to Appendix D.1 for a more in-depth discussion and for a detailed proof.
In our setting, the datasets are assumed to be independently sampled from the underlying environment. Combining this assumption with the regret bound in 4, we can control the excess future empirical risk by means of so-called online-to-batch conversion results , leading to the following proposition.
The result above follows by combining Prop. 1 with online-to-batch results (see e.g. Thm. in and ). In Appendix D.2 we provide the complete proof of this statement together with a more detailed discussion about this topic. At this point we are ready to give the proof of Thm. 2.
The claim follows by combining Prop. 3 and Prop. 5 in the decomposition of the error given in Eq. (4.1). ∎
ONLINE LTL VERSUS BATCH LTL
In this section, we compare the statistical guarantees obtained for our online meta algorithm with a state of the art batch LTL method for linear feature learning. We also comment on the computational cost of both procedures.
Given a finite collection of datasets, a standard approach to approximate a minimizer of the future empirical risk is to take a representation minimizing the multitask empirical risk
over the set . Such a choice has been extensively studied in the LTL literature . Here we report a result analogous to Thm. 2, characterizing the discrepancy between the transfer risks of and .
The result above is obtained by further decomposing the error as done in Eq. (4.1). In particular, since the multitask empirical error provides an estimate for the future empirical risk, it is possible to to control the overall error by further bounding the term uniformly with respect to . This last result was originally presented in ; in Appendix C we report the complete analysis of such decomposition, leading to the bound in Thm. 6.
2 Statistical Considerations
We now are ready to compare the bounds on the excess transfer risk for the representations resulting from the application of the online procedure (see Thm. 2) and the batch one (see Thm. 6); this provides a first indication of the behavior of the different algorithms. However, it should be kept in mind that we are comparing upper bounds, hence our considerations are not conclusive and further analysis by means of lower bounds for both algorithms would be valuable.
At first, we observe that both bounds reflect the fact that the LTL setting is more challenging than the MTL setting. As we have remarked in Sec. 2.3, MTL aims at bounding the excess averaged expected risk relative to a fixed set of tasks. Such bounds can be expressed as a function , with as for any . In LTL, the bounds study the behavior of the excess transfer risk, measuring how well the candidate estimator will work on a new task sampled from the environment. Therefore, it is no longer possible that for for any , we only have that when and simultaneously tend to infinity.
Thm. 2and Thm. 6 are both composed of three terms. The first term is exactly the same for both procedures and this is obvious looking at the decompositions used to deduce both results. This term can be interpreted as a within-task-estimation error, that depends on the number of points used to train the underlying learning algorithm (in our case Ridge Regression with a linear feature map). This term, similarly to the MTL setting, highlights the advantage of exploiting the relatedness of the tasks in the learning process in comparison to independent task learning (ITL). Indeed, if the inputs are distributed on a high dimensional manifold, then , while upper bounds for ITL have a leading constant of 1. In particular, if the marginal distributions of the tasks are uniform on the dimensional unit sphere; see also for a more detailed discussion. The last term in the bounds expresses the dependency on the confidence parameter and it is again approximately the same for the batch and the online case. It follows that the main role in the comparison between the online and batch bounds is driven by the middle term, which expresses the dependency of the bound on the number of tasks . This term originates in different ways: in the batch approach it is derived from the application of uniform bounds and it can be interpreted as an inter-task estimation error, while in the online approach, it plays the role of an optimization error. Despite the different derivations, we can ascertain from the explicit formula of the bounds that this term is approximately the same for both procedures. This is remarkable since it implies that the representation resulting from our online procedure enjoys the same statistical guarantees than the batch one, despite its more parsimonious memory and computational requirements.
3 Computational Considerations
After discussing the theoretical comparison between the online and the batch LTL approach, in this section we point out some key aspects regarding the computational costs of both procedures.
Memory. The batch LTL estimator corresponds to the minimizer of the empirical risk in Eq. (28) over all tasks observed so far. The corresponding approach would therefore require storing in memory all training datasets as they arrive in order to perform the optimization. This is clearly not sustainable in the incremental setting, since tasks are observed sequentially and, possibly indefinitely, which would inevitably lead to a memory overflow. On the contrary, in line with most stochastic methods, online LTL has a small memory footprint, since it requires to store only one dataset at the time, allowing to “forget” it as soon as one gradient step is performed.
Time. Online LTL is also advantageous in terms of the number of iterations performed whenever a new task is observed. Indeed, for every new task, online LTL performs only one step of gradient descent for a total of steps after tasks. On the contrary, batch LTL requires finding a minimizer for Eq. (28), which cannot be obtained in closed form but requires adopting an iterative method such as Projected Gradient Descent (see e.g. ). These methods typically require iterations to achieve an error of the order of from the optimum (better rates are possible adopting accelerated methods). However, since for any new task batch LTL needs to find a minimizer for the multitask empirical error in Eq. (28) from scratch, this leads to a total of iterations after tasks. Noting that every such iteration requires to compute gradients of in contrast to the single one of PSSA, this shows that online LTL requires much less operations. In the batch case, a “warm-restart” strategy can be adopted to initialize the Projected Gradient Descent with the representation learned during the previous step, however, as we empirically observed in Sec. 6, online LTL is still significantly faster than batch.
EXPERIMENTS
In this section, we report preliminary empirical evaluations of the online LTL strategy proposed in this work. In particular we compare our method with its batch (or offline) counterpart and independent task learning (ITL) with standard Ridge Regression.
In the online setting the training datasets arrive incrementally and a few at the time. Therefore model selection is performed in parallel: the system keeps track of all candidate representation matrices and whenever a new training task is presented, these matrices are all updated by incorporating the corresponding new observations. The best representation is then returned at each iteration, based on its performance on the validation set .
Figure 1 reports the comparison between the baseline ITL and the proposed online LTL approach in terms of the relative difference of the prediction error on test tasks for the two methods. More precisely, given the mean squared errors (MSE) of online LTL and of ITL averaged across the test tasks, we report the ratio as a percentage improvement. Results are reported across a range of and . We note that the regime considered for these experiments is particularly favorable to LTL, consistently outperforming ITL, which does not leverage any shared structure. As noted in Sec. 5.2, when the number of training points per task is small, the LTL algorithm is unable to capture the underlying representation, even if several tasks are provided in training. To provide further evidence of the performance of online LTL, Figure 2 compares the prediction error of online LTL, batch LTL, and ITL as the number of training tasks increases from to and the number of samples per task is fixed to . In particular we considered the setting where the task datasets are provided incrementally one at the time and the different methods update their corresponding representation accordingly. We also report the performance of the multitask algorithm (MTL) described in Sec. 2.3, performing trace norm regularization on the test set. Clearly, MTL does not fit the learning to learn setting since it optimizes the representation on the test set. In this sense, loosely speaking, the MTL performance provides a lower bound on the performance that we can expect from an “ideal” LTL algorithm. Indeed, we note that MTL consistently outperforms all LTL methods which, however, tend to converge to it as more training tasks are provided.
Interestingly, the online approach is able to rapidly close the gap with batch LTL as the number of training tasks increases. This is particularly favorable since, from the computational perspective, online LTL is significantly faster than its batch counterpart. To further emphasize this aspect, Table 1 compares the computational times required on average by online LTL and batch LTL as and vary. Online LTL is clearly faster then batch LTL. Indeed, as discussed in Sec. 5.3, whenever a new training task is provided, batch LTL requires to perform hundreds or thousands iterations of gradient descent to converge to a minimizer, even when “warm restarting” by initializing with the representation found at the previous step. On the other hand online LTL performs a single gradient step for each new task.
CONCLUSION AND FUTURE WORK
In this work, we have proposed an incremental approach to LTL which estimates a linear data representation that works well on regression tasks coming from a meta distribution. Compared with its batch (or offline) counterpart, this incremental approach is computationally more efficient both in terms of memory and number of operations, while enjoying the same generalization properties. Preliminary experiments have highlighted the favorable learning capability of the proposed learning-to-learn strategy. To our knowledge this is the first efficient incremental algorithm for meta learning for which statistical guarantees have been proved. Previous works either relied on algorithms which require to store the entire data sequence or which do not have statistical guarantees . Our analysis open several directions that will be worth investigating in the near future. First, it would be valuable to extend our analysis to a general class of loss functions. Although not allowing for a closed form expression as in the case of Ridge Regression, we suspect that it would be still be possible to extend our results by leveraging the regularity properties of the underlying learning algorithm. Second, we would like to depart from the feature learning setting by considering a more general family of learning-to-learn algorithms. Inspiration towards this direction is offered by the literature on multitask learning.
APPENDIX
Appendix A PROOF of Prop. 1
Recall the definition of the function in Eq. (17). In order to provide the proof of Prop. 1 we need the following Lemma.
.
.
Let and satisfy for some , for . Then we have that
Moreover, the following formula, which is a direct consequence of Eq. () and Eq. () in , holds:
and since, for every , we have that
and exploiting the symmetry of , we can rewrite:
This last equation contains the elements of the Jacobian in the statement of the proposition.
where in the first inequality we have applied 7-(d) with , for . The statement now follows observing that if , then and if , then .
for any two matrices and ,
by 7-(b): for ,
,
if and , then and ,
The last point is contained in [20, Prop. 1-(i)]; we report here the proof for completeness. To this end, we require some additional notation, which will be also used also in the next section of the appendix.
Coming back to the proof of the proposition, as observed in , it is possible to rewrite the algorithm defined in Eq. (16) in the equivalent form
From Eq. (40), we have that , for any and any dataset . Consequently
Due to the definition of , assuming , the following relations hold:
The claim now follows by combining the last inequality with Eq. (42).
Appendix B UNIFORM BOUNDS for LINEAR FEATURE LEARNING
In this section, we provide the uniform bounds on and (and the corresponding symmetric quantities) for the family of linear feature learning algorithms. Our observations are essentially taken from , we report them for clarity of exposition. We start from recalling some tools from empirical processes, then we state the uniform bounds for a more general class of learning algorithms and finally we specialize the bounds to linear feature learning. We ignore issues of measurability throughout.
For more details about these quantities, we refer to . Given a class of real-valued functions on a set , and given a point , we let
so that and are the corresponding Rademacher and Gaussian averages.
The following theorem is taken from , where the author considers only the inequality for the function . Considering both inequalities allows us to obtain symmetric uniform bounds. The proof follows the same pattern as in .
Let be a probability distribution over the space , let be a real-valued function class on and let . Define the random functions:
If is $\delta\in(0,1]$, we have that
with probability at least in , for .
In the previous two points we can replace with .
B.2 Uniform Bounds for a More General Family of Algorithms
The results presented in this sub-section hold for the infinite dimension case. In the sequel, we let be a generic Hilbert space and we denote by and its scalar product and the induced norm. We let be the set of positive semidefinite bounded linear operators on and, for any operator , we denote its -Schatten norm by , where . We continue to use the notation introduced in the paper and in Remark 1, in particular, is the meta sample and, for any , we denote . Throughout this section we will consider linear models and a learning algorithm processing a training set of points:
hence, according to our notation, we have that for any . For any , define now the more general family of modified algorithms
By this definition, as we have already observed in the proof of Prop. 1-(5) in Sec. A, we have that
for any and consequently
In this way, we can consider the family of learning algorithms , parameterized by the operators . Recall now, for every , the notion of transfer risk
In order to give the next theorem, we need to introduce the Gramian matrix defined by the entries for .
Let and be a bounded set. Consider a function satisfying the condition
for any and for some . Let tasks independently sampled from and sampled from for . Then, for any , we have that
B.3 Application to the Family of Linear Feature Learning Algorithm
Similarly to what observed in Prop. 1-(5) in Sec. A, also in the infinite dimension case, we can cast the family of linear feature learning algorithms in the framework described in the previous sub-section, taking the original vanilla algorithm as Ridge Regression with regularization parameter equal to :
we refer to for more details. Thus, we can apply the results in the previous sub-section to this specific case, in order to obtain the results stated in the paper for the uniform bounds. In fact, in the paper we have analyzed the finite dimension case, but from this analysis, we deduced that they still hold in the infinite dimension setting. The following definition will be used in the sequel.
be 1-bounded if and for any ;
have kernel stability if , for any and for some .
The following two lemmas are essentially taken from and they are respectively immediate consequences of Thm. 9 and Thm. 10 applied to the family of linear feature learning algorithms with restriction to the set
Thanks to the assumption , by [20, Prop. 1], , is -bounded – and in particular, for any and any dataset – with respect to the square loss. Hence, we can apply Thm. 9 to . We restrict to the set , we choose and and we observe that the square loss is -Lipschitz on the interval . ∎
Thanks to the assumption that , by [20, Prop. 1], is -bounded – and in particular, for any and any dataset – and has kernel stability with respect to the square loss. We can then apply Thm. 10 to the function
Appendix C PROOF of Thm. 6
In this section, we report the proof of Thm. 6. We do not make any claim of originality in this theorem which is merely a collection of results contained in ; we report the proof for completeness.
Similarly to the online case, the proof of Thm. 6 relies on the following decomposition.
We now describe how to deal with each term. We decompose the term as
and we bound the term by Prop. 3 and the term by Prop. 12 with confidence parameter . The term , thanks to the definition of , is negative. Lastly, as regards the term , we split it in
where we bound by Prop. 3, while, in order to bound the first term , we apply Hoeffding’s inequality (see 13 below) with parameters and for any (thanks to Prop. 1-(5)) and confidence parameter , i.e. for any , we have that
with probability at least in . Joining all the previous parts, the statement follows. ∎
Let be a positive integer and let be independent random variables such that with probability , for . Define . Then, for any , we have that
or equivalently, for any , we have that
Appendix D NON-ASYMPTOTIC RATES for PROJECTED STOCHASTIC SUBGRADIENT ALGORITHM
In this section, we briefly describe how to derive non-asymptotic convergence rates in probability for Projected Stochastic Subgradient Algorithm (PSSA), exploiting the regret bounds for Projected Online Subgradient Algorithm (POSA). In the first part we give a regret bound for POSA and we specialize it to Algorithm 1 for the case of the square loss (4). In the second part we first show, in general, how a bound on the regret implies a rate in probability for the convergence in the statistical setting and then we specialize this result to obtain the bound on the excess empirical future risk of the output of Algorithm 1 for the case of the square loss (Prop. 5). The results contained in this section are standard, we will cite during the presentation some references where the interested reader can find more details. Throughout this section, no differentiability assumptions on the functions will be made, we only require them to be convex and Lipschitz. We also require the boundedness of the diameter of the set over which we optimize. The general analysis will be conducted in a Hilbert space with scalar product and induced norm .
In the sequel, we will always assume the convexity of the functions and the existence of a minimizer of the batch problem . In our case, we will focus on the classical Projected Online Subgradient Algorithm described in Algorithm 2 and we will give an upper bound on its regret. When needed, the following assumptions will be made.
Assume that for any the functions are -Lipschitz on , i.e. there exists a positive constant such that for any and for any .
Assume that the diameter of the set is bounded by some constant , i.e. .
The following theorem is a classical result and a slightly different version can be found in [16, Thm. 3.1], we report here the proof because of clarity and completeness.
Under Asm. 1 and Asm. 2, the regret of Algorithm 2, with for some , is bounded by
Moreover, the optimal value for the previous bound, attained at , is .
Since , by convexity of and definition of subgradient, we have that:
Using the update rule of Algorithm 2, Pythagorean Theorem (i.e. the non-expansiveness property of the projection operator) and Asm. 1, the following relations hold:
Combining Eq. (64) with Eq. (62), we obtain:
Now, summing Eq. (65) from to , using the convention , and setting we can write:
where we have exploited Asm. 2, more precisely , the fact that and the inequality . Dividing by and optimizing with respect to , the result follows. ∎
We now specialize the regret bound obtained for the generic Algorithm 2 to our Algorithm 1 described in the paper for the square loss.
The thesis follows from applying Thm. 14 to the context of Algorithm 1 with the square loss. In this case the iteration coincide with , the cost functions are identified with , hence they are -Lipschitz thanks to Prop. 1-(3) and, consequently, we can take in Thm. 14. Moreover, the diameter of the set over which we project (in the previous notation ) is . Indeed, for any we have that , hence . ∎
D.2 Online-to-Batch Conversion
and we will assume the existence of a minimizer . In order to solve the stochastic problem in Eq. (67), we will analyze the general incremental procedure described in Algorithm 3, where the next point is updated by some rule depending on the past history of the process, for instance, if we choose the update , for some and , then Algorithm 3 coincides with POSA (Algorithm 2) applied to the functions .
In the online setting no further assumptions about the data are made, however, in the statistical setting we typically assume that the data are i.i.d. from the distribution ; since this last setting is more restrictive, one would expect that if Algorithm 3 solves the problem in the online framework, i.e. if its regret is such that as , then it will also solve the corresponding problem (67) in the statistical setting. This statement is formally confirmed by the following theorem, which relies on results taken from .
Let be convex functions with values in $Z_{t}t\in\{1,\dots,T\}\{Z_{t}\}_{t=1}^{T}\etaR_{T}\delta\in(0,1]$, we have that
with probability at least in the sampling of the points .
The previous theorem relies on the theory of Martingales and the analysis of the first term of the regret (), in fact this term is a data-dependent statistics evaluating the average cumulative error of the prediction of the algorithm on the next point , therefore it is reasonable to expect that it contains information about the generalization ability of the algorithm.
Adapting the previous discussion to the setting of Algorithm 1 for the square loss, we obtain the following rate for the excess empirical future risk of online estimator returned by the algorithm.
Appendix E PROJECTION ON THE SET 𝔇λ{{\mathfrak{D}}_{\lambda}}
In the following lemma we describe how to perform the projection over the set in a finite number of steps. Without loss of generality we consider the case that , the case regarding a general value of immediately follows by a rescaling argument.
Let be a symmetric matrix and let be an eigen-decomposition of , with . Then the solution of the problem
is given by if satisfies the constraints and otherwise, where , for , and the nonnegative parameter is uniquely defined by the equation .
The proof of the above lemma follows a standard path of reducing the matrix problem to a vector problem by application of von Neumann trace inequality, after which an argument based on Lagrange multipliers is employed, see e.g. [24, Theorem 15]. Note that the explicit equation defining the parameter can be solved efficiently in time, hence the computational cost of the projection is dominated by the computational cost of performing the eigen-decomposition of .