Yonathan Efroni

Gal Dalal

Bruno Scherrer

Shie Mannor

Beyond the one-step greedy approach in reinforcement learning

come   L'archive ouverte pluridisciplinaire

Introduction

Policy Iteration (PI) lies at the core of Reinforcement Learning (RL) and of many planning and on-line learning methods [START_REF] Konda | Actor-critic-type learning algorithms for markov decision processes[END_REF][START_REF] Kakade | Approximately Optimal Approximate Reinforcement Learning[END_REF]Schulman et al., 2015a;[START_REF] Mnih | Asynchronous methods for deep reinforcement learning[END_REF]Silver et al., 2017b). The classic PI algorithm repeats consecutive stages of i) 1-step greedy policy improvement with respect to (w.r.t.) a value function estimate, and ii) evaluation of the value function w.r.t. the greedy policy. Although multiple variants of the evaluation task have been considered [START_REF] Puterman | Modified policy iteration algorithms for discounted markov decision problems[END_REF][START_REF] Bertsekas | Temporal differences-based policy iteration and applications in neuro-dynamic programming[END_REF][START_REF] Sutton | Reinforcement learning: An introduction[END_REF], the usually considered policy update is the 1-step greedy improvement.

Conducting policy improvement using the common 1-step greedy approach is a specific choice, which is not necessarily the most appropriate one. Indeed, it was empirically recently suggested that greedy approaches w.r.t. multiple steps perform better than w.r.t. 1-step. Notable examples are Alpha-Go and Alpha-Go-Zero [START_REF] Silver | Mastering the game of go with deep neural networks and tree search[END_REF]2017b;a). There, an approximate online version of multiple-step greedy improvement is implemented via Monte Carlo Tree Search (MCTS) [START_REF] Browne | A survey of monte carlo tree search methods[END_REF]. The celebrated MCTS algorithm, which instantiates several steps of lookahead improvement, encompasses additional historical impressive accomplishments dating back to the past century and previous decade [START_REF] Tesauro | On-line policy improvement using monte-carlo search[END_REF][START_REF] Sheppard | World-championship-caliber scrabble[END_REF][START_REF] Bouzy | Monte-carlo go developments[END_REF][START_REF] Veness | Bootstrapping from game tree search[END_REF]. To the best of our knowledge, and despite such empirical successes, the use of a multiple-step greedy policy improvement has never been rigorously studied before. The motivation of this work is to fill this gap, and suggest new possible algorithms in this spirit.

The paper is organized as follows. We start by defining the h-greedy policy, a policy that is greedy w.r.t. a horizon of h steps. Using this definition, we introduce the h-PI algorithm, a class of PI algorithms with multiple-step greedy policy improvement and a guarenteed convergence to the optimal policy. We stress that the term "n-step return" often refered to in the literature, is used in the context of policy evaluation [START_REF] Sutton | Reinforcement learning: An introduction[END_REF][START_REF] Seijen | True online td (lambda)[END_REF]. Therefore, to avoid confusion, we choose to denote the multiple-step greedy policy by the letter h.

We then introduce a novel class of optimal Bellman operators, which is controlled by a continuous parameter κ ∈ [0, 1]. This operator is used to define a new greedy policy, the κ-greedy policy, leading to a new PI algorithm which we name κ-PI. This is analogous to the famous TD(λ) algorithm [START_REF] Sutton | Learning to predict by the methods of temporal differences[END_REF] for the improvement stage. In the TD(λ) algorithm, the λ parameter interpolates between the single-step evaluation update for λ = 0 and the infinitehorizon (Monte Carlo) evaluation update for λ = 1. Similarly, for κ = 0, we recover the traditional 1-step greedy policy for the improvement update and for κ = 1 we get the infinite-horizon greedy policy, i.e. the optimal policy. Roughly speaking, the κ-greedy policy can be viewed as allowing to make an 'interpolation' over all h-greedy policies. Similarly to the previous paragraph, we use the letter κ to avoid confusion with the parameter λ of TD(λ). Remarkably, we show that computing the κ-greedy policy is equivalent to solving the optimal policy of a surrogate κγ-discounted and stationary MDP.

As an additional generalization, we introduce the κλ-PI. This algorithm has a similar improvement step as the κ-PI, but its policy evaluation stage is 'relaxed', similarly to λ-PI [START_REF] Bertsekas | Temporal differences-based policy iteration and applications in neuro-dynamic programming[END_REF]. The κλ-PI further illustrates the difference between the λ and κ parameters. While the former controls the depth of the evaluation task in a way similar to previous works [START_REF] Sutton | Reinforcement learning: An introduction[END_REF][START_REF] Seijen | True online td (lambda)[END_REF], the latter controls the depth of the improvement step.

Next, we discuss the relation of this work to existing literature, and argue that it offers a generalized view for several recent impressive empirical advancements in RL, which are seemingly unrelated (Schulman et al., 2015b;Silver et al., 2017b). We thus show relevance of our proposed mathematical framework to current state-of-the-art algorithms. We conclude with an empirical display of the influence of these new parameters κ and h on a basic planning task. We empirically demonstrate that the best performance is obtained with non-trivial choices of them. This motivates future study of new RL algorithms which can be derived from the introduced framework in this work.

Preliminaries

Our framework is the infinite-horizon discounted Markov Decision Process (MDP). An MDP is defined as the 5-tuple (S, A, P, R, γ) [START_REF] Puterman | Markov decision processes: discrete stochastic dynamic programming[END_REF], where S is a finite state space, A is a finite action space, P ≡ P (s |s, a) is a transition kernel, R ≡ r(s, a) is a reward function, and γ ∈ (0, 1) is a discount factor. Let π : S → P(A) be a stationary policy, where P(A) is a probability distribution on A. Let v π ∈ R |S| be the value of a policy π, defined in state s

as v π (s) ≡ E π |s [ ∞ t=0 γ t r(s t , π(s t ))]
, where E π |s denotes expectation w.r.t. the distribution induced by π and conditioned on the event {s 0 = s}. For brevity, we respectively denote the reward and value at time t by r t ≡ r(s t , π t (s t ))

