Control is one of the key problems of Reinforcement Learning (RL, Sutton and Barto 2018), in which we seek a policy that maximizes certain performance metrics. The performance metric is usually the expectation of some random variable, for example, the expected episodic return (Puterman, 2014; Sutton and Barto, 2018). Although this paradigm has enjoyed great success in various domains (Mnih et al., 2015; Silver et al., 2016; Vinyals et al., 2019), we sometimes want to minimize certain risk measures of that random variable while maximizing its expectation. For example, a portfolio manager is usually willing to sacrifice the return of a portfolio to lower its risk. Risk-averse RL is a framework for studying such problems and has broad applications (Wang, 2000; Parker, 2009; Lai et al., 2011; Matthaeia et al., 2015; Majumdar and Pavone, 2020). Many risk measures have been applied to the episodic return random variable to control risk, for example, variance (Sobel, 1982; Mannor and Tsitsiklis, 2011; Tamar et al., 2012; Prashanth and Ghavamzadeh, 2013; Xie et al., 2018), value at risk (VaR, Chow et al. 2018), and conditional value at risk (CVaR, Chow and Ghavamzadeh 2014; Tamar et al. 2015; Chow et al. 2018). In this paper, we mainly focus on variance given its advantages in interpretability and computation (Markowitz and Todd, 2000; Li and Ng, 2000).
When the primary performance metric is the expectation of the episodic return random variable, it is natural to use the variance of the episodic return random variable as a risk measure. We, however, are not obligated to do so. In this paper, we design a new random variable, per-step reward, and use its variance for risk-averse RL. The expectation of the per-step reward matches the expectation of the episodic return up to a constant multiplier. Furthermore, we prove that the variance of the per-step reward bounds the variance of the episodic return from above, indicating minimizing the variance of the per-step reward implicitly minimizes the variance of the episodic return.
Considering the variance of the per-step reward, we derive the mean-variance policy iteration (MVPI) framework for risk-averse RL, with the help of cyclic coordinate ascent (Luenberger and Ye, 1984) and the Fenchel duality. MVPI is flexible in that all existing policy evaluation methods and risk-neutral control methods can be dropped in to obtain risk-averse control off the shelf, in both on-policy and off-policy settings. This flexibility offers two significant benefits: (1) It enables risk-averse RL to scale up easily to challenging domains with neural network function approximation. We propose risk-averse Proximal Policy Optimization (PPO, Schulman et al. 2017) as an instance of MVPI, which outperforms PPO in many Mujoco robot simulation domains. By contrast, previous risk-averse control methods that optimize the variance of the episodic return (Tamar et al., 2012; Prashanth and Ghavamzadeh, 2013; Xie et al., 2018) cannot be easily combined with advanced policy optimization techniques like PPO due to their reliance on the squared episodic return. As shown in our empirical study, the methods of Tamar et al. (2012); Prashanth and Ghavamzadeh (2013); Xie et al. (2018) suffer from poor performance in most Mujoco domains with neural network function approximation. (2) It enables off-policy risk-averse learning, which was difficult to achieve previously. For example, enabling off-policy learning for the methods of Tamar et al. (2012); Prashanth and Ghavamzadeh (2013); Xie et al. (2018) usually involves products of importance sampling ratios to reweight the squared episodic return, which suffer from high variance (Precup et al., 2001; Liu et al., 2018) and are compatible only with the setting where we have a single known behavior policy. By contrast, MVPI can leverage recent advances in density ratio learning (Hallak and Mannor, 2017; Gelada and Bellemare, 2019; Liu et al., 2018; Nachum et al., 2019a; Zhang et al., 2020a, b), which significantly reduces the variance from off-policy learning and is compatible with the behavior-agnostic off-policy learning setting (Nachum et al., 2019a), where we may have multiple unknown behavior policies.
We consider an infinite horizon MDP with a state space , an action space , a bounded reward function , a transition kernel , an initial distribution , and a discount factor . The initial state is sampled from . At time step , an agent takes an action according to , where is the policy followed by the agent. The agent then gets a reward and proceeds to the next state according to . In this paper, we consider a deterministic reward setting for the ease of presentation, following Chow (2017); Xie et al. (2018). The return at time step is defined as . When , is always well defined. When , to ensure remains well defined, it is usually assumed that all polices are proper (Bertsekas and Tsitsiklis, 1996), i.e., for any policy , the chain induced by
has some absorbing states, one of which the agent will eventually go to with probability 1. Furthermore, the rewards are always 0 thereafter. For any, is the random variable indicating the episodic return, and we use its expectation
as our performance metric. In particular, when , we can express as , where is a random variable indicating the first time the agent goes to an absorbing state. For any , the state value function and the state-action value function are defined as and respectively.
Mean-Variance RL. As is a random variable, we sometimes want to control its variance while maximizing its expectation (Prashanth and Ghavamzadeh, 2013; Tamar et al., 2012; Xie et al., 2018), which is usually referred to as mean-variance RL. Namely, we consider the following problem:
where indicates the variance of a random variable, indicates user’s tolerance for variance, and is parameterized by . We use and interchangeably in the rest of the paper.
where is the dual variable. Prashanth and Ghavamzadeh (2013)
use stochastic gradient descent to find the saddle-point of
. To estimate, they propose two simultaneous perturbation methods: simultaneous perturbation stochastic approximation and smoothed functional (Bhatnagar et al., 2013), yielding a three-timescale algorithm. Empirical success is observed in a simple traffic control MDP.
is a hyperparameter to be tuned andis a penalty function, which they define as . The analytical expression of they provide involves a term , leading to a double sampling issue. To address this, Tamar et al. (2012) consider a two-timescale algorithm and keep running estimates for and in a faster timescale, yielding an episodic algorithm. Given the -th episode , they propose the following updates:
where ; and are running estimates for and ; and are learning rates. Empirical success is observed in a simple portfolio management MDP.
We remark: (1) does not matter in Xie et al. (2018) as is the identity function. (2) can also be regraded as the dual variable in Tamar et al. (2012); Xie et al. (2018). Consequently, we can use gradient descent to optimize it. (3) Tamar et al. (2012); Xie et al. (2018) can also cope with the setting , if all policies are proper. Otherwise, it is infeasible to compute .
3 The Per-Step Reward Perspective
Although in many problems our goal is to maximize the undiscounted expected episodic return, practitioners often find that optimizing the discounted objective () as a proxy for the undiscounted objective () is better than optimizing the undiscounted objective directly, especially when deep neural networks are used as function approximator (Mnih et al., 2015; Lillicrap et al., 2015; Espeholt et al., 2018; Xu et al., 2018; Van Seijen et al., 2019). We, therefore, focus on the discounted setting in this paper.
It is well known that the expected discounted episodic return can be expressed as
where is the normalized discounted state-action distribution:
We now formally define the per-step reward random variable . Let and be the Borel algebra. We define a probability measure such that for any . Then forms a probability space, and we define the random variable , a deterministic mapping from to , as . Intuitively,
is a discrete random variable taking values in the image ofwith a probability mass function , where is the indicator function. It follows that
and remarkably, we have
As , , it suffices to show .
where the inequality comes from the infinite discrete form of Jensen’s inequality. ∎
Eq (11) suggests that the expectation of the random variable correctly indicates the performance of the policy , up to a constant multiplier. Theorem 1 suggests that minimizing the variance of implicitly minimizes the variance of . We, therefore, consider the following objective for risk-averse RL:
where is a hyperparameter and we have used the Fenchel duality to avoid a double-sampling issue. We, therefore, consider the following problem
3.1 Mean-Variance Policy Iteration
We propose a cyclic coordinate ascent (CCA, Luenberger and Ye 1984; Tseng 2001; Saha and Tewari 2010, 2013; Wright 2015) framework to solve (16), which updates and alternatively as shown in Algorithm 1.
In Algorithm 1, at the -the iteration, we first fix and update (Step 1). As is quadratic in , can be computed analytically as , i.e., all we need in this step is , which is exactly the performance metric of the policy . We, therefore, refer to Step 1 as policy evaluation. We then fix and update (Step 2). This maximization problem seems complicated at first glance, and we will soon discuss the solution to it. In this step, a new policy is computed. An intuitive conjecture is that this step is a policy improvement step, and we confirm this with the following theorem:
(Monotonic Policy Improvement) .
Though the monotonic improvement w.r.t. the objective in Eq (16) follows directly from standard CCA theories, Theorem 2 provides the monotonic improvement w.r.t. the objective in Eq (14). Details are provided in the appendix. Given Theorem 2, we can now consider the whole CCA framework in Algorithm 1 as a policy iteration framework, which we call mean-variance policy iteration (MVPI), and we have
(Convergence of MVPI) Under mild conditions, the policies generated by MVPI satisfies that converges and .
The precise statement of Corollary 1 and its proof are provided in the appendix. As we have shown that Algorithm 1 is a policy iteration framework, the problem narrows down to Step 2. The maximization in Step 2 seems challenging as it is nonlinear and nonconvex. A key observation is that it can be reduced to the following formulation:
where . In other words, to compute , we need to solve a new MDP, which is the same as the original MDP except that the reward function is instead of . Any risk-neutral control method can be used to solve this new MDP in a plug-play manner.
MVPI differs from the standard policy iteration (PI, e.g., see Bertsekas and Tsitsiklis 1996; Puterman 2014; Sutton and Barto 2018) in two key ways: (1) policy evaluation in MVPI requires only a scalar performance metric, while standard policy evaluation involves computing the value of all states. (2) policy improvement in MVPI considers an augmented reward (i.e., ), which is different at each iteration, while standard policy improvement always considers the original reward. Standard PI can be used to solve the policy improvement step in MVPI.
Motivated by the empirical success of PPO (OpenAI, 2018) and its convergence to the globally optimal policy (Liu et al., 2019a) (with over-parameterized neural networks), we now present Mean-Variance PPO (MVPPO, Algorithm 2), instantiating the idea of MVPI.
In MVPPO, is set to the empirical average reward directly. Theoretically, we should use a weighted average as is a discounted distribution. Though implementing this weighted average is straightforward, practitioners usually ignore discounting for state visitation in policy gradient methods to improve sample efficiency (Mnih et al., 2016; Schulman et al., 2015, 2017; Bacon et al., 2017). As the policy evaluation and the policy improvement in MVPPO are only partial, the convergence of MVPPO does not follow directly from Corollary 1, and we leave it for future work. Here we provide MVPPO mainly to verify the idea of MVPI empirically in challenging domains.
3.2 Off-Policy Learning
Previous work on mean-variance RL from the episodic return perspective considers only the on-policy setting and cannot be easily extended to the off-policy setting. For example, it is not clear whether perturbation methods for estimating gradients (Prashanth and Ghavamzadeh, 2013) can be used off-policy. Furthermore, the methods of Tamar et al. (2012); Xie et al. (2018) are episodic, involving terms like . To reweight and in the off-policy setting, we would need to compute the product of importance sampling ratios , where is the behavior policy. This product usually suffers from high variance (Precup et al., 2001; Liu et al., 2018) and requires knowing the behavior policy , both of which are practical obstacles in real applications.
We now consider off-policy mean-variance RL under the per-step reward perspective, i.e., we want to perform MVPI with off-policy samples. In particular, we consider the behavior-agnostic off-policy learning setting (Nachum et al., 2019a), where we have access to a batch of transitions . The state-actions pairs are distributed according to some unknown distribution , which may result from multiple unknown behavior policies. The successor state is distributed according to and .
In an off-policy setting, the policy evaluation step in MVPI becomes the standard off-policy evaluation problem (Thomas et al., 2015; Thomas and Brunskill, 2016; Jiang and Li, 2016; Liu et al., 2018), where we want to estimate a scalar performance metric of a policy with off-policy samples. One promising approach to off-policy evaluation is density ratio learning, where we use function approximation to learn the density ratio directly (Hallak and Mannor, 2017; Liu et al., 2018; Gelada and Bellemare, 2019), which we then use to reweight . Compared with products of importance sampling ratios, this density ratio learning approach significantly reduces the variance (Liu et al., 2018). Furthermore, it has recently been extended to the behavior-agnostic off-policy learning setting (Nachum et al., 2019a; Zhang et al., 2020a, b; Mousavi et al., 2020), and can thus be integrated into MVPI in a plug-and-play manner. In an off-policy setting, the policy improvement step in MVPI becomes the standard off-policy policy optimization problem. In the behavior-agnostic off-policy learning setting, we can reweight the canonical on-policy actor-critic (Sutton et al., 2000; Konda, 2002) with the density ratio as in Liu et al. (2019b) to achieve off-policy policy optimization.
All curves in this section are averaged over 30 independent runs with shaded regions indicate standard errors. All implementations are publicly available.111Link available upon publication.
On-Policy Setting. In many real world robot applications, e.g., in a warehouse, it is crucial that the robots’ performance be consistent. In such cases, risk-averse RL is an appealing option to train the robots. Motivated by this, we investigate mean-variance RL algorithms with six Mujoco robot manipulation tasks from OpenAI gym (Brockman et al., 2016). We use two-hidden-layer neural networks for function approximation. Details are provided in the appendix.
Comparison with other mean-variance RL methods. We compare MVPPO against the mean-variance RL algorithms in Prashanth and Ghavamzadeh (2013); Tamar et al. (2012); Xie et al. (2018). Previously, those algorithms were tested only on simple domains with tabular representations or linear function approximation. None has been benchmarked on Mujoco domains with neural network function approximation. Experience replay (Lin, 1992) and multiple parallel actors (Mnih et al., 2016) are common techniques for stabilizing RL agents when neural network function approximators are used. To make the comparison fair, we also implement the algorithms in Prashanth and Ghavamzadeh (2013); Tamar et al. (2012); Xie et al. (2018) with multiple parallel actors (they are on-policy algorithms so we cannot use experience replay). We also introduce Mean-Variance A2C (MVA2C) as a baseline, where A2C, a synchronized version of A3C (Mnih et al., 2016), is used for the policy improvement step in MVPI. For the compared algorithms, we tune in , in , and the initial learning rates in to maximize at the end of training. More details are in the appendix.
The results are reported Figure 3a. MVPPO with outperforms all baselines. By contrast, previous mean-variance RL methods generally suffer from poor performance in Mujoco domains with neural network function approximation, with the exception that Xie et al. (2018) acheive reasonable performance in Reacher-v2. No matter how we tune , the learning curves of the baseline mean-variance RL methods always remain flat, indicating they fail to achieve the risk-performance trade-off in Mujoco domains with neural network function approximation. We conjecture that perturbation-based gradient estimation in Prashanth and Ghavamzadeh (2013) does not work well with neural networks, and the term in Tamar et al. (2012); Xie et al. (2018) suffers from high variance, yielding instability. MVA2C also outperforms previous mean-variance RL methods, though it is outperformed by MVPPO. This indicates that part of the performance advantage of MVPPO comes from the more advanced policy optimization techniques (i.e., PPO). This flexibility of using any existing risk-neural control method for risk-averse control is exactly the key feature of MVPI.
Comparison with PPO. We compare MVPPO with vanilla PPO. Our PPO implementation uses the same architecture and hyperparameters as Schulman et al. (2017), and the performance of our PPO matches the PPO performance reported in Achiam (2018). The results are reported Figure 3b. In 4 out of the 6 tested domains, there is a such that MVPPO outperforms PPO, while in the remaining two domains, the performance of MVPPO with is also competitive. Though it is infeasible to expect a risk-averse algorithm to always outperform its risk-neutral counterpart in terms of a risk-neutral performance metric, our experimental results suggest that this does occur sometimes with task-specific risk level (). We conjecture that this is because the penalty term from the variance regularizes and stabilizes the training of neural networks. We also demonstrate that MVPPO achieves the trade-off between risk and performance. To this end, we test the agent at the end of training for an extra 100 episodes. We then report the normalized statistics of the episodic returns in Table 1. The original statistics are provided in the appendix. When we increase from 0.1 to 10, the decrease in the variance often becomes more and more significant. Furthermore, MVPPO usually outperforms PPO significantly in terms of the risk-sensitive performance metric when and . For , MVPPO has higher variance than PPO. As PPO is exactly MVPPO(). We conjecture that this increase in variance results from variability in estimating the average reward, which further translates into variability of the augmented reward , in turn increasing variability of the learned policy.
Off-Policy Setting. We consider a tabular infinite horizon MDP (Figure 6a). Two actions and are available at , and we have . The discount factor is and the agent is initialized at . We consider the objective in Eq (14). If , the optimal policy is to choose . If is large enough, the optimal policy is to choose . We consider the behavior-agnostic off-policy setting, where the sampling distribution satisfies . This sampling distribution may result from multiple unknown behavior policies. We use density-ratio-learning-based off-policy MVPI. Details are provided in the appendix. In particular, we use GradientDICE (Zhang et al., 2020b) for learning the density ratio. We report the probability of selecting against training iterations. As shown in Figure 6b, off-policy MVPI behaves correctly for both and . The main challenge in off-policy MVPI rests on learning the density ratio. Scaling up density ratio learning algorithms reliably to more challenging domains like Mujoco is out of the scope of this paper.
5 Related Work
are also used for risk-averse control. Risk measures can be classified into coherent/incoherent risk measures and time consistent/inconsistent risk measures, seeChow (2017) for details. Besides the expected episodic return, which is the primary objective for many mean-variance RL methods as discussed in Section 2, the average reward (Puterman, 2014) is also a commonly used performance metric, where is the stationary distribution of the chain induced by . Prashanth and Ghavamzadeh (2013) develop risk-averse control methods under the average reward criterion. Although our proposed metric has a similar structure as the average reward and can be interpreted as the average reward of a different MDP (see Konda (2002) for details), is literally the expected episodic return of the original MDP, up to a constant multiplier. Furthermore, our approach for optimizing and differs dramatically from Prashanth and Ghavamzadeh (2013). Deriving the MVPI framework under the average reward criterion is straightforward, and we leave it for future work.
In this paper, we propose the per-step reward perspective for risk-averse RL. Considering the variance of the per-step reward random variable, we derive the MVPI framework. MVPI enjoys great flexibility such that all policy evaluation methods and risk-neutral control methods can be dropped in for risk-averse control off the shelf, in both on-policy and off-policy settings. MVPI is the first empirical success of risk-averse RL in Mujoco robot simulation domains. Off-policy MVPI is the first success of off-policy risk-averse RL. Possibilities for future work include considering other risk measures (e.g., VaR and CVaR) of the per-step reward random variable, integrating more advanced off-policy policy optimization techniques (e.g., Nachum et al. 2019b) in off-policy MVPI, optimizing with meta-gradients (Xu et al., 2018), conducting a sample complexity analysis for MVPI, and developing theories for approximate MVPI.
Our work is beneficial for those exploiting RL to solve sequential decision making problems, including but not limited to portfolio management, autonomous driving, and warehouse robotics. They will be better at controlling the risk of their automated decision making systems. Failure of the proposed system may increase the variability of their automated decision making systems, yielding property loss. Like any artificial intelligence system, our work may reduce the need for human workers, resulting in job losses.
Acknowledgments and Disclosure of Funding
SZ is generously funded by the Engineering and Physical Sciences Research Council (EPSRC). This project has received funding from the European Research Council under the European Union’s Horizon 2020 research and innovation programme (grant agreement number 637713). The experiments were made possible by a generous equipment grant from NVIDIA. BL’s research is funded by the National Science Foundation (NSF) under grant NSF IIS1910794 and an Amazon Research Award.
- Spinning up in deep reinforcement learning. Cited by: §4.
- The option-critic architecture.. In Proceedings of the 31st AAAI Conference on Artificial Intelligence, Cited by: §3.1.
- Nonlinear programming. Athena Scientific. Cited by: §A.2.
- Neuro-dynamic programming. Athena Scientific Belmont, MA. Cited by: §2, §3.1.
- Stochastic recursive algorithms for optimization. Springer London. Cited by: §2.
- Q-learning for risk-sensitive control. Mathematics of operations research. Cited by: §5.
- Openai gym. arXiv preprint arXiv:1606.01540. Cited by: Appendix B, §4.
Risk-constrained reinforcement learning with percentile risk criteria.
The Journal of Machine Learning Research. Cited by: §1.
- Algorithms for cvar optimization in mdps. In Advances in Neural Information Processing Systems, Cited by: §1.
- Risk-sensitive and data-driven sequential decision making. Ph.D. Thesis, Stanford University. Cited by: §2, §5.
- Multi-step reinforcement learning: a unifying algorithm. In Proceedings of the 32nd AAAI Conference on Artificial Intelligence, Cited by: 3.
- OpenAI baselines. GitHub. Note: https://github.com/openai/baselines Cited by: Appendix B.
- Impala: scalable distributed deep-rl with importance weighted actor-learner architectures. arXiv preprint arXiv:1802.01561. Cited by: §3.
- Off-policy deep reinforcement learning by bootstrapping the covariate shift. In Proceedings of the 33rd AAAI Conference on Artificial Intelligence, Cited by: §1, §3.2.
- Consistent on-line off-policy evaluation. In Proceedings of the 34th International Conference on Machine Learning, Cited by: §1, §3.2.
- Doubly robust off-policy value evaluation for reinforcement learning. In International Conference on Machine Learning, Cited by: §3.2.
- Actor-critic algorithms. Ph.D. Thesis, Massachusetts Institute of Technology. Cited by: §3.2, §5.
- Mean-variance portfolio optimization when means and covariances are unknown. The Annals of Applied Statistics. Cited by: §1.
- Optimal dynamic portfolio selection: multiperiod mean-variance formulation. Mathematical finance. Cited by: §1.
- Continuous control with deep reinforcement learning. arXiv preprint arXiv:1509.02971. Cited by: §3.
- Self-improving reactive agents based on reinforcement learning, planning and teaching. Machine Learning. Cited by: §4.
- Neural trust region/proximal policy optimization attains globally optimal policy. In Advances in Neural Information Processing Systems, Cited by: §3.1.
- Breaking the curse of horizon: infinite-horizon off-policy estimation. In Advances in Neural Information Processing Systems, Cited by: §1, §3.2, §3.2.
- Off-policy policy gradient with state distribution correction. arXiv preprint arXiv:1904.08473. Cited by: §3.2.
- Linear and nonlinear programming (3rd edition). Springer. Cited by: §A.2, §1, §3.1, Remark 1.
- How should a robot assess risk? towards an axiomatic theory of risk in robotics. In Robotics Research, Cited by: §1.
Mean-variance optimization in markov decision processes. arXiv preprint arXiv:1104.5601. Cited by: §1.
- Mean-variance analysis in portfolio choice and capital markets. John Wiley & Sons. Cited by: §1.
- Autonomous driving: technical, legal and social aspects. Springer, Berlin. Cited by: §1.
- Asynchronous methods for deep reinforcement learning. In Proceedings of the 33rd International Conference on Machine Learning, Cited by: §3.1, §4.
- Human-level control through deep reinforcement learning. Nature. Cited by: §1, §3.
- Black-box off-policy estimation for infinite-horizon reinforcement learning. In International Conference on Learning Representations, Cited by: §3.2.
- DualDICE: behavior-agnostic estimation of discounted stationary distribution corrections. arXiv preprint arXiv:1906.04733. Cited by: §1, §3.2, §3.2.
- AlgaeDICE: policy gradient from arbitrary experience. arXiv preprint arXiv:1912.02074. Cited by: §6.
- Rectified linear units improve restricted boltzmann machines. In Proceedings of the 27th International Conference on Machine Learning, Cited by: Appendix B.
- OpenAI five. Note: https://openai.com/five/ Cited by: §3.1.
- Managing risk in healthcare: understanding your safety culture using the manchester patient safety framework (mapsaf). Journal of nursing management. Cited by: §1.
- Actor-critic algorithms for risk-sensitive mdps. In Advances in neural information processing systems, Cited by: Appendix B, Appendix B, §1, §1, §2, §2, §3.2, §4, §4, §5.
- Off-policy temporal-difference learning with function approximation. In Proceedings of the 18th International Conference on Machine Learning, Cited by: §1, §3.2.
- Markov decision processes: discrete stochastic dynamic programming. John Wiley & Sons. Cited by: §1, §3.1, §5.
- On the finite time convergence of cyclic coordinate descent methods. arXiv preprint arXiv:1005.2146. Cited by: §3.1.
- On the nonasymptotic convergence of cyclic coordinate descent methods. SIAM Journal on Optimization 23 (1), pp. 576–601. Cited by: §3.1.
- Trust region policy optimization. In Proceedings of the 32nd International Conference on Machine Learning, Cited by: Appendix B, §3.1.
- Proximal policy optimization algorithms. arXiv preprint arXiv:1707.06347. Cited by: Appendix B, Appendix B, §1, §3.1, §4, 2.
- Mastering the game of go with deep neural networks and tree search. Nature. Cited by: §1.
- The variance of discounted markov decision processes. Journal of Applied Probability. Cited by: §1.
- Reinforcement learning: an introduction (2nd edition). MIT press. Cited by: §1, §3.1.
- Policy gradient methods for reinforcement learning with function approximation. In Advances in Neural Information Processing Systems, Cited by: §3.2.
- Policy gradients with variance related risk criteria. arXiv preprint arXiv:1206.6404. Cited by: Appendix B, Appendix B, §1, §1, §2, §2, §2, §3.2, §4, §4, §5.
- Optimizing the cvar via sampling. In Proceedings of the 29th AAAI Conference on Artificial Intelligence, Cited by: §1.
- Data-efficient off-policy policy evaluation for reinforcement learning. In International Conference on Machine Learning, pp. 2139–2148. Cited by: §3.2.
- High-confidence off-policy evaluation. In Twenty-Ninth AAAI Conference on Artificial Intelligence, Cited by: §3.2.
- Convergence of a block coordinate descent method for nondifferentiable minimization. Journal of optimization theory and applications 109 (3), pp. 475–494. Cited by: §3.1, Remark 1.
- Using a logarithmic mapping to enable lower discount factors in reinforcement learning. In Advances in Neural Information Processing Systems, Cited by: §3.
- Grandmaster level in starcraft ii using multi-agent reinforcement learning. Nature. Cited by: §1.
- A class of distortion operators for pricing financial and insurance risks. Journal of risk and insurance. Cited by: §1.
- Coordinate descent algorithms. Mathematical Programming 151 (1), pp. 3–34. Cited by: §3.1.
- A block coordinate ascent algorithm for mean-variance optimization. In Advances in Neural Information Processing Systems, Cited by: Appendix B, Appendix B, §1, §1, §2, §2, §2, §2, §3.2, §4, §4.
- Meta-gradient reinforcement learning. In Advances in neural information processing systems, Cited by: §3, §6.
- GenDICE: generalized offline estimation of stationary values. In International Conference on Learning Representations, Cited by: §1, §3.2.
- GradientDICE: rethinking generalized offline estimation of stationary values. arXiv preprint arXiv:2001.11113. Cited by: §1, §3.2, §4, 3.
Appendix A Proofs
a.1 Proof of Theorem 2
|(By definition, is the maximizer.)|
|(By definition, is the maximizer of the quadratic.)|
a.2 Proof of Corollary 1
Let be our function class for the policy optimization. We assume
The policy is differentiable in , is a compact set, and for each , .
For each , there is a unique maximizing .
As is quadratic in , the maximizing for each is . As rewards are bounded, we have , allowing us to specify a compact set such that for each , . To make it clear, we rephrase Corollary 1 as
Under Assumptions 1 and 2, standard CCA theories (e.g., page 253 in Luenberger and Ye (1984)) show that the limit of any convergent subsequence , referred to as , satisfies and . As is quadratic in , implies . Recall the Fenchel’s duality
where . Applying Danskin’s theorem (Proposition B.25 in Bertsekas (1995)) to Fenchel’s duality yields
Note Danskin’s theorem shows that we can treat as a constant independent of when computing the gradients in the RHS of Eq (31). Applying Danskin’s theorem in the Fenchel duality used in Eq (14) yields
Eq (32) can also be easily verified without invoking Danskin’s theorem by expanding the gradients explicitly. Eq (32) indicates that the subsequence converges to a stationary point of . As and are compact, such a convergent subsequence always exists, implying . The convergence of follows directly from Theorem 1.
Appendix B Experiment Details
For all compared algorithms in Mujoco domains, we use two-hidden-layer networks to parameterize policy and value function. Each hidden layer has 64 hidden units and a ReLU(Nair and Hinton, 2010)activation function. In particular, we parameterized
as a diagonal Gaussian distribution with the mean being the output of the network. The standard derivation is a global state-independent variable. This is a common policy parameterization for continuous-action problems(Schulman et al., 2015, 2017).
Hyperparameter Tuning: For PPO, we use the same hyperparameters as Schulman et al. (2017). MVPPO inherits the hyperparameters from PPO directly without any further tuning. For MVA2C, we use the common A2C hyperparameters from Dhariwal et al. (2017). We implement the methods of Prashanth and Ghavamzadeh (2013); Tamar et al. (2012); Xie et al. (2018) with multiple parallelized actors like A2C.
Hyperparameters of PPO and MVPPO: We use an Adam optimizer with and an initial learning rate . The discount factor is 0.99. The GAE coefficient is 0.95. We clip the gradient by norm with threshold 0.5. The rollout length ( in Algorithm 2
) is 2048. The number of optimization epochs is 10 with batch size 64. We clip the action probability ratio with threshold 0.2.
Hyperparameters of MVA2C:
We use 16 parallelized actors. The initial learning rate for the RMSprop optimizer is, The discount factor is 0.99. We use policy entropy as a regularization term, whose weight is 0.01. The rollout length is 5. As the rollout length is much smaller than PPO/MVPPO, we use running estimates for the policy evaluation step. We clip the gradient by norm with threshold 0.5. We tune from and find the best.
Hyperparameters of Prashanth and Ghavamzadeh (2013): To increase stability, we treat as a hyperparameter instead of a variable. Consequently, does not matter. We tune from and find the best. We set the perturbation in Prashanth and Ghavamzadeh (2013) to . We use 16 parallelized actors. The initial learning rate of the RMSprop optimizer is , tuned from . We also test the Adam optimizer, which performs the same as the RMSprop optimizer. We use policy entropy as a regularization term, whose weight is 0.01. The discount factor is 0.99. We clip the gradient by norm with threshold 0.5.
Hyperparameters of Tamar et al. (2012): We use , tuned from . We use , tuned from . We set the initial learning rate of the RMSprop optimizer to , tuned from . We also test the Adam optimizer, which performs the same as the RMSprop optimizer. The learning rates for the running estimates of and is 100 times of the initial learning rate of the RMSprop optimizer. We use 16 parallelized actors. We use policy entropy as a regularization term, whose weight is 0.01. We clip the gradient by norm with threshold 0.5.
Hyperparameters of Xie et al. (2018): We use , tuned from . We set the initial learning rate of the RMSprop optimizer to , tuned from . We also test the Adam optimizer, which performs the same as the RMSprop optimizer. We use 16 parallelized actors. We use policy entropy as a regularization term, whose weight is 0.01. We clip the gradient by norm with threshold 0.5.
We conduct our experiments on an Nvidia DGX-1 with PyTorch, though no GPU is used.
The pseudocode of Off-Policy MVPI is provided in Algorithm 3. In our off-policy experiments, we set to and use tabular representation for , and .
Appendix C Other Experimental Results
We report the original evaluation performance of MVPPO and PPO in Table 2.