Efficient Risk-Averse Reinforcement Learning
Abstract
In risk-averse reinforcement learning (RL), the goal is to optimize some risk measure of the returns.
A risk measure often focuses on the worst returns out of the agent’s experience.
As a result, standard methods for risk-averse RL often ignore high-return strategies.
We prove that under certain conditions this inevitably leads to a local-optimum barrier, and propose a mechanism we call soft risk to bypass it.
We also devise a novel cross entropy module for sampling, which (1) preserves risk aversion despite the soft risk; (2) independently improves sample efficiency.
By separating the risk aversion of the sampler and the optimizer, we can sample episodes with poor conditions, yet optimize with respect to successful strategies.
We combine these two concepts in CeSoR – Cross-entropy Soft-Risk optimization algorithm – which can be applied on top of any risk-averse policy gradient (PG) method.
We demonstrate improved risk aversion in maze navigation, autonomous driving, and resource allocation benchmarks, including in scenarios where standard risk-averse PG completely fails.
Our results and CeSoR implementation are available on Github.
The stand-alone cross entropy module is available on PyPI.
Introduction
Risk-averse reinforcement learning (RL) is important for high-stake applications, such as driving, robotic surgery, and finance [Vittori et al., 2020].
In contrast to risk-neutral RL, it optimizes a risk measure of the return random variable, rather than its expectation.
A popular risk measure is the Conditional Value at Risk (CVaR), defined as CVaR α ( R ) =
E [ R | R ≤ q α ( R )] , where q α ( R ) = inf { x | F R ( x ) ≥ α } is the α -quantile of the random variable R and F R is its CDF.
Intuitively, CVaR measures the expected return below a specific quantile α , also termed the risk level.
CVaR optimization is widely researched in the RL community, e.g., using adjusted policy gradient approaches (CVaR-PG)
[Tamar et al., 2015b, Hiraoka et al., 2019].
In addition, CVaR is a coherent risk measure, and its optimization is equivalent to a robust optimization problem [Chow et al., 2015].
Since risk-averse RL aims to avoid the hazardous parts of the environment (e.g., dangerous areas in navigation), CVaR-PG algorithms typically sample a batch of N trajectories (episodes), and then optimize w.r.t.
the mean of the αN trajectories with worst returns [Tamar et al., 2015b, Rajeswaran et al., 2017].
This approach suffers from two major drawbacks: (i) 1 − α of the batch is wasted and excluded from the optimization (where often 0 .
01 ≤ α ≤ 0 . 05 ), leading to sample inefficiency; (ii) focusing on the worst episodes inherently overlooks good agent strategies corresponding to high returns – a phenomenon we refer to as the blindness to success .
An illustrative example – the Guarded Maze : Consider the Guarded Maze benchmark (visualized in Figure 1d).
The goal is to reach the target zone (a constant location marked in green), resulting in
[Figure]
a reward of 16 points.
However, the guarded zone (in red) may be watched by a guard who demands a payment from any agent that passes by.
Every episode, the probability that a guard is present is ϕ 1 = 20% , and the payment is exponentially-distributed with average ϕ 2 = 32 .
That is, the cost of crossing the guarded zone in a certain episode is C = C 1 · C 2 , where C 1 ∼ Ber ( ϕ 1 ) , C 2 ∼
Exp ( ϕ 2 ) are independent and unknown to the agent.
The agent starts at a random point at the lower half, and every time-step, observing its location, it selects an action: left, right, up or down, with an additive control noise.
One point is deducted per step, up to 32 deductions.
In this maze, the shortest path maximizes the average return; yet, the longer path is CVaR-optimal, since sometimes short cuts make long delays [Tolkien, 1954].
However, the standard CVaR-PG optimizer (GCVaR in Figure 1) suffers from blindness to success: in a batch of N random episodes, the worst αN returns (e.g., for α = 5% ) usually correspond to either encountering a guard in the short path, or not reaching the goal at all.
Hence, the desired long path is never even observed by the
CVaR-PG optimizer, and cannot be learned.
Our key insight is that the variation in returns comes from both environment conditions ( epistemic uncertainty) and agent actions ( aleatoric uncertainty).
We wish to focus on the low quantiles w.r.t.
the conditions (e.g., a costly guard in the short path of the maze), yet to be exposed to the high quantiles w.r.t.
the strategies (e.g., taking the long path in the maze).
To that end, we devise two mechanisms: first, we use a soft risk-level scheduling method, which begins the training with risk neutrality α ′
= 1 , and gradually shifts the risk aversion to α ′
=
α .
Second, we present a novel dynamic-target version of the Cross Entropy method (CE or CEM)
[de Boer et al., 2005], aiming to sample the worst parts of the environment.
That is, the CEM samples trajectories with more challenging or riskier conditions, and the soft risk feeds a larger part of them ( α ′ ≥ α ) to the CVaR-PG optimizer.
Together, these constitute the Cross-entropy method for Soft-Risk optimization ( CeSoR ).
CeSoR can be applied on top of any CVaR-PG method to learn any differentiable model (e.g., a neural network).
To apply the CEM, we assume to have certain control over the environment conditions.
For example, in driving we may choose the roads for collecting training data, or in any simulation we may control the environment parameters (e.g., ϕ 1 , ϕ 2 in the Guarded Maze).
Note that (i) only the CE sampler (not the agent) is aware of the conditions; (ii) their underlying effect is unknown to the sampler and may vary with the agent throughout the training, hence the CEM needs to learn it adaptively.
Contribution: We present the following contribution for PG algorithms under risk-sensitive MDP problems (as defined in Section 2):
We analyze the phenomenon of blindness to success in the standard CVaR-PG, and show that it leads to a local-optimum barrier in certain environments (Section 3.1).
We analyze the potential increase in sample efficiency – if we could sample directly from the tail of the returns distribution (Section 3.2).
We introduce the CeSoR algorithm (Section 4), which modifies any CVaR-PG method with: (i) a soft risk mechanism preventing blindness to success; (ii) a novel dynamic-CE method that over-samples the riskier realizations of the environment, increasing sample efficiency.
We demonstrate the effectiveness of CeSoR in 3 risk-sensitive domains (Section 5), where it learns faster and achieves higher returns (both CVaR and mean) than the baseline CVaR-PG.
1.1 Related Work
Optimizing risk in RL is crucial to enforce safety in decision-making [García and Fernández, 2015,
Paduraru et al., 2021].
It has been long studied through various risk criteria, e.g., mean-variance
[Sato et al., 2001, Prashanth and Ghavamzadeh, 2013, 2016, Xie et al., 2018], entropic risk measure [Borkar and Meyn, 2002, Borkar and Jain, 2014, Fei et al., 2021] and distortion risk measures [Vijayan and
Prashanth, 2021].
Tamar et al.
[2015a] derived a PG method for general coherent risk measures, given their risk-envelope representation.
The CVaR risk measure specifically was studied using value iteration
[Chow et al., 2015] and distributional RL [Dabney et al., 2018a, Tang et al., 2019, Bodnar et al., 2020] (also discussed in
Appendix H).
CVaR optimization was also shown equivalent to mean optimization under robustness
[Chow et al., 2015], motivating robust-RL methods [Pinto et al., 2017, Godbout et al., 2021].
Yet, PG remains the most popular approach for CVaR optimization in RL [Tamar et al., 2015b, Rajeswaran et al., 2017, Hiraoka et al., 2019, Huang et al., 2021b], and can be flexibly applied to a variety of use-cases, e g
, mixed mean-CVaR criteria [Chow and Ghavamzadeh, 2014] and multi- problems [Qiu et al., 2021].
Optimizing the CVaR for risk levels α ≪ 1 poses a significant sample efficiency challenge, as only a small portion of the agent’s experience is used to optimize its policy [Curi et al., 2020].
Keramati et al.
[2020] used an exploration-based approach to address the sample efficiency.
Pessimistic sampling for improved sample efficiency was suggested heuristically by Tamar et al.
[2015b] using a dedicated value function, but no systematic method was suggested to direct the pessimism level.
In this work, we use the CEM to control the sampled episodes around the desired risk level α , and demonstrate CVaR optimization for as extreme levels as α = 1% .
Note that unlike other CE-optimizers in RL [Mannor et al., 2003, Huang et al., 2021c], we use the CEM for sampling , to support a gradient-based optimizer.
Problem Formulation
Consider a Markov Decision Process (MDP) ( S, A, P, γ, P 0 ) , corresponding to states, actions, statetransition and reward distribution, discount factor, and initial state distribution, respectively.
For any policy parameter θ ∈ R n , we denote by π θ the parameterized policy that maps a state to a probability distribution over actions.
Given a state-action-reward trajectory τ = { ( s t , a t , r t ) } Tt =0 , the trajectory total return is denoted by R ( τ ) =
(cid:80) Tt =
γ t r t .
The expected return of a policy π θ is defined as
[Equation] [Equation]
where P π θ ( τ ) =
P 0 ( s 0 ) (cid:81) T − 1 t =
P ( s t +1 , r t | s t , a t )
π θ ( a t | s t ) is the probability distribution of τ induced by π θ .
Under the risk-neutral objective, the PG method uses the gradient ∇ θ J ( π θ ) to learn θ , aiming to increase the probability of actions that lead to higher returns.
In contrast, CVaR-PG methods aim to optimize the risk-averse CVaR α objective (w.r.t.
a given risk level α ):
[Equation]
where q α ( R | π θ ) is the α -quantile of the return random variable of policy π θ .
Thus, CVaR-PG algorithms aim to improve the actions specifically for episodes whose returns are lower than q α
( R | π θ ) .
Specifically, given a batch of N trajectories { τ i } N i =1 whose empirical return quantile is ˆ q α =
ˆ q α ( { R ( τ i ) } Ni =1 ) , the CVaR gradient estimation is given by [Tamar et al., 2015b]:
[Equation]
where w i =
P π θ ( τ i ) /f
( τ i | π θ ) is the importance sampling (IS) correction factor for τ
i , if τ i is sampled from a distribution f ̸ = P π θ .
Specifically, as discussed below, we modify the sample distribution using the cross entropy method over a context-MDP formulation of the environment.
Context-MDP: As mentioned above, we aim to focus on high-risk environment conditions.
To discuss the notion of conditions, given a standard MDP, we extend its formulation to a Context-MDP (C-MDP)
[Hallak et al., 2015], where the context is a set of variables that capture (part or all of) the randomness of the original MDP.
We define the extension as ( S, A, C , P C , γ, P 0 , D ϕ 0 ) , where
C ∈ C is sampled from the context space C according to the distribution D ϕ 0 parameterized by ϕ 0 , and P C ( · ) =
P ( ·| C ) is the transition and reward distribution conditioned on C .
In a C-MDP, a context-trajectory pair is sampled from the distribution P π θ ϕ
( C, τ ) =
D ϕ
( C ) P π θ C ( τ ) , where
P π θ C ( τ ) = P 0 ( s 0 ) (cid:81) T − 1 t =
P C ( s t +1 , r t | s t , a t )
π θ ( a t | s t ) .
The mean and CVaR α objectives J ( π θ ) ,
J α ( π θ ) in Equations (1) and (2) are naturally generalized to C-MDP using the distribution P π θ ϕ 0 ( C, τ ) .
Once we extend an MDP into a C-MDP, we can learn how to modify the context-distribution parameter ϕ to sample high-risk contexts and trajectories, focusing the training on high-risk parts of the environment and thus improving sample efficiency.
For this, we assume that certain aspects of the training environment (represented by C ) can be controlled.
This assumption indeed holds in many practical applications – in both simulated and physical environments.
For example, consider a data collection procedure for a self-driving agent training, which by default samples all driving hours uniformly: C ∼ U ([0 , 24)) .
As the hour may affect traffic and driving patterns, a risk-averse driver would prefer to sample more experience in high-risk hours.
To that end, we could re-parameterize the uniform distribution as, say, Beta ( ϕ ) with ϕ 0 = (1 , 1) (note that Beta (1 , 1) is the uniform distribution), learn the high-risk hours, and modify ϕ to over-sample them.
As another example, in the Guarded Maze described above, we can control the parameters ϕ 1 , ϕ 2 of the simulation.
Limitations of CVaR-PG
Consider the standard CVaR-PG algorithm, which relies on Equation (3) to apply PG for maximization of J α ( π θ ) of (2).
In this section, we analyze two major limitations of this algorithm.
Section 3. analyzes the blindness to success phenomenon, which may bring CVaR-PG learning to a localoptimum deadlock.
This will motivate the soft-risk scheduling in Section 4.
Section 3.2 analyzes the potential increase in sample efficiency when the environmental context is sampled in correspondence to the tail of the returns distribution.
This will motivate the cross-entropy sampler in Section 4.
While the analysis focuses on CVaR-PG methods, Appendix H discusses Distributional RL algorithms for CVaR optimization, and demonstrates that similar limitations apply to these methods as well.
3.1 Blindness to Success
We formally analyze how the blindness to success phenomenon can bring the policy learning to a local-optimum deadlock by ignoring successful agent strategies.
Recall the α -quantile of a return distribution q π α = min { r | F R ( a ) | π ( r ) ≥ α } .
We first introduce the notion of a tail barrier , corresponding to a returns-distribution tail with a constant value.
Definition 1 (Tail barrier) .
Let α ∈ (0 , 1] .
A policy π has an α -tail barrier if ∀ α ′ ∈ [0 , α ] : q πα ′ =
q πα .
Note that in any environment with a discrete rewards distribution, a policy is prone to having a tail barrier for some α > 0 .
In existing CVaR-PG analysis [Tamar et al., 2015b], such barriers are often overlooked by assuming continuous rewards.
For the Guarded Maze, Figure 13c in the appendix demonstrates how a standard CVaR-PG exhibits a 0 .
9 -tail barrier, since as many as 90% of the trajectories reach neither the target nor the guard, and thus have identical low returns.
A tail barrier has a destructive effect on CVaR-PG.
Consider a CVaR α objective, and a policy π with a β -tail barrier where β > α .
Intuitively, any infinitesimal change of π cannot affect the CVaR return, since the returns infinitesimally-above q πα are identical to those below q πα .
That is, any tail barrier wider than α brings the CVaR-PG to a stationary point of type plateau.
More formally, consider ∇ θ ˆ J α of Equation (3) with a β -tail barrier β > α : any trajectory has either 111 R ( τ i ) ≤ q πα =
(if its return is above q πα ) or R ( τ i ) − q πα =
(otherwise), hence the whole gradient vanishes.
Such a loss plateau was also observed in a specific MDP in Section 5.1 of Huang et al.
[2021a].
In practice, a discrepancy between q πα and its estimate
ˆ q α ( { R ( τ i ) } ) (used in Equation 3) may prevent the gradient from completely vanishing, if q πα = q πβ < ˆ q α ( { R ( τ i ) } ) .
Otherwise, if ˆ q α ( { R ( τ i ) } ) ≤ q πβ in every subsequent iteration, the gradient remains zero, the policy cannot learn any further, and any trajectory returns beyond q πα will never be even propagated to the optimizer.
We refer to this phenomenon as blindness to success .
Definition 2 (Blindness to success) .
Let a risk level α ∈ (0 , 1) and a CVaR-PG training step m 0 ≥ 1 , and let β ∈
( α, 1) .
Denote by T , Π the spaces of trajectories and policies, respectively, and by { τ m,i } Ni =1 ∼ P π m the random trajectories in step m ≥ m 0 .
We denote by B m 0 ,n α,β the event of blindness to success in the subsequent n steps (and the complementary event by ¬B m 0 ,n α,β ):
[Equation]
Note that Definition 2 uses q π m 0 β (corresponding to step m 0 ) to bound the returns in training steps m > m 0 , thus indeed represents training stagnation.
Theorem 1 shows that given a β -tail barrier with β > α , the probability that CVaR-PG avoids the blindness to success decreases exponentially with β − α .
For example, for n = 10 6 , α = 0 .
05 , β = 0 .
25 , and N = 400 , we have P ( ¬B m 0 ,n α,β ) < 10 − 7 .
Theorem 1.
Under Definition 2’s conditions, P (cid:16) ¬B m 0 ,n α,β (cid:12) (cid:12) π m 0 has β -tail barrier (cid:17) ≤ ne − 2 N ( β − α ) 2 .
Proof sketch (see the full proof in Appendix A).
In every step m , we have q π m 0 β < ˆ q α ( { R ( τ m,i ) } ) only if at least 1 − α of the returns are higher than q π m 0 β .
We bound the probability of this event using the Hoeffding inequality (Lemma 1).
In the complementary event the gradient is 0 (due to the barrier), thus the policy does not change, and the argument can be applied inductively to the next step.
3.2 Variance Reduction and Sample Efficiency
As discussed in Section 2, an MDP can be often re-parameterized as a C-MDP.
In terms of the C-MDP,
CVaR-PG samples N context-trajectory pairs from the distribution P π θ ϕ 0 ( C, τ ) , and calculates the policy gradients with respect to the αN trajectories with the lowest returns.
That is, CVaR-PG aims to follow the policy gradients corresponding to the tail distribution defined by
[Equation]
Notice that by considering only α of the trajectories, CVaR-PG essentially suffers from α − 1 -reduction in sample efficiency in comparison to risk-neutral PG.
Proposition 1 shows that if we could sample trajectories directly from P π θ ϕ 0 ,α , we would reduce the variance of the policy gradient estimate (and thus increase the sample efficiency) back by a factor of α − 1 .
This will motivate the CEM in Section 4, which will aim to modify ϕ such that P π θ ϕ ≈ P π θ ϕ 0 ,α .
Proposition 1 (Variance reduction) .
If the quantile estimation error is negligible ( ˆ q α =
q
α
( R | π θ ) in
Equation (3)), then
[Equation]
Proof sketch (see the full proof in Appendix B).
Since the left term corresponds to the sample distribution P π θ ϕ 0 ,α , the corresponding IS weights are w ≡ α w.p. 1.
When applying IS analysis to the expected value, w cancels out the distributional shift (as in Equation 5), resulting in the same expected gradient estimate.
When applying the same analysis to the variance, we begin with the square weight w 2 , thus a w =
α factor still remains after the distributional shift compensation.
The variance reduction can be connected to sample efficiency through the convergence rate as follows.
According to Theorem 5.5 in Xu et al.
[2020], denoting the initial parameters by θ 0 , the convergence of any CVaR-PG algorithm can be written as E [ ∥∇ θ J α ( π
[Equation] [Equation]
O
[Equation]
M
[Equation]
+
O ( Var
[Equation] [Equation]
} Ni =1 ; π
[Equation]
) αN ) .
Clearly, variance reduction of α -factor linearly improves the second term.
In particular, it cancels out the denominator’s α -factor attributed to tail sub-sampling, and brings the sample efficiency back to the level of the risk-neutral PG.
The Cross-entropy Soft-Risk Algorithm
Algorithm 1 presents our Cross-entropy Soft-Risk algorithm ( CeSoR ), which uses a PG approach to maximize J α ( π θ ) in (2).
CeSoR adds two components on top of CVaR-PG: soft-risk scheduling to address the blindness to success analyzed in Section 3.1, and CE sampling to address the sample efficiency analyzed in Section 3.2.
Algorithm 1: CeSoR 1 Input : risk level α ; context distribution D ϕ ; original context parameter ϕ 0 ; training steps M ; trajectories sampled per batch N , where ν fraction of them is from the original D ϕ 0 ; smoothed CE quantile β ; risk-level scheduling factor ρ 2 Initialize: policy π θ , ϕ ← ϕ 0 , 3 N o ← ⌊ νN ⌋ ,
N s ← ⌈ (1 − ν ) N ⌉ 4 for m in 1 : M do //
Sample contexts
Sample { C o,i } N o i =1 ∼ D ϕ 0 , { C ϕ,i } N s i =1 ∼ D ϕ
C ← ( C o, 1 , . . .
, C o,N o , C ϕ, 1 , . .
C ϕ,N s ) w o,i ← 1 , ∀ i ∈ { 1 , . . .
, N o } w ϕ,i ← D ϕ
( C ϕ,i )
D ϕ
( C ϕ,i ) , ∀ i ∈ { 1 , . .
. , N s } w ← ( w o, 1 , . . . , w o,N o , w ϕ, 1 , . . . , w ϕ,N s ) //
Sample trajectories { τ C o,i } , { τ C ϕ,i } ← run_episodes ( π θ , C ) //
Update CE sampler q ← max(ˆ q α ( { R ( τ C o,i ) } ) , ˆ q β ( { R ( τ C · ,i ) } ))
ϕ ← argmax ϕ ′
(cid:80) i ≤ N w i 111 R ( τ Ci ) ≤ q log D ϕ ′
( C i ) //
PG step (e.g., Eq
[Table] [Table]
[Table]
Soft-risk scheduler : We set the policy optimizer (Line 15 in Algorithm 1) to use a soft risk level α ′ that gradually decreases from 1 to α
(Line 13 and Figure 2).
This is motivated by the blindness to success analyzed in Section 3.1: by modifying the risk level to α ′ > α , and specifically α ′
≈ 1 at the beginning of training, we guarantee that there cannot be a wider tail barrier β > α ′ .
Thus, CeSoR can feed the optimizer with trajectories whose returns q πβ < R ≤ q πα ′ are higher than any constant tail; and since the fed returns are not constant, they do not eliminate the gradient.
In this sense, CeSoR looks beyond local optimization-plateaus to prevent the blindness to success.
The scheduling defined in Line 13 and
Figure 2 is heuristic.
As demonstrated in
Section 5, once we understand the limitation of blindness to success, this simple heuristic is sufficient to bypass the blindness.
An adaptive α ′ scheduling that maximizes blindness prevention probability would require tighter concentration inequalities [Boucheron et al., 2013], and is left for future work.
Cross Entropy Method (CEM) :
The CEM [de Boer et al., 2005] is a general approach to rareevent sampling and optimization, which we use to sample high-risk contexts and trajectories.
First, we review the standard CEM in terms adjusted to our setting and notations (for a more general presentation, see Algorithm 2 in the appendix).
Then, we discuss the limitations of the standard CEM in the RL settings, and present our dynamic, regularized version of the CEM.
Motivated by the sample efficiency analysis of Section 3.2, we wish to align the agent’s experience with the α worst-case returns – by sampling contexts whose corresponding trajectory-returns are likely to be below q
α
( R | π θ ) .
That is, we wish to sample context-trajectory pairs from P π θ ϕ 0 ,α of (4).
To that end, the CEM searches for a value of ϕ for which P π θ ϕ is similar to P π θ ϕ 0 ,α .
More precisely, it looks for ϕ ∗ that minimizes the KL-divergence (i.e., cross-entropy) between the two:
[Equation]
where P π θ ϕ ′ ( C, τ ) =
D ϕ ′
( C ) P π θ C ( τ ) (Section 2), and w ( C, τ ) =
P πθϕ
( C,τ ) P πθϕ ( C,τ ) =
D ϕ
( C ) D ϕ ( C ) is the IS weight corresponding to the sample distribution ( C, τ ) ∼ P π θ ϕ .
The optimization problem in Equation (5) often reduces to a simple closed-form calculation: if D ϕ is a Gaussian, for example, ϕ ∗ reduces to the weighted expectation and variance of { C | R ( τ ) ≤ q α } C,τ ∼ P πθϕ with the IS weights w ( C, τ ) .
Equation (5) may produce noisy results when estimated from data { ( C i , τ i ) }
Ni =1 , unless N ≫ α − 1 , since only αN trajectory-samples satisfy R ( τ ) ≤ q α and are used in the estimation.
To address this, the CEM reaches the α -tail gradually over iterations.
Every iteration, it samples a batch of contexts { C i } Ni =1 from the current distribution D ϕ , and then solves Equation (5) with respect to a higher quantile q ≥
q α .
More specifically, denote by ˆ q ϕα the estimated α -quantile of { R ( τ ) } C,τ ∼ P πθϕ ; then, we set q = max(ˆ q ϕ
α , ˆ q ϕβ ) with a hyperparameter β > α (often β = 0 . 2 ).
Since the data is drawn from P π θ ϕ , this guarantees at least βN samples per update step.
The quantile ˆ q ϕ
α corresponds to the α -tail of the original context-distribution, and can be viewed as a stopping condition: once
ˆ q ϕ
α > ˆ q ϕβ , many of our samples are already in the tail, and β is no longer needed to smooth the update of ϕ .
Dynamic-target CEM :
The standard CEM assumes to search for the tail of a constant distribution.
In our setting, however, we look for the tail of the distribution of the returns R ( τ ) , where C, τ ∼ P π θ ϕdepend on π θ and thus are non-stationary throughout the training.
The non-stationarity poses several challenges for the CEM.
First, the stopping condition ˆ q ϕ
α varies with π θ and has to be re-estimated every iteration 1 .
Second, the high-risk contexts C (which correspond to the lowest returns) may vary as the agent evolves; and if the CEM learns to only sample a strict subset of the context space, then it may miss such changes in the high-risk contexts.
We address both issues using reference samples: every iteration, we sample two batches of contexts – { C ϕ,i } N s i =1 from the current context distribution D ϕ and { C o,i } N o i =1 from the original distribution D ϕ 0 .
The reference contexts provide an important regularization: they guarantee continual exposure to the whole context space, in case that the high-risk contexts vary.
In addition, the reference samples were empirically found to stabilize the estimation of ˆ q ϕ
α
(Line 11 in Algorithm 1).
Consider the two batches of context-trajectory pairs, and denote the estimated return quantile ˆ q α =
ˆ q α ( { R ( τ i ) } N o i =1 ) .
We can estimate the CVaR policy gradient, using the notation ∀ 1 ≤ i ≤ N o + N s :
C i = (cid:26) C
o,
i if 1 ≤ i ≤ N o
C ϕ,i − N o if N o + 1 ≤ i ≤ N o + N s , by
[Equation] [Equation]
6) where w i = 1 for 1 ≤ i ≤ N o and w i = D ϕ
( C i ) /D
ϕ ∗ ( C i ) for N o + 1 ≤ i ≤ N o + N s .
Note that if the policy learning scale is slower than that of ϕ , the target context distribution P π θ ϕ 0 ,α is effectively stationary in the ϕ -optimization problem.
In that case, according to de Mello and
Rubinstein [2003], the CEM will converge to the KL-divergence minimizer ϕ ∗ of (5).
Sample efficiency in practice : Proposition 1 guarantees an α − 1 -increase in sample efficiency when using an accurate quantile estimate ˆ q α = q
α
( R | π θ ) and sampling exactly from P π θ ϕ 0 ,α .
The latter condition is equivalent to the CE-sampler reaching its objective D KL ( P π θ ϕ 0 ,α || P π θ ϕ )
= 0 .
In practice,
P π θ ϕ 0 ,α can only be approximated, and the sample efficiency is increased – but by a smaller factor than α − 1 .
Appendix D.3 demonstrates the increased sample size exploited by CeSoR in our experiments.
If ˆ q α ̸ = q α
( R | π θ ) , the quantile estimation error may theoretically lead to unbounded IS weights (see
Appendix B).
Practically, we address this by clipping the weights (as mentioned in Section 5), and by constraining the family of permitted distributions { D ϕ } ϕ to have a constant support independently of ϕ .
A side-effect is a function approximation error of the family { D ϕ } ϕ , as D ϕ ∗ ( C ) P π θ C ( τ ) cannot replicate the tail distribution P π θ ϕ 0 ,α ( C, τ ) to achieve the full α − 1 -increase in sample efficiency.
Another limitation in the expressiveness of P π θ ϕ
( C, τ ) =
D ϕ ( C ) P π θ C ( τ ) occurs when the context C only controls part of the environment randomness in P π θ C ( τ ) .
As an extreme example in the Guarded
Maze, after π θ already learns to avoid the short path, the context (guard cost) does not affect the outcome at all anymore.
Indeed, Figure 10a in the appendix shows that high guard costs are sampled in the beginning; then, once the short path is avoided, the sampler gradually falls back to the original context distribution.
Note that in this example, the invariance to C began after the learning was essentially done, hence the CEM did play its part effectively.
Finally, note that the soft risk creates an intentional bias in the gradient estimate (to overcome the blindness to success).
As a result, in the first phase of training ( α ′ ≫ α ), only a few trajectories are overlooked every iteration.
As α ′ approaches α , the number of overlooked trajectories increases, and so is the importance of over-sampling the tail.
In the final steady-state phase ( α ′ = α ), the sample inefficiency is most severe, the soft risk produces no further biases, and the CEM helps CeSoR to reduce the high variance in the policy gradient estimation.
The harmony between the soft risk and the CEM : Soft risk has the inherent side effect of reducing the risk aversion.
In the Guarded Maze, for example, as demonstrated in Section 5.1, soft risk alone leads to learning the short path (instead of the risk-averse long path).
Fortunately, the CEM reduces this side effect.
In that sense, the two mechanisms complement each other:
α ′ >
α allows the optimizer to learn policies with high returns, while the CE sampler still preserves the risk aversion – as illustrated in Figure 3.
This connection stands in addition to the independent motivations of the two mechanisms, as discussed above.
Baseline optimizer : CeSoR can be implemented on top of any CVaR-PG method as a baseline (Line 15).
We use the standard GCVaR [Tamar et al., 2015b], which guarantees asymptotic convergence under certain regularity conditions.
Appendix C shows that these guarantees hold for CeSoR as well, when implemented on top of GCVaR. Other CVaR-PG baselines can also be used, such as the
TRPO-based algorithm of Rajeswaran et al.
However, such methods often include heuristics that introduce additional gradient estimation bias (to reduce variance), and thus do not necessarily guarantee the same theoretical convergence.
Experiments
We conduct experiments in 3 different domains.
We implement CeSoR on top of a standard CVaR-PG method, which is also used as a risk-averse baseline for comparison.
Specifically, we use the standard
GCVaR baseline [Tamar et al., 2015b], which guarantees convenient convergence properties (see
Appendix C)
and is simple to implement and analyze.
We also use the standard policy gradient ( PG ) as a risk-neutral baseline.
We stress that the comparison to PG is only intended to present the mean-CVaR tradeoff, while each method legitimately optimizes its own objective.
Appendix H also compares CeSoR to risk-neutral and risk-averse Distributional RL algorithms.
In all the experiments, all agents are trained using Adam [Diederik P. Kingma, 2014], with a learning rate selected manually per benchmark and N = 400 episodes per training step.
Every 10 steps we run validation episodes, and we choose the final policy according to the best validation score (best mean for PG, best CVaR for GCVaR and CeSoR).
For CeSoR, unless specified otherwise, ν = 20% of the trajectories per batch are drawn from the original distribution D ϕ 0 ; β = 20% are used for the
CE update; and the soft risk level reaches α after ρ = 80% of the training.
As mentioned in Section 4, for numerical stability, we also clip the IS weights (Algorithm 1, Line 9) to the range [1 / 5 , 5] .
Every policy is modeled as a neural network with tanh activation on its middle layers and softmax operator on its output, with temperature 1 in training (i.e., network outputs are actions probabilities), and 0 in validation and test (i.e., the max output is the selected action).
We use a middle layer withneurons in Section 5.2, 16 neurons in Section 5.3, and no middle layer (linear model) in Section 5.1.
In each of the 3 domains, the experiments required a running time of a few hours on an Ubuntu machine with eight i9-10900X CPU cores.
In addition to these RL-related experiments, Appendix D presents dedicated experiments for the independent CE module.
5.1 The Guarded Maze
Benchmark: The Guarded Maze benchmark is defined in Section 1.
For the experiments, we set a target risk level of α = 0 . 05 , and train each agent for n = 250 steps with the parameters described above.
The CEM controls C through ϕ =
( ϕ 1 , ϕ 2 ) , where ϕ 0 =
(0 . 2 , 32) as mentioned above, and updates ϕ 1 , ϕ 2 using the weighted means of Cand C 2 , respectively.
As an ablation test, we add two partial variants of our CeSoR: CeR (with CE, without α -scheduling) and SoR (with scheduling, without CE).
See more details in Appendix E.1.
Results: Figure 1a summarizes the test scores, and
Figure 1d illustrates a sample episode.
PG learned the short path, maximizing the average but at the cost of poor returns whenever charged by the guard.
CeSoR, on the other hand, successfully learned to follow the CVaR-optimal long path.
GCVaR, which also aimed to maximize the CVaR, failed to do so.
As analyzed in Figure 4, throughout GCVaR training, the agent takes the long path in up to 50% of the episodes per batch, but none of these episodes is ever included in the bottom α = 5% that are fed to the optimizer.
Thus, GCVaR is entirely blind to the successful episodes and fails to learn the corresponding strategy.
In fact, in most training steps, all the worst episodes of GCVaR reach neither the guard nor the target, leading to a constant return of − 32 , a tail barrier, and a zero loss-gradient.
CeR suffers from blindness to success just as GCVaR. SoR is exposed to the successful long-path episodes thanks to soft risk scheduling; however, due to the reduced risk-aversion, it fails to prefer the long path over the short one.
Only CeSoR both observes the "good" strategy (thanks to soft risk scheduling) and judges it under "bad" environment variations (thanks to the CEM).
Appendix E. presents a detailed analysis of the learning dynamics, the blindness to success and the learned policies.
It is important to notice that standard optimization tweaks cannot bring GCVaR to learn the long path: a "warm-start" from a standard PG only encourages the short-path policy (as in SoR); and increased batch size N does not expose the optimizer to the long path (see Theorem 1).
5.2 The Driving Game
Benchmark: The Driving Game is based on an inverse-RL benchmark used by Majumdar et al.
[2017] and Singh et al.
The agent’s car has to follow the leader (an "erratic driver") for 30 seconds as closely as possible without colliding.
Every 1.5 seconds (i.e., 20 times per episode), the leader chooses a random action (independently of the agent): drive straight, accelerate, decelerate, change lane, or brake hard ("emergency brake"), with respective probabilities ϕ
= (0 . 35 , 0 . 3 , 0 .
We denote the sequence of leader actions by C ∈ { 1 , ..., 5 } 20 .
Every 0.5 seconds (60 times per episode), the agent observes its relative position and velocity to the leader, with a delay of 0.7 seconds (representing reaction time), as well as
We set α = 0 .
01 , and train each agent for n = 500 steps.
To initiate learning, for each agent we begin with shorter training episodes of 6 seconds and gradually increase their length.
The CEM controls the leader’s behavior through the probabilities ϕ
= { ϕ i } 5 i =1 described above.
[Figure]
Results: Figure 1b summarizes the test scores of the agents, where CeSoR presents a reduction of 28% in the
CVaR cost in comparison to the baselines.
GCVaR completely fails to learn a reasonable policy – losing in terms of CVaR even to the risk-neutral PG.
Figure 5 shows that
CeSoR learned an arguably-intuitive policy for risk averse driving: it keeps a safer distance from the leader, and uses the gas and the brake less frequently.
This results in complete avoidance of the rare accidents occurring to PG, as demonstrated in Figure 1e.
In Appendix D, we also see that by over-sampling turns and emergency brakes of the leader, the CEM manages to align the mean return of the training samples with the 1%-CVaR of the environment, and significantly increases the data efficiency.
5.3 The Computational Resource Allocation Problem
Benchmark: Computational resource allocation in serving systems, and in particular the tradeoff between resource cost and serving latency, is an important challenge to both academia [Jiang et al., 2013, Tessler et al., 2022] and industry [Barr, 2018, Lunden, 2022].
In popular applications such as E-commerce and news, latency is most critical at times of peak loads [Garces, 2019], making
CVaR a natural metric for risk-averse optimization.
In our benchmark, the agent allocates servers to handle user requests, managing the tradeoff between servers cost and time-to-service (TTS).
Requests arrive randomly with a constant rate, up to rare events that cause sudden peak loads, whose frequency is controlled by the CE sampler.
See Appendix G for more details.
Results: As shown in Figure 1c, CeSoR significantly improves the CVaR return, and does not compromise the mean as much as GCVaR. As demonstrated in Figure 1f, CeSoR learned to allocate a default of 5 servers and react to peak loads as needed, whereas GCVaR simply allocates 8 servers at all times.
PG only allocates 4 servers by default, and thus its TTS is more sensitive to peak loads.
Appendix G describes the complete implementation and detailed results, discusses the poor parameterization of D ϕ in this problem and shows the robustness of CeSoR to that parameterization.
Summary and Future Work
We introduced CeSoR, a novel method for risk-averse RL, focused on efficient sampling and soft risk.
In a variety of experimental domains, in comparison to a risk-averse baseline, CeSoR demonstrated higher CVaR metric, better sample-efficiency, and elimination of blindness to success – where the latter two were also analyzed theoretically.
There are certain limitations to CeSoR. First, we assume to have at least partial control over the training conditions, through a parametric family of distributions that needs to be selected.
Second,
CeSoR can be applied robustly on top of any CVaR-PG method, but is currently not applicable to non-PG methods.
Since the limitations of CVaR-PG apply in other risk-averse methods as well (as we demonstrated for Distributional RL), future work may adjust CeSoR to such methods, as well as to other risk measures.
Third, in terms of blindness to success and estimation variance, CeSoR shows both theoretical and empirical improvement – but is not proven optimal.
Future work may look for optimal design of CEM or risk scheduling.
Considering the current results and the potential extensions, we believe CeSoR may open the door for more practical applications of risk-averse RL.
Acknowledgements: This research was supported by the Israel Science Foundation (grant 2199/20).
A Blindness to Success: Proof of Theorem
Theorem 1 considers the probabilistic event of a global blindness to success over n consecutive training steps.
We begin with a local blindness in a single training step.
Lemma 1 (Local blindness to success) .
Let a risk level α ∈ (0 , 1) and a CVaR-PG training step m ≥ 1 , and let β ∈
( α, 1) .
Denote A = (cid:110) { τ m,i } Ni =1 ∈ T N (cid:12)(cid:12) q π m β
[Equation]
( { R (
[Equation]
m,i ) } Ni =1 ) (cid:111) .
Then,
[Equation]
Proof.
Denote R i
=
R ( τ m,i ) , χ qi = 111 R i >q , and χ i =
χ q πmβ i .
Note that χ
i ∼ Bernoulli (1 − β ) .
Also denote the percent of high-return trajectories by n q = (cid:80) Ni =1 χ qi /N and n ∗ = n q πβ .
Since ˆ q α ( { R i } Ni =1 ) = min (cid:110)
q | |{ i | R i ≤ q }| N ≥ α (cid:111) =
min (cid:110) q | |{ i | R i >q }| N < 1 − α (cid:111) =
min (cid:110) q | 1 N (cid:80) Ni
=1 χ qi < 1 − α (cid:111) , we have q πβ < ˆ q α ( { R i } )
⇔ n ∗ ≥ 1 − α , i.e., A = ( n ∗ ≥ 1 − α ) .
Since P (0 ≤ χ i ≤ 1) = 1 , E
[ χ i ] =
1 − β and the Bernoulli χ i are sub-Gaussian with variance factor σ 2 = 1 / 4 , by Hoeffding inequality [Hoeffding, 1994]
we obtain
P ( A ) = P ( n ∗ ≥ 1 − α ) =
P ( n ∗ − E [ n ∗ ] ≥ β − α
[Equation]
Note that Lemma 1 does not depend on a tail-barrier: it simply implies that since a CVaR-PG algorithm focuses on the worst α trajectories in every batch, we do not expect trajectories with high returns R ( τ m,i ) >
q π m β to be fed to the optimizer.
Still, in general, even if high-return trajectories are ignored, the CVaR-PG can learn to avoid low-return trajectories with R ( τ m,i ) <
q π m β .
The tail barrier prevents this learning, since there are no returns strictly lower than q π m β – all the tail identically equals q π m β .
Since there are no worse trajectories to learn from, and better trajectories are ignored, this brings the training to a deadlock, as stated by Theorem 1.
Proof of Theorem 1 (stated in Section 3.1).
All probabilities below are conditioned on the event of π m 0 having a β -tail barrier.
Thus, we simplify the notation to P ( · ) =
P (cid:0) · (cid:12)(cid:12) π m 0 has β -tail barrier (cid:1) .
Denote by S =
(cid:110)(cid:16) { τ m,i } Ni =1 , π m (cid:17)(cid:111) m
+ n − 1 m = m ∈ ( T N × Π) n the sequence of trajectory batches and policies, and by R m = { R ( τ m,i ) }
Ni =1 the returns on step m .
Also denote for simplicity B = B m 0 ,n α,β .
We are interested in the probability of the event that there is no global blindness (Definition 2):
[Equation]
Define the event of blindness at step m , along with an unchanged policy:
A m = (cid:110)
S
[Equation]
R m
[Equation]
(cid:111) .
Note that (cid:84) m 0 + n − 1 m = m
A m ⊆ B , hence
P ( ¬B
[Equation]
≤ 1 − P (cid:32)
[Equation]
(cid:92) m = m
A m (cid:33) = 1 − m 0 + n − 1 (cid:89) m
[Equation]
m
P ( A m | A m 0 , ..., A m − 1 ) .
Thus, to complete the proof, we show below that P ( A m | A m 0 , ..., A m − 1 ) ≥ 1 − δ , where δ = e − 2 N ( β − α ) 2 , hence P ( ¬B ) ≤ 1 − (1 − δ ) n ≤ 1 − (1 − nδ )
= nδ .
For m = m 0 , we have immediately π m = π m 0 , and from Lemma 1 P ( q π m 0 β <
ˆ q α ( R m 0 ))
≤ δ .
For m 0 + 1 ≤ m ≤ m 0 + n − 1 , assume that A m 0 , ..., A m − 1 hold.
In particular, ˆ q α ( R m − 1 ) ≤ q π m 0 β , π m − 1 =
π m 0 and π m − 1 has a β -tail barrier.
Now consider the m − 1 training batch: for every trajectory 1 ≤ i ≤ N , if R m − 1 ,i >
ˆ q α ( R m − 1 ) , then 111 R m − 1 ,i ≤ ˆ q α
( R m − 1 ) = 0 ; otherwise,
R m − 1 ,i ≤ ˆ q α ( R m − 1 ) ≤ q π m 0 β , that is, R m − 1 ,i =
q π m 0 β ′ for some β ′ ≤ β , and by the barrier property
R m − 1 ,i =
q π m 0 β
and thus R m − 1 ,i − ˆ q α
( R m − 1 ) = 0 .
Hence, the gradient in Equation (3) is 0, the policy update vanishes, and we obtain π m =
π m − 1 = π m 0 .
Then again, according to Lemma 1 (and since R m and R m 0 are drawn from the same distribution corresponding to π m = π m 0 ), we have P ( q π m 0 β < ˆ
q
α
( R m ))
=
P ( q π m
β
< ˆ q α ( R m 0 ))
≤ δ , as required.
Note that the factor n may become quite negligible when the barrier is wider than α : if n = 10 6 , α = 0 .
05 , β = 0 .
25 , N = 400 , for example, we still have P ( ¬B m 0 ,n α,β ) < 10 − 7 .
Indeed, the blindness occurs with significantly smaller barriers than the β = 0 .
9 demonstrated in the Guarded Maze in Appendix E.2.
Note that the momentum term of the Adam algorithm
[Diederik P. Kingma, 2014], while preventing the policy update from completely vanishing, was empirically insufficient to overcome the barrier in the Guarded Maze.
This should not come as a surprise, since the momentum comes from previous gradients that encouraged the strategies of the barrier and brought them into the tail in the first place.
B Variance Reduction: Proof of Proposition
Proof.
Define H ( C, τ ) =
α − 1 111 R ( τ ) ≤ ˆ q α
( R ( τ ) − ˆ q α ) ∇ θ (cid:80) t log π θ ( a t ; s t ) , such that the CVaR
PG can be written as ∇ θ ˆ J α (cid:0) { C i , τ i } Ni =1 ; π θ (cid:1)
= 1 N (cid:80) Ni =1 w ( C i , τ i ) H
( C i , τ i ) , where w ( C, τ ) =
P πθϕ
( C,τ )
P πθϕ 0 ,α ( C,τ ) is the IS weighting that accounts for the modified sample distribution.
Since C, τ ∼ P π θ ϕ 0 ,α , we have R ( τ ) ≤ q α
( R | π θ ) almost surely; and along with the assumption ˆ q α =
q
α
( R | π θ ) , we obtain w ( C,
[Equation]
[Equation]
The assumption ˆ q α =
q
α
( R | π θ ) , when applied to Equation (3), also guarantees that ∇ θ ˆ J α is an unbiased gradient estimator for both sample distributions P =
P π θ ϕ 0 and P =
P π θ ϕ 0 ,α : E C i ,τ i ∼ P [ ∇ θ ˆ J α (cid:0) { C i , τ i } Ni =1 ; π θ (cid:1) ]
= ∇ θ J α
( π θ ) .
Its variance over N i.i.d samples is
Var C i ,τ i ∼ P [ ∇ θ ˆ J α (cid:0) { C i , τ i } Ni =1 ; π θ (cid:1) ]
= 1 N Var C,τ ∼ P [ ∇ θ ˆ J α
( C, τ ; π θ )] .
Denoting g := ∇ θ J α ( π θ ) , we obtain:
[Equation]
which completes the proof.
Note that if ˆ q α ̸ =
q α ( R | π θ ) , the term 111 R ( τ ) ≤ ˆ q α in the denominator may vanish and the IS weight w ( τ, C ) may become unbounded.
To overcome this issue when using our CE-sampler (described in Section 4), we constrain the family of distributions { P π θ ϕ } ϕ such that the sample distribution
P π θ ϕ always has the same support as the original distribution P π θ ϕ 0 (even though this eliminates the possibility of an exact tail sampling P π θ ϕ
=
P π θ ϕ 0 ,α ).
In addition, in the experiments of Section 5 we clip the IS weights directly.
C Gradient Estimation Bias and CeSoR Convergence
The gradient estimator of Equation (3) is biased due to the biasedness of the empirical quantile.
However, Tamar et al.
[2015b] show that the gradient estimator is still consistent, and bound its bias by O ( N − 1 / 2 ) .
Lemma 2 below proves that a similar result holds for CeSoR – despite the CEM and the risk scheduling.
Given Lemma 2, CeSoR’s convergence is a direct application of Theorem 5 in
Tamar et al.
[2015b], as stated below.
The soft-risk scheduling α ′ introduces additional transient bias to the CVaR gradient estimate when α ′ >
α , but this bias vanishes in the last steady-state 1 − ρ steps when α ′ =
α ; hence, we can safely assume consistency of CeSoR’s gradient estimate, and focus our asymptotic convergence analysis on the steady-state phase.
Formally, in terms of Section 2, assume that the update step includes a ℓ p projection Γ to a compact set with a smooth boundary: θ m +
=
Γ( θ m + η m ∇ θ ˆ J α ) ; and that the learning rate η m satisfies (cid:80) ∞ m =
η m = ∞ , (cid:80) ∞
m =
η 2 m < ∞ and (cid:80) ∞ m =
η m (cid:12)(cid:12)(cid:12) E (cid:104) ∇ θ ˆ J α (cid:105) − ∇ θ J α (cid:12)(cid:12)(cid:12) < ∞ w.p. 1.
In addition, denote by K the set of all asymptotically-stable equilibria of the ODE ˙ θ = Γ( ∇ θ J α
( R ; π θ )) .
Theorem 2 (Convergence of CeSoR) .
Assume that for any ϕ , the sample distribution D ϕ of Algorithm 1 has the same support as the original distribution D ϕ 0 .
Then, under the smoothness assumptions specified in Appendix C.1, and the projection and learning rate assumptions specified above, the sequence of policy parameters { θ m } generated by Algorithm 1 converges almost surely to K .
Theorem 2 relies on similar assumptions to Tamar et al.
[2015b], two of them are of particular interest in our context.
First, the rewards are assumed to be continuous.
Second, in the gradient estimator, the baseline is assumed to be a consistent estimator of the returns α -quantile.
Hence, while CeSoR is compatible with any CVaR-PG method, the current derivation of theoretical convergence guarantees only holds for PG methods with a consistent gradient estimate.
C.1 Gradient Estimation Bias
The gradient estimator of the standard CVaR PG may be inconsistent and unboundedly-biased, unless the return baseline is a consistent estimator of the α -quantile of the returns [Tamar et al., 2015b].
Thus, we rely on the empirical quantile baseline ˆ q α used in Equation (3), which is a consistent (though biased) estimator of the true quantile.
Given certain smoothness assumptions, Tamar et al.
[2015b] bound the resulted bias of the gradient estimator E (cid:104) ∇ θ ˆ J α (cid:105) − ∇ θ J α (as defined in Equations (2),(3)).
Lemma 2 guarantees that under the same assumptions, despite the modified sampling by the CEM, the same bias bounds apply to CeSoR.
We first specify the smoothness assumptions.
Note that Tamar et al.
[2015b] consider ∇ θ log f s |
a ( s | a, θ ) in their calculations (or in their notation: ∇ θ log f X | Y ( X | Y, θ ) ).
In RL applications, given the action a , the next-state distribution is independent of the policy π θ , and this gradient vanishes.
We accordingly ignore this term in the calculations, which simplifies the assumptions and the analysis.
The remaining assumptions mostly consider the smoothness of the rewards, and in particular do not hold in the case of discrete rewards as discussed in Section A.
Assumption 1 (Smoothness assumptions) .
For any policy π θ , the return R is a continuous random variable; and ∇ θ q α ( R ; π θ ) , ∇ θ J α ( π θ ) and ∇ θ log π θ ( a ) (for any a ) are well defined and bounded.
Lemma 2 (Gradient estimation bias bound) .
In Algorithm 1 with a batch size N , consider a certain step m ≥ ρM , and assume that the underlying PG follows Equation (3) (or Equation (6)).
In addition, assume that for any ϕ , the sample distribution D ϕ of Algorithm 1 has the same support as the original distribution D ϕ 0 .
Then, under Assumption 1, E (cid:104) ∇ θ ˆ J α (cid:105) − ∇ θ J α
= O
( N − 1 / 2 ) .
Proof.
We follow the steps of the proof of Theorem 4 in Tamar et al.
[2015b] with the following modifications.
First, we take the gradient expectations with respect to the CE sampling distribution
D ϕ rather than the original distribution D ϕ 0 .
Second, the empirical quantile ˆ q α is calculated in
Algorithm 1 using a reduced sample size N o =
⌊ νN ⌋ < N .
Note that the estimator ˆ q α relies on samples drawn from D ϕ 0 , hence is not otherwise affected by the CEM.
Denote by D ϕ i the distribution from which was drawn C i , i.e., ϕ i = ϕ 0 for i ≤ N o
and ϕ i = ϕ
for i > N o .
Since m ≥ νN , according to Line 13 in Algorithm 1 we have α ′ =
α .
Denoting by q α the true α -quantile of the returns, we have
[Equation]
We now substitute w i = D ϕ
( C i )
D ϕi ( C i ) , which is finite due to the assumption that D ϕ i has the same support as D ϕ 0 .
Using the notation E ϕ 0 [ · ] =
E C ∼ D ϕ 0 ,τ ∼ P πθC [ · ] and π θ ( τ i ) =
Π t π θ ( a i,t ; s i,t ) , we obtain (cid:12)(cid:12)(cid:12)
[Equation]
i
[Equation]
From this point, the proof is mostly identical to Theorem 4 in Tamar et al.
[2015b].
Namely, the first term is o ( N − 1 / 2 ) according to Hong and Liu [2009], given Assumption 1; and since ˆ q α is estimated using νN samples, we have | q α − ˆ q α | =
O (( νN ) − 1 / 2 ) =
O ( N − 1 / 2 ) in probability (note that ν is constant, e.g., ν = 0 .
2 or ν = 0 .
5 in the experiments of Section 5).
Together, the whole expression is
O ( N − 1 / 2 ) as required.
D The Cross Entropy Module: Extended Discussion
The Cross Entropy Method (CEM) with non-stationary score function has a major role in CeSoR.
The CEM code is implemented and available as an independent module [Greenberg, 2022].
Below we present an analysis of the CEM empirical results over both a dedicated toy problem (which tests the CEM independently of CeSoR) and as part of CeSoR in the benchmarks of Section 5.
D.1 The CEM Algorithm
For clarity, we first provide the pseudo-code for the general CEM algorithm.
This version repeatedly generates samples from the tail of the distribution D ϕ 0 .
A similar version [de Boer et al., 2005] would stop once q β (cid:0) { R ( x i ) } N i =1 (cid:1) ≤ q (as it means that at least βN samples are already beyond q ), and use all the recent samples R ( x i ) ≤ q to estimate the probability of the “rare event” R ( X ) ≤ q .
Note that unlike CeSoR, Algorithm 2 relies on a constant mapping R ( x ) and a constant target q .
Our CEM version in CeSoR, as implemented in our code and presented in Algorithm 1, supports a quantile-target α with respect to a return mapping R that varies dynamically with the learning agent.
do //
Sample
Sample x ∼ D Nϕ w i ← D ϕ
( x i ) /D
ϕ
( x i ) (1 ≤ i ≤ N )
Print x // Update q ′ ← max (cid:0) q, q β (cid:0) { R ( x i ) } Ni =1 (cid:1)(cid:1)
ϕ ← argmax ϕ ′ (cid:80) Ni
=1 w i 111 R
( x i ) ≤
q ′ log D ϕ ′ ( x i )
D.2 Sample Distribution
The goal of the CEM is to align the sample distribution with the bottom-
α percent of the reference distribution.
Note that given a parametric family of distributions D ϕ with a limited expressiveness, a perfect alignment is not always possible.
For example, if the CEM controls the mean of an exponential distribution C ∼ Exp ( ϕ ) , and the returns decrease with c , then the lower quantiles of the returns correspond to C ≥
q α ( C ) .
However, no value of ϕ could eliminate the lower values
C ∈ [0 , q α ] – but could merely assign more probability density to higher values.
Even when the family of distributions is expressive enough, the CEM has to learn the desired sample distribution without any prior knowledge about the meaning of the parameters that it controls.
In particular, it cannot know in advance in which direction each parameter may affect the agent return, what the size of the effect would be, and how it would change during the training.
Formally, the objective of the CEM is often defined as minimization of the KL-divergence between the sample distribution and the desired tail of the reference distribution [Dambreville, 2006].
Indeed, this objective is well-defined even if the expressiveness of D ϕ does not allow a perfect alignment.
In this section, we focus on the comparison between the mean and the CVaR of the sample distribution and the reference distribution of the returns.
Specifically, while both distributions begin with the same mean and CVaR, we hope that the sample mean would align with the reference CVaR as quickly as possible.
First, we consider a toy problem with a static reference distribution and no RL environment.
The parametric family of distributions is C ∼ Beta (2 ϕ, 2 − 2 ϕ ) (such that E [ C ] = ϕ ), and the reference distribution corresponds to ϕ 0 = 0 . 5 , which results in the uniform distribution Beta (1 , 1) =
U (0 , 1) .
We are interested in the bottom α = 10% of the reference distribution, i.e., U (0 , 0 . 1) .
We run the
CEM for n = 10 steps with N = 1000 samples per step, ν = 20% of them are drawn from the original reference distribution, and update ϕ using the mean of the lower β = 50% samples.
Note that generally in this work, C is the context or configuration of an environment that produces returns; in this toy example, we do not have an RL environment and we simply define R ( C )
=
C .
The CV aR 10% of C (or equivalently, the mean of U (0 , 0 . 1) ) is 0 .
Note that no value of ϕ can yield the distribution U (0 , 0 . 1) , as the support of the Beta distribution is always (0 , 1) .
Yet, as shown in Figure 6, the sample mean converges to the reference CVaR within mere 2 iterations, and remains around this level.
Figure 7 presents the same metrics for the experiments described in Section 5.
In these cases, the reference returns distribution corresponds to the agent returns under the original environment.
Note that this reference returns distribution is dynamic during the training, as it changes with the agent (and in certain benchmarks also with the episode length that increases throughout the training).
Yet, in the Driving Game benchmark, for example, we see that the sample mean reasonably aligns with the reference CVaR throughout most of the training, even as both of them vary.
[Figure]
In the Guarded Maze, the sample mean also quickly converges into the reference CVaR.
However, once the agent learns to avoid the short path, the CE sampler can no longer control the agent performance at all, and due to the regularizing reference samples, the sample distribution gradually goes back to the original one.
This is a valid behavior, as the agent already learned to avoid the risk, and if for some reason it came back to the risky short path, the CE would simply learn again to focus on the risky configurations of the environment.
The Servers Allocation Problem takes the challenge of the CEM to the limit, as the target is α = 1% , the difficulty to the agent arrives in a non-smooth manner as rare and discrete events, and the given family of distributions (Binomial) has limitations in expressing the desired distribution.
Specifically, we would like most of the sample episodes to include a peak event, but not more than one; whereas the Binomial distribution is not best-suitable for this.
However, even as the CEM struggles to fit the reference CV aR 1% (Figure 7c), CeSoR is still shown to provide beneficial results (Section 5.3,
Appendix G).
This demonstrates the robustness of CeSoR to limitations and misspecification of the modeled family of distributions.
Sensitivity to β : As discussed in Sections 2 and 4, the smoothness parameter β determines the minimal percent of data samples used for the update step in the CEM.
We argue that CeSoR has a low sensitivity to the parameter β .
Intuitively, every iteration of the CEM focuses on the β -tail of the previous iteration (until reaching the α -tail of the reference distribution).
Theoretical analysis of the convergence rate is challenging, due to the limited expressiveness of D ϕ and the non-stationary agent returns; yet, according to the qualitative intuition above, we expect exponential convergence to the tail, which applies even for high values of β .
On the other hand, while low values of β may increase the noise in the update step of the
CEM, any noisy update could be corrected throughout the training.
Note that Algorithm 1 uses the original context-distribution for a certain part of the samples of each batch; this guarantees that any update step is reversible, as CeSoR continues to be exposed to the complete context-space.
Empirically, we repeated the experiments of Section 5 with various values of β ∈ [0 . 05 , 0 . 3] .
In the
Guarded Maze and the Driving Game, all the values of β resulted in similar test returns; in addition,
Figure 8 shows that the CEM successfully aligned the sample mean return with the reference CVaR, independently of β .
The Servers Allocation Problem is more challenging for the CEM (as discussed above), making the sampler more sensitive to the parameter β , and in particular leading to a failure for β = 0 .
However, note that even under such a combination of poor algorithmic choices (Binomial parameterization of D ϕ and very high β ), the failure of the CEM is easy to notice through Figure 8c (as the sample-mean fails to deviate from the reference-mean), and is easy to fix.
[Figure]
D.3 Sample Efficiency
An important aspect of the CEM is its increase of sample efficiency (Section 3.2).
While the results in Section 5 already demonstrate that CeSoR learns better and faster than the standard GCVaR, here we measure the effective sample size directly.
While PG always uses the entire batch, and GCVaR always uses at most α of the episodes, Figure 9 shows that CeSoR manages to optimize CVaR α while using more than α percent of the data.
Note that even beyond the risk level scheduling (which ends after ρ = 80% of the training), the CEM still allows for more than α percent of each batch to be used.
Note that GCVaR effectively uses less than α episodes in a batch if multiple episodes { τ i } satisfy
R ( τ i ) =
q α – since the contribution of any such episode to the gradient in Equation (3) is 0 .
In the extreme case, as discussed in in Section 3.1 and Appendix E.2, all the worst α episodes are identical, and the whole loss gradient is identically 0 .
[Figure]
D.4 Risk Characterization
The CEM not only allows CeSoR to sample the most relevant environment conditions for CVaR optimization, but also allows us to characterize the conditions that correspond to the risk level α .
This enhances our understanding of the problem and may help us to anticipate poor returns in advance.
Figure 10 presents the evolution of the sample distribution parameters ϕ throughout the CeSoR training process in the various benchmarks.
In the Guarded Maze, for example, ϕ goes back to its original values once the agent behavior converges, which teaches us that a risk-averse agent can be entirely insensitive to the environment conditions.
In the Driving Game, on the other hand, the agent must still beware a leader that applies many turns and emergency brakes.
Furthermore, the CEM provides the connection between the risk level of interest ( α ) and the corresponding values of ϕ (e.g., how many turns and brakes it takes to bring us to this risk level).
[Figure]
E The Guarded Maze: Extended Discussion E.1 Implementation Details
In this section we specify the implementation details of the Guarded Maze.
The full code is available in the gym environment and the corresponding jupyter notebook.
The Guarded Maze benchmark: The benchmark introduces a maze of size 8 × 8 , with the walls marked in gray in Figure 1d.
The target is a 1 × 1 square marked in green.
Every episode, the initial agent location is drawn from a uniform distribution over the lower-left quarter of the maze.
Every time step, the agent can walk in one of the directions left, right, up and down, with a step size of 1 , and an additive normally-distributed noise with standard deviation of 0 . 2 in each dimension.
That is,
[Equation]
where s t , a t ∈ R 2 and ϵ i ∼ N (0 , 0 .
2 2 ) ( i ∈ { 1 , 2 } ) .
A step that ends in a wall is cancelled, and the agent remains in its place.
Every time-step, the agent observes its location s t .
In practice, we use a soft (continuous) one-hot encoding of the agent location in the maze, calculated as a 2D interpolation between the 4 nearest points of a 8 × 8 grid, represented as a corresponding 8 × 8 matrix.
That is, if the agent is located between the grid points ( i, j ) , ( i, j + 1) , ( i + 1 , j ) , ( i + 1 , j + 1) , then all the other elements of the matrix are set to 0 , and these 4 elements are assigned positive value that are summarized to 1 , according to the relative location of the agent between them.
Note that the locations of the target and the guarded zone are constant, and are not given as input.
An episode ends either when reaching the target or after 160 time-steps.
The rewards are specified in
Section 5.1.
The return of an episode is the sum of its rewards (i.e., no discount factor).
The maze is designed such that the mean -optimal strategy is taking the shortest path to the target, where the expected cost of crossing the guarded zone is E [ C 1 C 2 ] =
ϕ 1 ϕ 2 = 0 .
2 · 32 = 6 . 4 – smaller than the additional cost of the longer path.
The CV aR 0 .
05 -optimal strategy, however, is to take the longer path, since sometimes short cuts make long delays [Tolkien, 1954].
Algorithms implementation: The training algorithms are specified in Section 5.
In the maze benchmark, all of them are applied to a linear model that takes as an input the one-hot encoding described above ( ∈ R 64 ), and is followed by a softmax operator with temperature T .
That is,
P ( a j ; θ ) = exp ( Ty j ) / (cid:80) j ′ exp ( Ty j ′ ) (where 1 ≤ j ≤ 4 and y j is the corresponding output of the linear model F θ ).
We set a constant T = 1 over the whole training, and T =
(i.e., choosing the max-probability action) for validation and test episodes.
The CE module in CeR and CeSoR controls the parameters ϕ of the Bernoulli and the Exponential distributions.
Note that the module is aware of the original ("true") values of ϕ , but not of their semantic meaning in the maze (e.g., it is not aware that high values are "bad", or that they only affect the agent through the guarded zone).
The sample parameters update using the moments-method is as simple as ϕ ← ( mean ( C 1 ) , mean ( C 2 )) , calculated over the episodes selected by the CE (Line 12 in
Algorithm 1).
E.2 Detailed Results
Figure 11 shows the distribution of the trained agent returns over the test episodes in the Guarded
Maze (note that the left tail of this distribution is displayed in Figure 1a.
Figure 12 shows the mean and CVaR of the training and validation scores throughout the training process.
Below we elaborate on the training dynamics in general, and the blindness to success in particular.
Blindness to success: Section D.3 discusses the contribution of the CE sampling to the sample efficiency.
Here we discuss the contribution of soft risk level scheduling to the sample efficiency, and in particular its prevention of blindness to success .
[Figure]
As displayed in Figure 13a, for all the agents in the beginning of the optimization process, around 10% of the episodes in every batch reach the target through the long path.
At the same time, around 70% of the episodes reach the target through the short (and risky) path.
As a risk-averse algorithm,
GCVaR learns to avoid the short path, and the ratio of the long-path episodes increases accordingly – reaching up to 50% around the 15th batch (recall that in training episodes the actions are selected randomly according to the policy softmax output with temperature 1, which allows the agent to randomly reach the target).
Nonetheless, as shown in Figure 13b, in all of the train iterations, none of the long-path episodes belong to the bottom α = 5% episodes (which are fed to the optimizer), hence GCVaR never learns to prefer the long-path.
This demonstrates the blindness of GCVaR to the successful long path.
In fact, after around 10 training iterations of GCVaR, all the bottom α = 5% episodes in most batches already follow the stay-strategy (i.e., do not reach the target, nor take the guarded-zone risk), and achieve a constant return of − 32 (Figure 13c).
Note that according to Equation (3), this means that the loss gradient is identically 0 .
As shown in Figure 9a, the used sample size of GCVaR is indeedafter the 10th iteration, the effective sample efficiency is 0, and most of the changes in the agent from this point are attributed to the remaining Adam gradient momentum.
The soft risk level scheduling eliminates the blindness to success, and allows the optimizer to observe the long-path episodes (SoR in Figure 13b).
However, at the same time, it reduces the risk-aversion of the agent, and the long path is no longer preferred over the short path.
When the risk level reduces sufficiently, the agent may re-learn to avoid the short path, but the long path is no longer sampled at all and cannot be learned.
Only CeSoR manages both to observe the long-path episodes (thanks to soft risk level scheduling) and to prefer them over the short path (thanks to the risk-aversion induced by the CEM).
Examples and visualization: Figure 14 visualizes the policies learned by PG, GCVaR and CeSoR.
While the policies are defined over all the continuous state space, the visualization is restricted to a discrete grid.
Note that CeSoR and GCVaR behave similarly in the lower-left part of the maze, corresponding to guarded-zone avoidance; however, since GCVaR never observed the long path and learned its benefits, it fails to learn the CVaR-optimal strategy in the upper part of the maze.
[Figure]
Figure 15 shows a sample of test episodes for each of the trained agents.
Due to the reduced riskaversion of SoR (as discussed above), its best validation CVaR score was obtained early in the training, which may explain its non-smooth behavior in Figure 15.
F The Driving Game: Extended Discussion F.1 Implementation Details
In this section we specify the implementation details of the Driving Game.
The full code is available in the gym environment and the corresponding jupyter notebook.
Note that the leader behavior generation mechanism and the policy architecture are already specified in Section 5.
Observation space : the policy receives the following variables as inputs: relative position dx, dy , relative on-track velocity dvx , agent acceleration ax and agent direction θ .
Action space : the possible agent actions are (1) keep speed and steer; (2) accelerate; (3) decelerate; (4) steer left; (5) steer right.
The acceleration and deceleration magnitudes ( +4 m/s 2 , − 6 m/s 2 ) were determined according to the typical acceleration value described in Singh et al.
Rewards : we use the rewards defined in Singh et al.
[2018], with the parameters r 1 = 0 .
5 , r 2 = 0 .
05 , r 3 = 0 .
1 , r 4 = 0 .
5 , r 5 = 1 , r 6 = 0 .
These parameters determine the scale of the 6 additive rewards of Singh et al.
[2018], which correspond to staying behind the leader, staying close to the leader, keeping similar speed to the leader, keeping smooth agent acceleration, staying in the same lane as the leader, and staying on-road, respectively.
We also add a new additive reward of size 5 for any time-step with overlap between the agent and leader cars, meant to penalize collisions – which are not explicitly expressed in the original rewards.
F.2 Detailed Results
Figures 16-18 present a detailed analysis of the results of the Driving Game experiments.
[Figure] [Figure]
G The Computational Resource Allocation Problem: Extended Discussion G.1 Implementation Details
In this section we specify the implementation details of the Resource Allocation Problem presented in Section 5.3.
The full code is available in the gym environment and the corresponding jupyter notebook.
The benchmark simulates one-hour episodes, where user-requests arrive randomly and the agent is responsible to allocate sufficiently many servers to handle them.
Once a request is attended, its service time is distributed exponentially with an average of 1 second.
Every second t , the number of arrivals is distributed ∼
Exp ( λ t ) , where the arrival rate λ t is itself an exponential moving average (EMA) of the (unknown) users interest r t , with a typical decay of 5 minutes (i e., λ t = 2995 · 60 λ t − 1 + 15 · 60 r t ).
r t = 3 is usually constant but an unpredictable event causes a peak load every second with probability ϕ
= 1 3 · 24 · 3600 , i.e., every 3 days (or 72 episodes) on average.
In case of a peak load we set the momentary user interest to r t = 3 · 300 , which means that the arrival rate doubles immediately to λ t = 299300 λ t − 1 + 1300 r t = 299300 3 + 1300 3 · 300 ≈ 6 , and then starts decreasing exponentially back to 3, with a typical decay of 5 minutes.
Every minute, the agent observes the number of active servers 3 ≤ n s ≤ 10 (initialized every episode to n s = 4 ) and the number of pending user-requests in the system, and may choose to add or remove one server (or to keep the number of servers as before).
Uploading a new server takes a 2-minute delay before the server is ready to handle requests.
Removing a busy server takes effect once the server ends its current task.
Note that the servers form an ordered list, and only the last server in the list can be directly removed.
This constraint has little significance, since (1) the queue of pending requests is a global FIFO queue (i.e., the assignment only happens when a server becomes available – there is no separate queue per server); (2) the requests serving time is exponentially distributed, i.e., the remaining time of the current task is independent of the task history and thus is identical for all the busy servers at any point of time.
Denoting by tts i the Time-To-Service (TTS) latency of a request, the agent return is
[Equation]
requests
[Equation]
Once a request is assigned to a server, its serving time ∼ Exp (1) is independent of the agent decisions.
Thus, to simplify computations and to reduce the noise, we measure the TTS of a request only as the waiting time between arrival and beginning of serving.
We set a target risk level of α = 0 . 01 , and train each agent for n = 100 steps.
During the training, we gradually increase the episodes length L from 15 to 60 seconds.
The CEM controls the peak events frequency ϕ , or equivalently, the number of peaks per episode (which is distributed ∼ Binom ( ϕ, L ) ).
The update function of ϕ is simply the (weighted) average number of peaks per selected episode, divided by the episode length.
ν = 50% of the episodes per batch are drawn from the original distribution D ϕ 0 .
Note that at times of no peak-loads, the arrival rate is λ = 3 and the service rate equals the number of servers n s (since the service takes 1 second on average).
Thus, in terms of queueing theory, any number of servers n s ≥ 4 guarantees that the expected number of requests in the system is
E [ n r ] = 3 / ( n s − 3) ≤ 3 .
In particular, this means that the policy learned by PG (see Section 5.3) chooses the minimal number of servers n s = 4 that can handle no-peak demand, and adds resources only when required.
The agent policy receives a 9-dimensional vector as an input.
The first 8 elements correspond to a one-hot encoding of the current number of paid servers 3 ≤ n s ≤ 10 (including new servers that are not finished uploading yet).
The last element corresponds to the current number of pending user requests in the queue, divided by 10 r = 30 (the average number of arriving requests in 10 seconds of no peak-load).
G.2 Detailed Results
Figure 1c summarizes the test scores of the agents, where CeSoR presents a reduction of 44% and 17% in the CVaR cost in comparison to PG and GCVaR, respectively.
In addition, its average cost is only 7% higher than PG, and 33% lower than GCVaR.
That is, CeSoR significantly improves the CVaR return without as a large compromise to the mean as in GCVaR. CeSoR also outperforms GCVaR in episodes both with and without peak events, as shown in Figure 20b below.
As demonstrated in Figure 1f and summarized in Figure 22, PG and CeSoR learned to allocate a default of 4 andservers, respectively, and to react to peak loads as needed; whereas GCVaR simply allocates 8 servers at all times.
Note that the CE task – sampling the bottom α = 1% – is particularly challenging in this problem, due to the combination of very rare peak events and limited expressiveness of the Binomial distributions family.
In particular, this family cannot guarantee the existence of a peak in a simulated episode without simulating multiple peaks per episode (i.e., P π θ ϕ ∗ ̸
=
P π θ ϕ 0 ,α in terms of Section 3.2).
Yet,
CeSoR is demonstrated robust to the poor parameterization selection of D ϕ , as it presents a reasonable sampling (see Appendix D.2) and improves the returns CVaR.
Figures 20-23 present a detailed analysis of the results.
[Figure]
[Figure] [Figure]
(which is itself shown in Figure 22)
[Figure]
H Distributional Reinforcement Learning for CVaR Optimization
Many RL algorithms aim to learn the value Q ( s, a ) of a state-action pair, representing the expected return from choosing action a at state s .
Then, given a state and a finite set of action candidates, the agent can choose the action with the highest value.
In Distributional Reinforcement Learning (DRL), not only the expected return is learned, but rather the whole return distribution – conditioned on s , a and the current policy.
While standard DRL algorithms [Bellemare et al., 2017, Dabney et al., 2018b] still optimize the expected return and thus are risk-neutral, the learning of the whole return distribution encourages risk-averse variants as well [Dabney et al., 2018a].
A naive risk-averse DRL agent may simply use the learned return distribution to choose the action with the highest risk measure (e.g., CVaR) over the returns.
However, notice that the return distribution is conditioned on the policy.
Hence, similarly to other RL methods, the learned values become incorrect once we change the policy: the CVaR of the current action does not take into account the change in the next action.
Thus, this naive approach would not truly optimize the CVaR.
Instead, a risk-averse DRL agent can train using a risk-averse actor, such that the learned distribution is consistent with the risk-averse policy.
This approach is valid and was indeed used by Dabney et al.
[2018a].
However, it suffers from similar limitations as CVaR-PG.
Regarding sample-efficiency,
CVaR-DRL considers only the bottom quantiles of the distribution, whose corresponding loss function assigns very low weights to all the returns except for the lowest ones, reducing the effective sample size.
In particular, since there is no separation between low returns and high-risk environment conditions, still only a small portion of the data corresponds to high-risk, and it remains challenging to learn how to act under such conditions.
Regarding blindness to success, CVaR-DRL is still prone to miss beneficial strategies: it still directs the actor policy according to the lowest returns rather than the hardest conditions, and learns the distribution with respect to that policy.
We implemented the methods mentioned above for the Guarded Maze benchmark, on top of the
QR-DQN [Dabney et al., 2018b] implementation of Stable-Baselines [Raffin et al., 2021].
As shown in Table 1, none of the DRL variants improved the CVaR return even in comparison to the baseline
CVaR-PG (GCVaR): the standard risk-neutral QR-DQN obtained similar returns to the risk-neutral
PG; the naive DRL approach resulted in a noisy and seemingly-meaningless policy, obtaining worse returns than GCVaR; and the valid CVaR-DRL obtained identical returns to GCVaR.
These results support the discussion above, indicating that blindness to success and sampleinefficiency are general limitations in risk-averse RL, and in particular apply to DRL in addition to
PG.
We hope that our work will pave the way for other efficient risk-averse RL methods, beyond the scope of PG algorithms.
[Table]