and v t ≡ v(s t ). It is known that v π = ∞ t=0 γ t (P π ) t r π = (I -γP π ) -1 r π , with the component-wise values [P π ] s,s P (s | s, π(s)) and [r π ] s r(s, π(s)).
Our goal is to find a policy π * yielding the optimal value v * such that

v * = max π (I -γP π ) -1 r π = (I -γP π * ) -1 r π * . (1)
This goal can be achieved using the three classical operators (with equalities holding component-wise):

∀v, π, T π v = r π + γP π v, (2) ∀v, T v = max π T π v, (3) ∀v, G(v) = {π : T π v = T v}, (4)
where T π is a linear operator, T is the optimal Bellman operator and both T π and T are γ-contraction mappings w.r.t. the max norm. It is known that the unique fixed points of T π and T are v π and v * , respectively. The set G(v) is the standard set of 1-step greedy policies w.r.t. v. Furthermore, given v * , the set G(v * ) coincides with that of stationary optimal policies. In other words, every policy that is 1-step greedy w.r.t. v * is optimal and vice versa.

The h-Greedy Policy and h-PI

In this section we introduce the h-greedy policy, a generalization of the 1-step greedy policy. This leads us to formulate a new PI algorithm which we name "h-PI". The h-PI is derived by replacing the improvement stage of the PI, i.e, the 1-step greedy policy, with the h-greedy policy.

We further prove its convergence and show it inherits most properties of PI.

Let h ∈ N\{0}. A h-greedy policy w.r.t. a value function v belongs to the following set of policies,

arg max π0 max π1,..,π h-1 E π0...π h-1 |• h-1 t=0 γ t r(s t ,π t (s t ))+γ h v(s h ) = arg max π0 E π0 |• r(s 0 , π 0 (s 0 ))+γ T h-1 v (s 1 ) (5)
where the notation

E π0...π h-1 |•
means that we condition on the trajectory induced by the choice of actions (π 0 (s 0 ), π 1 (s 1 ), . . . , π h-1 (s h-1 )) and the starting state s 0 = • . Since the argument in (5) is a vector, the maximization is component-wise, i.e., we wish to find the choice of actions that will jointly maximize the entries of the vector. Thus, the h-greedy policy chooses the first optimal action of a non-stationary, optimal control problem with horizon h. As the equality in (5) suggests, this policy can be equivalently interpreted as the 1-step greedy policy w.r.t. T h-1 v. Although the former view is more natural, it is, in fact, the latter on which this section's proofs are based. Thus, the set of h-greedy policies w.r.t. v, G h (v), can be expressed as follows:

∀v, π, T π h v def = T π T h-1 v, (6) ∀v, G h (v) = {π : T π h v = T h v}. ( 7
)
Remark 1. This is a generalization of the standard 1-step greedy operation, which one recovers by taking h = 1. Each call to the greedy operator G h amounts to identifying for all states, the best first action of an h-horizon optimal control problem. More interestingly, one may compute these first optimal actions with specifically designed procedures such as A * -like/optimistic tree exploration algorithm [START_REF] Hren | Optimistic planning of deterministic systems[END_REF][START_REF] Busoniu | Optimistic Planning for Markov Decision Processes[END_REF][START_REF] Munos | From Bandits to Monte-Carlo Tree Search: The Optimistic Principle Applied to Optimization and Planning[END_REF][START_REF] Szörényi | Optimistic planning in Markov decision processes using a generative model[END_REF][START_REF] Grill | Blazing the trails before beating the path: Sample-efficient Monte-Carlo planning[END_REF].

With this set of operators, we consider Algorithm 1, the h-PI algorithm, where the assignments hold point-wise. This algorithm alternates between i) identifying the h-greedy policy, i.e, solving the h-horizon optimal control problem, and ii) estimating the value of this policy.

Algorithm 1 h-PI

Initialize: h ∈ N\{0}, v ∈ R |S| while the value v changes do π ← arg max π0 max π1,..,π h-1 E π0...π h-1 |• h-1 t=0 γ t r t + γ h v h v ← E π |• [ ∞ t=0 γ t r t ] end while Return π, v
As we are about to see, this new algorithm inherits most properties of standard PI. We start by showing a monotonicity property for the h-greedy operator.

Lemma 1 (Policy improvement of the h-greedy policy). Let π ∈ G h (v π ). Then v π ≥ v π component-wise, with equality holding if and only if π is an optimal policy. Proof. First observe that

v π = T π v π ≤ T v π . (8)
Then, sequentially using (8), ( 7) and (6), we have

v π = (T π ) h v π ≤ T h v π = T π h v π = T π (T h-1 v π ). (9)
This leads to the following inequalities:

v π ≤ T π (T h-1 v π ) (10) ≤ T π (T h-1 T v π ) = T π (T h v π ) (11) = T π T π T h-1 v π = T π 2 (T h-1 v π ) (12) ≤ • • • ≤ lim n→∞ T π n (T h-1 v π ) = v π . ( 13
)
In the above derivation, (10) is due to (9), ( 11) is due to (8) and the monotonicity of T π and T (and thus of their composition), ( 12) is due to (9), and ( 13) is due to the fixed point property of T π . Lastly, notice that v π = v π if and only if (cf. (8)) T v π = v π , which holds if and only if π is the optimal policy.

Thus, the improvement property of the 1-step greedy policy also holds for the h-greedy policy. As a consequence, the h-PI algorithm produces a sequence of policies with component-wise increasing values, which directly implies convergence (since the sequence is bounded). We can be more precise about the convergence speed by generalizing several known results on PI to h-PI. Let us begin by the following lemma, which is essentially a consequence of the fact that T h is a γ h -contraction (see Appendix C in the supplementary material for a proof).

Lemma 2. The sequence

{ v * -v π k ∞ } k≥0 is contract- ing with coefficient γ h .
Thus, the convergence rate is at most γ h , which generalizes the known γ convergence rate of the original (h = 1) PI algorithm [START_REF] Puterman | Markov decision processes: discrete stochastic dynamic programming[END_REF]. The next theorem describes a result with respect to the termination of the algorithm.

Theorem 3. The h-PI algorithm converges in at most

|S|(|A| -1) (h log 1 γ ) -1 log 1 1-γ iterations.
Proof. The proof follows the steps of [START_REF] Scherrer | Improved and Generalized Upper Bounds on the Complexity of Policy Iteration[END_REF], Section 7, where instead of using the contraction coefficient of PI algorithm we use the contraction coefficient of h-PI, proved in Lemma 2.

Remark 2. Note that the fact that T h is γ h -contraction does not imply that all existing PI results extend to h-PI with γ h replacing γ. For instance, the rightmost term in the logarithm of Theorem 3 is 1 1-γ and not 1 1-γ h . Remark 3. Notice how the complexity term in Theorem 3 is a decreasing function of h. At the limit h → ∞, running a single iteration of h-PI is sufficient for finding the optimal value-policy pair. However, although the total number of iterations is reduced with h increasing, each iteration is expected to be computationally more costly.

The κ-Greedy Policy

In this section, we introduce an additional, novel generalization of the 1-step greedy policy: the κ-greedy policy. Similarly to the previous section, the newly introduced greedy policy leads to a new PI algorithm, which we shall name "κ-PI". This generalization will be based on the definition of a new κ-optimal Bellman operator. This operator will also naturally lead to a new Value Iteration (VI) algorithm, "κ-VI". In the later Section 6, we shall highlight the relation between the κ-greedy and the previously introduced h-greedy policy.

κ-Optimal Bellman Operator and the κ-Greedy Policy

In this section we will derive the κ-optimal Bellman operator and define its induced greedy policy, the κ-greedy policy.

Given a parameter κ ∈ [0, 1], consider the following operator:

∀v, π, T π κ v def = (1 -κ) ∞ j=0 κ j (T π ) j+1 v. ( 14
)
This linear operator is identical to the one of the λ-PI algorithm [START_REF] Bertsekas | Temporal differences-based policy iteration and applications in neuro-dynamic programming[END_REF]. By simple linear algebra arguments (see e.g. (Scherrer, 2013a)), one can see that

∀v, π, T π κ v = (I -κγP π ) -1 (r π + (1 -κ)γP π v) (15) = v + (I -κγP π ) -1 (T π v -v). (16)
Comparing ( 1) and ( 15), we can interpret (15), given a fixed v, as the value of policy π in a surrogate stationary MDP. This MDP has the same dynamics as the MDP we wish to solve, a κγ ≤ γ discount factor and a reward function rπ,v given by

rπ,v def = r π + (1 -κ)γP π v. (17)
Thus, this surrogate stationary MDP depends on both v and κ. According to basic MDP theory, the surrogate MDP has an optimal value. We shall denote its optimal value by T κ v and refer to T κ as the "κ-optimal Bellman operator". Note that, from ( 1) and ( 15), we have

T κ v = max π (I -κγP π ) -1 rπ,v = max π T π κ v. ( 18
)
The κ-optimal Bellman operator naturally induces a new set of greedy policies, the set of κ-greedy policies w.r.t. v, which we shall denote by G κ (v), and define as follows:

∀v, G κ (v) = {π : T π κ v = T κ v}. (19)
Remark 4. The κ-optimal Bellman operator is a generalization of the optimal Bellman operator, which one recovers by taking κ = 0; i.e., T κ=0 = T . Additionally, applying once T κ=1 is equivalent to solving the original γ-discounted MDP; i.e, for any v, v * = T κ=1 v. For all other values 0 < κ < 1, applying T κ amounts to solving a stationary MDP with reduced discount factor, the solution of which can be obtained using any generic planning, model-free or model-based RL algorithm. As was previously analyzed in [START_REF] Petrik | Biasing approximate dynamic programming with a lower discount factor[END_REF][START_REF] Strehl | Reinforcement learning in finite mdps: Pac analysis[END_REF][START_REF] Jiang | The dependence of effective planning horizon on model accuracy[END_REF] and reported [START_REF] François-Lavet | How to discount deep reinforcement learning: Towards new dynamic strategies[END_REF], solving a MDP with a smaller discount factor is in general easier.

In the next lemma we prove that both T π κ and T κ are contractions with respective fixed points v π and v * . Lemma 4. For any π, T π κ and T κ are ξ-contraction mappings w.r.t. the max norm, where ξ = (1-κ)γ 1-γκ ∈ [0, γ], and have unique fixed points v π and v * , respectively. Moreover,

G κ (v * ) = G(v * ).
Proof. From (15), we see that for all v and w,

T π κ v -T π κ w = (1 -κ)(I -κγP π ) -1 γP π (v -w), (20)
which implies, by taking the max norm, that T π κ is a ξcontraction mapping.

From (18), we see that for all v and w,

T π * w κ v -T π * w κ w ≤ T κ v -T κ w ≤ T π * v κ v -T π * v κ w, (21)
and this in turn implies, by again taking the max norm, that T κ is also a ξ-contraction mapping.

Since both operators are contraction mappings, they have one and only one fixed point. To identify them, it is thus sufficient to show that the foreseen fixed points are indeed fixed points. By ( 16), since v π = T π v π , it is clear that v π = T π κ v π . Now, from ( 18) and ( 16),

T κ v * = max π T π κ v * = v * + z, (22)
with z = max

π (I -κγP π ) -1 (T π v * -v * ).
By the optimality of v * , we know that for any π, T π v *v * ≤ 0 ; since the matrix (I -κγP π ) -1 = ∞ i=0 (κγP π ) i is only made of non-negative coefficients, it follows that z ≤ 0. Then, since for π = π * , T π v * = v * , we deduce that z = 0 and, as a consequence,

T κ v * = v * . Lastly, we show that G κ (v * ) = G(v * ). Let π ∈ G κ (v * ). Thus, T π κ v * = T κ v * = v *
, where the second equality holds since v * is the fixed point of T κ . From ( 22) we deduce that

0 = z = T π v * -v * . Thus, T π v * = v * = T v * and π is in G(v * ). To show the opposite direction, we assume that π is in G(v * ). Thus, it holds that z = T π v * -v * = 0; hence, T π κ v * = v * , and indeed π is in G κ (v * ).

Two New Algorithms: κ-PI and κ-VI

In the previous subsection, we derived the κ-optimal Bellman operator, and defined its induced κ-greedy policy. These operators lead us to consider Algorithm 2, the κ-PI algorithm, where the assignments hold component-wise.

Algorithm 2 κ-PI

Initialize: κ ∈ [0, 1], v ∈ R |S| while the value v changes do π ← arg max π E π |• [ ∞ t=0 (κγ) t (r t + γ(1 -κ)v t+1 )] v ← E π |• [ ∞ t=0 γ t r t ] end while Return π, v
This algorithm repeats consecutive steps of i) identifying the κ-greedy policy, i.e, solving the optimal policy of a surrogate, stationary MDP, with a reduced γκ discount factor, and ii) estimating the value of this policy. As we shall see, the iterative process is guaranteed to converge to the optimal policy-value pair of the MDP we wish to solve.

Similarly to Section 3, we shall now prove that the κ-PI algorithm inherits many properties from PI. We start by showing a monotonicity property for the κ-greedy operator.

Lemma 5 (Policy improvement of the κ-greedy policy). Let π ∈ G κ (v π ). Then v π ≥ v π component-wise, with equality if and only if π is an optimal policy. Proof. Since v π is also the fixed point of T π κ , by Lemma 4, and using the definition of T κ (see 18),

v π = T π κ v π ≤ T κ v π = T π κ v π (23) by choosing π ∈ G κ (v π ).
Using the monotonicity of the operator T π κ and repeating (23) we get,

v π = T π κ v π ≤ T π κ v π ≤ • • • ≤ lim n→∞ T π κ n v π = v π .
The final equality holds since T π κ is a contraction mapping, and v π is its fixed point, due to Lemma 4. According to the same lemma, equality holds if and only if

v π = v * .
Similarly to Lemma 2, let us state a result that is a direct consequence of the fact that T κ , that induces the κ-greedy policy, is a ξ contraction (see Appendix D in the supplementary material for a proof).

Lemma 6. The sequence ( v * -v π k ∞ ) k≥0 is contracting with coefficient ξ.
In the following theorem to the lemma we upper bound the maximal number of iteration it takes the κ-PI algorithm to terminate (the proof is the same as that for Theorem 3).

Theorem 7. The κ-PI algorithm converges in at most |S|(|A| -1) (log 1-κγ (1-κ)γ ) -1 log 1 1-γ iterations.

Remark 5. As in the case of h-PI, the complexity term in Theorem 7 is a decreasing function of κ. This complements the fact that κ-PI converges in one iteration if κ = 1. Again, as κ increases, each iteration is expected to be computationally more demanding since the surrogate MDP is less discounted.

Lastly, using the κ-optimal Bellman operators, T κ , we derive a non-trivial generalization of the VI algorithm which we name "κ-VI". The κ-VI algorithm repeatedly applies T κ until convergence. The convergence proof of κ-VI and its rate of convergence, ξ, thus follows easily as a corollary of Lemma 4. In the next section, we shall group both κ-PI κ-VI into a single, larger, class of algorithms that contains them both.

κλ-PI

Even though κ-PI and κ-VI are distinct algorithms, in this section we unite them under the single "κλ-PI" class of algorithms (Algorithm 3). This generalization is similar to the λ-PI which interpolates between standard PI and VI [START_REF] Bertsekas | Temporal differences-based policy iteration and applications in neuro-dynamic programming[END_REF][START_REF] Bertsekas | Neuro-dynamic programming: an overview[END_REF]Scherrer, 2013b;[START_REF] Bertsekas | Lambda-policy iteration: A review and a new implementation[END_REF]. We shall describe how to estimate the value of the κ-greedy policy on a surrogate MDP with a smaller horizon and shaped reward, and show that this still yields convergence to the optimal policy and value. Thus, in κλ-PI, we ease the policy evaluation phase of κ-PI via solving a simpler task.

In the λ-PI, the improvement stage is the common 1-step greedy policy, and the evaluation stage is relaxed by applying the T π λ operator ( 14) instead of fully estimating the value, where λ ∈ [0, 1]. We start by formulating the appropriate generalization of the T π λ operator to κ-PI. Let λ ∈ [0, 1] . The analogous T π λ to our framework is the following linear operator:

∀v, π, T π λ,κ v = (1 -λ) ∞ j=0 λj T π κ v.
Interestingly, due to the fact this operator is affine, the following lemma shows that T π λ,κ is equivalent to yet another T π λ operator ( 14) where λ is a function of λ and κ (see Appendix E in the supplementary material for a proof). Lemma 8. For every λ, κ ∈

[0, 1], T π λ,κ = T π λ , where λ = κ + λ(1 -κ), i.e, λ ∈ [κ, 1]. Algorithm 3 κλ-PI Initialize: κ ∈ [0, 1], λ ∈ [κ, 1], v ∈ R |S| while some stopping condition is not satisfied do π ← arg max π E π |• [ ∞ t=0 (κγ) t (r t + γ(1 -κ)v t+1 )] v ← E π |• [ ∞ t=0 (λγ) t (r t + γ(1 -λ)v t+1 )] end while Return π, v
Consider κλ-PI (Algorithm 3, in which again the assignments hold component-wise). Its improvement stage is similar to the κ-PI algorithm; however, in the evaluation step, we apply T π λ,κ , or, equivalently, T π λ . Indeed, by setting λ = κ we recover κ-VI (see Appendix F) and by setting λ = 1 we recover κ-PI. Moreover, by setting κ = 0, we obtain the class of λ-PI algorithms. Notice that λ ∈ [κ, 1], whereas for λ-PI, λ ∈ [0, 1]. We leave for future work the question whether the κλ-PI makes sense for λ ∈ [0, κ).

At this point of the paper, we have reached a very general algorithmic formulation. We shall not only prove convergence for the κλ-PI, but also provide a sensitivity analysis that shows how errors may propagate along the steps. This may indeed be of interest if we use approximations when computing a κ-greedy policy or updating the value function. Also, doing so, we generalize similar results on λ-PI (Scherrer, 2013a). In the following the subscript notation, k, refers to the kth iteration of the algorithm (the proof is deferred to the end of the paper for clarity, in Appendix A).

Theorem 9. Let κ ∈ [0, 1] and λ ∈ [κ, 1]. Assume that in Algorithm 3 we employ noisy versions of the two steps at the kth iteration

π k+1 ← Ĝδ k+1 κ (v k ) (24) v k+1 ← T π k+1 λ v k + k+1 ,
where the noisy improvement of (24) means:

T π k+1 κ v k ≥ T κ v k -δ k+1 .
Assume that for all k, k ∞ ≤ and δ k ∞ ≤ δ. Then,

lim sup k→∞ v * -v π k ≤ 2ξ + δ (1 -ξ) 2 = 2γ(1 -κ)(1 -κγ) +(1 -κγ) 2 δ (1 -γ) 2 .
Once again, we can measure how increasing κ allows improving these asymptotic bounds. Furthermore, observe that the bounds do not depend on λ.

By setting = δ = 0 we get the following corollary.

Corollary 10. The κλ-PI algorithms converges to the optimal value-policy pair.

Relation to Existing Works

In this section we compare the κ-greedy policy (Section 4) to the h-greedy policy (Section 3). Furthermore, we connect previous works of the literature to the framework developed in this paper.

Let v : S → R be a value function, h ∈ N\{0} and define the following random variable, the future h-step return:

r (h) v def = h-1 t=0 γ t r t + γ h v(s h ).
Consider the h-greedy policy w.r.t. to v, defined in (5). We have for all π ∈ G h (v) and s ∈ S,

π(s) = arg max π0 max π1,..,π h-1 E π0...π h-1 |s r (h) v .
Alternatively, consider a different generalization of the greedy step in the form of a greedy policy w.r.t. a κ-weighted average of the future rewards {r

(h) v } h≥1 : G κ-weighted (v) def = arg max π E π |• [(1 -κ) ∞ h=0 κ h r (h+1) v ].
We can highlight the following strong relation between these two greedy sets (see Appendix G in the supplementary material for a proof).

Proposition 11. Let δ v (s t ) = r(s t , π(s t )) + γv(s t+1 )v(s t ). We have

G κ-weighted (v) = G κ (v) = arg max π E π |• ∞ t=0 (κγ) t δ v (s t ) .
The second equality in Proposition 11 reveals a connection to two existing works: planning with shorter horizons [START_REF] Ng | Shaping and policy search in reinforcement learning[END_REF] and generalized advantage estimation (Schulman et al., 2015b). Using the terminology of our work, the approach of [START_REF] Ng | Shaping and policy search in reinforcement learning[END_REF] is equivalent to performing a single κ-greedy improvement step. The theory we developped in this paper suggests that there is no reason to stop after only one step. In (Schulman et al., 2015b), the implemented algorithm is equivalent to an on-line Policy Gradient variant of the κ-PI algorithm. As Proposition 11 in our work states, the objective function considered in (Schulman et al., 2015b) describes the very same surrogate MDP that is being solved in the improvement step of κ-PI. Moreover, in that work, an evaluation algorithm estimates the value of the current policy similarly to the evaluation stage of κ-PI. We can interpret the empirically demonstrated trade-off in λ of (Schulman et al., 2015b) as a trade-off in κ. Finally, the policy update phase in the MCTS approach in RL, and in Alpha-Go [START_REF] Silver | Mastering the game of go with deep neural networks and tree search[END_REF]2017b;a) as an instance of it, is conceptually similar to the policy update in an asynchronous online version of h-PI.

Experimental Results

In this section we empirically test the hand κ-PI algorithms on a toy grid-world problem. As mentioned before, in h-PI, performing the greedy step amounts to solving a h-horizon optimal control problem (Remark 1), and in κ-PI, it amounts to solving a γκ-discounted stationary MDP (Remark 4). In both cases, conducting these operations in practice can be done with either a generic planning, model-free or modelbased algorithm. Here, we implement the hand κ-greedy step via the VI algorithm. In the former case, we simply do h steps, while in the latter case, we stop VI when the value change in max norm is less than = 10 -5 (other values did produce the same qualitative behavior). With this choice, note that κ = 1 is equivalent to solving the problem with VI.

We conduct our simulations on a simple N × N deterministic grid-world problem with γ = 0.97. The actions set is {'up','down','right','left','stay'}. In each experiment, we randomly chose a single state and placed a reward r g = 1.

In all other states the reward was drawn uniformly from [-0.1r g , 0.1r g ]. In the considered problem there is no terminal state. Also, the entries of the initial value function are drawn from N (0, r 2 g ). We ran hand κ-PI and counted the total number of calls to the simulator. Each such "call" takes a state-action pair (s, a) as input, and returns the current reward and next (deterministic) state. In all plots, the y-axis is the total queries to simulator until convergence, which we chose as a performance criterion. (Left) Performance of h-PI as a function of h. (Center) Performance of κ-PI as a function of h eff (κ) = (1 -γκ) -1 , the 'effective' planning horizon. The κ values that resulted in the lowest number of simulator queries are κopt = 0.82, 0.82, 0.88, 0.92 for N = 25, 30, 35, 40, respectively. (Right) Performance of λ-PI as a function of λ. This corresponds to κλ-PI with κ = 0. The three plots demonstrate that the algorithms introduced in this work, h-PI and κ-PI, can outperform λ-PI in terms of best empirical performance.

Figure 1 shows the average number of calls to the simulator as a function of h or κ. For each value, experiments were conducted 5 times. The figure depicts that optimal computational efficiency is obtained for some value of the parameters that is not trivial (h ∈ {1, ∞} and κ ∈ {0, 1}). Empirically, these 'optimal' parameter values slowly grow with the grid dimension N . For a comparison, we measured the empirical performance of λ-PI (notice that λ = 1, which is PI, corresponds to κ-PI with κ = 0). Our simulations show that the performance of λ-PI is inferior to that of our new algorithms.

Discussion and Future Work

In this work, we introduced and formulated two possible approaches that generalize the traditional 1-step greedy operator. Borrowing from the general principle behind Dynamic Programming, we proposed a new family of techniques for solving a single complex problem via iteratively solving smaller sub-problems. We showed that the discussed approaches are coherent with previous lines of work, by generalizing existing analyses on the 1-step greedy policy to the hand κ-greedy policies. In particular, we derived new algorithms and showed their convergence. By introducing and analyzing the κλ-PI, we demonstrated that the κ-PI can be used with a 'relaxed' value estimation and that the effects of noise are controlled. Last but not least, by making connections with some recent empirical works (Schulman et al., 2015b;Silver et al., 2017b), our work sheds some light on the reasons of their impressive success. We conducted simulations on a toy example and have shown how a generic RL algorithm (VI) can be used for the greedy step of the κand h-PI frameworks. We empirically demonstrated that such a new algorithm leads to a performance improvement. By using other techniques for solving the greedy step (see in particular Remarks 1 and 4), many new algorithms may be built.

It may be interesting to consider online versions (i.e. stochastic approximations) of the algorithmic schemes we have introduced here, which would probably require to consider at least two time scales (one for the inner surrogate problems, one for the main loop). On the theoretical side, our first attempts in this direction suggest that previous approaches for proving online convergence of PI [START_REF] Konda | Actor-critic-type learning algorithms for markov decision processes[END_REF][START_REF] Kakade | Approximately Optimal Approximate Reinforcement Learning[END_REF] may not be so straightforwardly generalized. We are currently working on this extension.

A potential practical extension of this work would be to consider a state-dependent κ value, that is a function κ : S → [0, 1]. Though the details of such a generalization need to be written carefully, we believe that the machinery we developped here will still hold. We expect the convergence to be assured with rates that would intricately depend on this κ function. Using such an approach, the algorithm designer could put more 'prior knowledge' into the learning phase. In general though, understanding better when the choice of a κ function would be good or not (and even understanding how to choose the κ or h parameters of the algorithms described here) is intriguing and deserves future investigation.

A. Proof of Theorem 9

We might follow the steps in [START_REF] Scherrer | Performance bound for Approximate Optimistic Policy Iteration[END_REF][START_REF] Scherrer | Approximate Modified Policy Iteration and its Application to the Game of Tetris[END_REF]. But we give here an alternative and shorter proof, which is new even in the specific context of κ = 0.

Using (15), for any π, we have

T π κ v 1 -T π κ v 2 = γ(1 -κ)(I -κγP π ) -1 (v 1 -v 2 ) = ξD π κ P π (v 1 -v 2 ) def = ξ P π (v 1 -v 2 ),
where we defined D π κ = (1-κγ)(I-κγP π ) -1 , a stochastic matrix, and P π κ = D π κ P π , also a stochastic matrix. Define the following alternative error k = k -C k e, where C k = max δ k+1 +max k -ξ min k 1-ξ and e is the constant vector made of ones. Since for all α, T π κ (v + αe) = T π κ v + ξαe and Ĝδ κ (v) = Ĝδ κ (v + αe), the sequence of policies that can be generated by the original algorithm, with error k , is the same as that that would be generated by the algorithm with erros k . From now on, let us consider the latter.

With a similar invariance argument, let us assume, without loss of generality, that v 0 -T π1 κ v 0 ≤ 0. Then, one can see that for all k ≥ 1,

b k def = v k -T π k+1 κ v k ≤ v k -T π k κ v k + δ k+1 = (v k -k ) -T π k κ (v k -k ) + (1 -ξ) k + δ k+1 ≤ T π k λ v k-1 -T π k κ T π k λ v k-1 + (max δ k+1 + max k -ξ min k )e = T π k λ v k-1 -T π k λ T π k κ v k-1 + (max δ k+1 + max k -C k -ξ(min k -C k ) 0 )e = ξ λ P π k λ (v k-1 -T π k κ v k-1 ) = ξ λ P π k λ b k-1 .
In the fifth relation we used Proposition 13 (see Appendix B) that shows T κ T λ = T λ T κ , and defined ξ λ def = γ 1-λ 1-λγ . Thus, since P π k λ has only non-negative elements, by induction, we have b k ≤ 0 for all k.

Then, since (1 -λ) ∞ j=0 λj = 1, one can see that

d k+1 def = v * -(v k+1 -k+1 ) = v * -(1 -λ) ∞ j=0 λj (T π k+1 κ ) j+1 v k = (1 -λ) ∞ j=0 λj (v * -(T π k+1 κ ) j+1 v k ).
Each term in the sum satisfies:

v * -(T π k+1 κ ) j+1 v k = T π * κ v * -T π * κ v k + T π * κ v k -T π k+1 κ v k + j i=1 (T π k+1 κ ) i v k -(T π k+1 κ ) i+1 v k ≤ ξ P π * κ (v * -v k ) + δ k+1 + j i=1 (ξ P π k+1 κ ) i b k ≤ ξ P π * κ (v * -v k ) + δ k+1 ,
and hence we deduce that

d k+1 ≤ ξ P π * κ (v * -v k ) + δ k+1 = ξ P π * κ d k -ξ P π * κ k + δ k+1
and thus

max d k+1 ≤ ξ max d k + max δ k+1 -ξ min k = ξ max d k + max δ k+1 -ξ min k - max δ k+1 + max k -ξ min k 1 -ξ = ξ max d k + max δ k+1 + ξ(max k -min k ) 1 -ξ ,
which eventually leads to

lim k→∞ d k ≤ ξ(max k -min k ) + max δ k+1 (1 -ξ) 2 .
To conclude, we finally observe that

s k def = v k+1 -k+1 -v π k+1 = (1 -λ) ∞ j=0 λj (T π k+1 κ ) j+1 v k -v π k+1 = (1 -λ) ∞ j=0 λj ((T π k+1 κ ) j+1 v k -v π k+1 ),
and each term of the sum satisfies:

(T π k+1 κ ) j+1 v k -v π k+1 = i≥j+1 (T π k+1 κ ) i v k -(T π k+1 κ ) i+1 v k = i≥j+1 (ξ P π k+1 κ ) i b k ≤ 0.
In other words, we deduce that s k is non-positive. The result follows from the fact that v

* -v π k = d k + s k and that max k -min k ≤ 2 k .

B. Affinity of the Fixed Policy Bellman Operator and Consequences

In this section we show that due to the affinity of the fixed-policy Bellman operator, T π , it also preserves barycenters. We discuss the consequences of this observation and specifically prove that T λ commutes with any other T λ operator.

Lemma 12. Let {v i , λ i } ∞ i=0 be a series of value functions, v i ∈ R |S| , and positive real numbers, λ i ∈ R + , such that ∞ i=0 λ i = 1. Let T π be a fixed policy Bellman operator and n ∈ N. Then,

T π ( ∞ i=0 λ i v i ) = ∞ i=0 λ i T π v i , (T π ) n ( ∞ i=0 λ i v i ) = ∞ i=0 λ i (T π ) n v i .
Proof. Using simple algebra and the definition of T π (see Definition 2) we have that

T π ( ∞ i=0 λ i v i ) = r π + γP π ( ∞ i=0 λ i v i ) = r π + ∞ i=0 λ i γP π v i = ∞ i=0 λ i (r π + γP π v i ) = ∞ i=0 λ i T π v i .
The second claim is a result of the first claim and is proved by iteratively applying the first relation.

This lemma induces the following property.

Proposition 13. Let T π λ be the fixed-policy λ Bellman operator, λ 1 , λ 2 ∈ [0, 1] and v ∈ R |S| be a value function. Then,

T π λ1 T π λ2 v = T π λ2 T π λ1 v,
i.e, T π λ1 , T π λ2 commute.

Proof. We have that

T π λ1 T π λ2 v = (1 -λ 1 ) ∞ i=0 λ i 1 (T π ) i+1 T π λ2 v = (1 -λ 1 ) ∞ i=0 λ i 1 (T π ) i+1   (1 -λ 2 ) ∞ j=0 λ j 2 (T π ) j+1 v   = (1 -λ 1 )(1 -λ 2 ) ∞ i,j=0 λ i 1 λ j 2 (T π ) i+1 (T π ) j+1 v = (1 -λ 2 )(1 -λ 1 ) ∞ i,j=0 λ j 2 λ i 1 (T π ) j+1 (T π ) i+1 v = (1 -λ 2 ) ∞ j=0 λ j 2 (T π ) j+1 (1 -λ 1 ) ∞ i=0 λ i 1 (T π ) i+1 v = T π λ2 T π λ1 v.
The first and third relations use Definition 14, the forth and sixth relations are due to Lemma 12, and the fifth relation is due to the fact that every operator commutes with itself.

C. Proof of Lemma 2

The proof goes as follows.

v * -v π k = T π * T h-1 v * -T π * T h-1 v π k-1 + T π * T h-1 v π k-1 -T π k T h-1 v π k-1 + T π k T h-1 v π k-1 -T π k v π k ≤ T π * T h-1 v * -T π * T h-1 v π k-1 + T π k T h-1 v π k-1 -T π k v π k ≤ γP π * (T h-1 v * -T h-1 v π k-1 ) + γP π k (T h-1 v π k-1 -v π k ) ≤ γP π * (T h-1 v * -T h-1 v π k-1 ).
The second relation uses that

T π * T h-1 v π k-1 ≤ T π k T h-1 v π k-1 since π k ∈ G h (v π k-1
). The third relation holds by definition, and the fourth because T h-1 v π k-1 ≤ v π k , as as seen from Lemma 1. Since v * -v π k is non-negative we can take the max norm. By using the fact that T is a γ contraction in the max norm, T h-1 is a γ h-1 contraction in the max norm. Thus, by taking the max norm of both sides we prove the claim.

D. Proof of Lemma 6

Using the fixed point property of the operator in Lemma 4,

v * -v π k = T π * κ v * -T π * κ v π k-1 + T π * κ v π k-1 -T π k κ v π k-1 + T π k κ v π k-1 -v π k ≤ T π * κ v * -T π * κ v π k-1 + T π k κ v π k-1 -v π k ≤ T π * κ v * -T π * κ v π k-1 .
The second relation holds since

T π * κ v π k-1 ≤ T π k κ v π k-1 = T κ v π k-1
, as follows from the definition of T κ (see ( 18)). The third relation uses that T π k κ v π k-1 ≤ v π k , as follows from the proof of Lemma 5. Since v * -v π k is positive, we take the max norm and use the fact that T π * κ is ξ contraction in the max norm to conclude the proof.

E. Proof of Lemma 8

Since for the operator T π the distributive property holds, i.e, aT π + b(T π ) 2 = (a + bT π )T π , we have the following relation for any λ ∈ [0, 1].

(1

-λT π )T π λ =(1 -λT π )(1 -λ) ∞ i=0 λ i (T π ) i+1 =(1 -λ) ∞ i=0 λ i (T π ) i+1 -(1 -λ)λT π ∞ i=0 λ i (T π ) i+1 =(1 -λ) ∞ i=0 λ i (T π ) i+1 -(1 -λ) ∞ i=1 λ i (T π ) i+1 =(1 -λ)T π .
The first relation uses that the infinite sum converges and the definition of the T π λ operator (cf. ( 14)), in the third relation we used Lemma 12, and in the forth relation all terms cancel out except for the first term (with i = 0) in the first series.

We thus get a new relation the T π λ operator satisfies,

(1 -λT π )T π λ = (1 -λ)T π . ( 25
)
Let λ ∈ [0, 1], κ ∈ [0, 1] and λ = κ + λ(1 -κ). We now expand (1 -λT π )T π λ,κ .

(1 -λT π )T π λ,κ = (1 -λT π )(1 -λ)

∞ j=0 λj (T π κ ) j+1 = ((1 -κT π ) -λ(1 -κ)T π )(1 -λ) ∞ j=0 λj (T π κ ) j+1 = (1 -κT π )   (1 -λ) ∞ j=0 λj (T π κ ) j+1   -λ(1 -κ)T π   (1 -λ) ∞ j=0 λj (T π κ ) j+1   = (1 -λ) ∞ j=0 λj (1 -κT π )(T π κ ) j+1 -λ(1 -κ)T π   (1 -λ) ∞ j=0 λj (T π κ ) j+1   = ∞ j=0 λj (1 -λ)(1 -κ)T π (T π κ ) j -λ(1 -κ)T π   (1 -λ) ∞ j=0 λj (T π κ ) j+1   = (1 -κ)T π   (1 -λ) ∞ j=0 λj (T π κ ) j -(1 -λ) ∞ j=0 λj+1 (T π κ ) j+1   =(1-λ) = (1 -λ)(1 -κ)T π = (1 -λ)T π .
In the forth relation we used Lemma 12, in the fifth relation we used (25) , with κ instead of λ, and in the sixth relation we again used Lemma 12. We thus get that the operators T π λ,κ and T π λ satisfy the following relations.

(1 -λT π )T π λ,κ = (1 -λ)T π , (1 -λT π )T π λ = (1 -λ)T π .

Subtracting the two equations and using T π = r π (•) + γP π we get1 ,

[1 -λ(r π + γP π )] (T π λ,κ -T π λ ) = (1 -λγP π )(T π λ,κ -T π λ ) = 0.

Since (1 -λγP π ) is non-zero (i.e, exists v ∈ R |S| s.t (1 -λP π )v = 0), we get that

T π λ,κ = T π λ ,
which concludes the proof.

F. Equivalence of κ-VI and κλ-PI with λ = κ

The equivalence of κλ-PI when λ = κ to κ-VI is similar to the equivalence of λ-PI to VI for λ = 0 (Scherrer, 2013a). To see this, start by considering the κ-VI algorithm (see Section 5). Let v k be the value of the algorithm at the k-th iteration.

Then, the value at the next iteration, v k+1 , is

v k+1 = T κ v k = max π T π κ v k . ( 26
)
Now consider the update performed by the κλ-PI algorithm with λ = κ (see Algorithm 3). By construction, it will apply the following update.

π k+1 = arg max π T π κ v k (27) v k+1 = T π k+1 κ v k . (28)

Figure 1 :

 1 Figure 1: Empirical performance of h-PI, κ-PI and λ-PI for different grid sizes, N (see Section 7). The shown results are the average of 5 experiments. The standard deviation is shown as errorbars. In all plots, the y-axis is the total queries to simulator until convergence, which we chose as a performance criterion. (Left) Performance of h-PI as a function of h. (Center) Performance of κ-PI as a function of h eff (κ) = (1 -γκ) -1 , the 'effective' planning horizon. The κ values that resulted in the lowest number of simulator queries are κopt = 0.82, 0.82, 0.88, 0.92 for N = 25, 30, 35, 40, respectively. (Right) Performance of λ-PI as a function of λ. This corresponds to κλ-PI with κ = 0. The three plots demonstrate that the algorithms introduced in this work, h-PI and κ-PI, can outperform λ-PI in terms of best empirical performance.

Technion, Israel Institute of Technology

INRIA, Villers-lès-Nancy, F-54600, France. Correspondence to: Yonathan Efroni <jonathan.efroni@gmail.com>.Proceedings of the

35 th International Conference on Machine Learning, Stockholm, Sweden, PMLR 80, 2018. Copyright 2018 by the author(s).

In this context, we treat r π (•) as a constant mapping from R |S| to itself; i.e., for any v ∈ R |S| , r π (v) = r π .

Acknowledgments

We thank Timothy Mann and Guy Tennenholtz for helpful discussions and the reviewers for their comments. We also thank Liyu Chen for pointing to an incomplete proof which is now fixed. This work was partially funded by the Israel Science Foundation under contract 1380/16 and by the European Community's Seventh Framework Programme (FP7/2007-2013) under grant agreement 306638 (SUPREL)

Using these updating equations we see that the value at the k + 1 iteration of this algorithm can be written as

since π k+1 is the policy attaining the maximum in (27).

Thus, both κ-VI and κλ-PI with λ = κ produce the same sequence of values, given equal initial value, v 0 . In this sense, both of the algorithms are equivalent. However, we note that these algorithms are not computationally equivalent. This can be seen by focusing on the computations steps per iteration. The κ-VI algorithm updates a value function in every iteration whereas κλ-PI (with λ = κ) calculates a policy ( 27) and then updates the current value (28). These two forms do not necessarily share similar computational complexity.

G. Proof of Proposition 11

The proof is close in spirit to a related proof in (Schulman et al., 2015b) and can also be derived using the relations in ( 14), ( 15) and ( 16). We explicitly give here the proof for completeness. Furthermore, in this proof we explicitly show that the greedy sets are equal, a notion developed in this work.

We prove the first equality and then the second equality of the proposition. The first equality follows by a direct algebraic manipulation on the random variables inside the mean. For clarity, we use the notation a t = π(s t ).

(1 -κ)

In the second relation we used

, and in the last we packed the infinite sum and introduced a summation variable t. Since for every realization of the random variables this equality holds, it also holds for the mean. This concludes the proof of the first equality since we have explicitly shown equality between the optimization criteria.

We now prove the second equality, again with direct algebraic manipulation. We start with the last term in the proposition. Consider again the random variables inside the mean.

where the second relation holds because

κγ) t κγv(s t+1 ) + v(s 0 ). Eq. ( 30) varies from (29) only by v(s 0 ). The solution of the optimization problem, finding the κ-greedy policy, is invariant to the addition of v(s 0 ), since it is a constant w.r.t. the optimization problem. This concludes the proof.