Original: Understanding the Evolution of Linear Regions in Deep Reinforcement Learning
Revised: Understanding the Evolution of Linear Regions in Deep Reinforcement Learning

Original: Abstract
Revised: Abstract

Original: Policies produced by deep reinforcement learning are typically characterised bytheir learning curves, but they remain poorly understood in many other respects.
Revised: Policies produced by deep reinforcement learning are typically characterised by their learning curves, but they remain poorly understood in many other respects.

Original: ReLU-based policies result in a partitioning of the input space into piecewise linearregions.
Revised: ReLU-based policies result in a partitioning of the input space into piecewise linear regions.

Original: We seek to understand how observed region counts and their densitiesevolve during deep reinforcement learning using empirical results that span arange of continuous control tasks and policy network dimensions.
Revised: We seek to understand how observed region counts and their densities evolve during deep reinforcement learning using empirical results that span a range of continuous control tasks and policy network dimensions.

Original: Intuitively, wemay expect that during training, the region density increases in the areas that arefrequently visited by the policy, thereby affording fine-grained control.
Revised: Intuitively, we may expect that during training, the region density increases in the areas that are frequently visited by the policy, thereby affording fine-grained control.

Original: We userecent theoretical and empirical results for the linear regions induced by neuralnetworks in supervised learning settings for grounding and comparison of ourresults.
Revised: We use recent theoretical and empirical results for the linear regions induced by neural networks in supervised learning settings for grounding and comparison of our results.

Original: Empirically, we find that the region density increases only moderatelythroughout training, as measured along fixed trajectories coming from the finalpolicy.
Revised: Empirically, we find that the region density increases only moderately throughout training, as measured along fixed trajectories coming from the final policy.

Original: However, the trajectories themselves also increase in length during training,and thus the region densities decrease as seen from the perspective of the currenttrajectory.
Revised: However, the trajectories themselves also increase in length during training, and thus the region densities decrease as seen from the perspective of the current trajectory.

Revised: Our findings suggest that the complexity of deep reinforcement learning policies does not principally emerge from a significant growth in the complexity of functions observed on-and-around trajectories of the policy.

Original: We further provide other empirically-driven observations regardingthe number of visited regions with respect to the number of neurons, changingtrajectory lengths during training, and the impact of network depth on regiondensity.
Revised: We further provide other empirically-driven observations regarding the number of visited regions with respect to the number of neurons, changing trajectory lengths during training, and the impact of network depth on region density.

Original:  Introduction
Revised:  Introduction

Original: Deep reinforcement learning (RL) utilizes neural networks to represent the policy and to train thisnetwork to optimize an objective, typically the expected value of time-discounted future rewards.
Revised: Deep reinforcement learning (RL) utilizes neural networks to represent the policy and to train this network to optimize an objective, typically the expected value of time-discounted future rewards.

Original: Deep RL algorithms have been successfully applied to diverse applications including robotics,challenging games, and an increasing number of real-world decision-and-control problems [FrançoisLavet et al., 2018].
Revised: Deep RL algorithms have been successfully applied to diverse applications including robotics, challenging games and an increasing number of real-world decision-and-control problems [FrançoisLavet et al., 2018].

Original: For a given choice of task, RL algorithm and policy network configuration,the performance is commonly characterised via the learning curves, which provide insight into thelearning efficiency and the final performance.
Revised: For a given choice of task, RL algorithm, and policy network configuration, the performance is commonly characterised via the learning curves, which provide insight into the learning efficiency and the final performance.

Original: However, little has been done to understand the detailedstructure of the state-to-action mappings induced by the control policies and how these evolve overtime.
Revised: However, little has been done to understand the detailed structure of the state-to-action mappings induced by the control policies and how these evolve over time.

Original: In this work we aim to further understand deep feed-forward neural network policies that use rectifiedlinear activation functions (rectifier linear units or ReLUs).
Revised: In this work, we aim to further understand deep feed-forward neural network policies that use rectified linear activation functions (rectifier linear units or ReLUs).

Original: ReLUs [Nair and Hinton, 2010] areamong the most popular choices of activation functions due to their practical successes [Montúfaret al., 2014].
Revised: ReLUs [Nair and Hinton, 2010] are among the most popular choices of activation functions due to their practical successes [Montúfar et al., 2014].

Original: For RL, these activations induce a piecewise linear mapping from states to actions,where the input space, i.e, the state space, is divided into distinct linear regions , where within eachregion, the actions are a linear function of the states.
Revised: For RL, these activations induce a piecewise linear mapping from states to actions, where the input space, i.e, the state space, is divided into distinct linear regions , where within each region, the actions are a linear function of the states.

Original: Note that the regions are formally an affinefunction of the input, due to the constant-valued bias terms.
Revised: Note that the regions are formally an affine function of the input, due to the constant-valued bias terms.

Original: For simplicity and convenience, these are more commonly described as linear regions.
Revised: For simplicity and convenience, these are more commonly described as linear regions.

Original: Figure 1 provides a schematic illustration of theseregions, along with a policy trajectory.
Revised: Figure 1 provides a schematic illustration of these regions, along with a policy trajectory.

Original: The number of distinct regions into which the input space is divided is a natural measure of networkexpressivity.
Revised: The number of distinct regions into which the input space is divided is a natural measure of network expressivity.

Original: Learned functions with many linear regions have the capacity to build complex andflexible decision boundaries.
Revised: Learned functions with many linear regions have the capacity to build complex and flexible decision boundaries.

Original: Thus, the problem of counting the number of linear regions has beenextensively studied in recent literature [Montúfar et al., 2014, Raghu et al., 2017, Hanin and Rolnick,2019a, Serra et al., 2018].
Revised: Thus, the problem of counting the number of linear regions has been extensively studied in recent literature [Montúfar et al., 2014, Raghu et al., 2017, Hanin and Rolnick, 2019a, Serra et al., 2018].

Original: While the maximum number of regions is exponential with respect tonetwork depth [Montúfar et al., 2014], recent work has demonstrated that the number of regions isinstead typically proportional to the number neurons [Hanin and Rolnick, 2019a].
Revised: While the maximum number of regions is exponential with respect to network depth [Montúfar et al., 2014], recent work has demonstrated that the number of regions is instead typically proportional to the number neurons [Hanin and Rolnick, 2019a].

Original: For RL, we are interested in the local granularity (density) of linear regions along trajectories arisingfrom the policy.
Revised: For RL, we are interested in the local granularity (density) of linear regions along trajectories arising from the policy.

Original: Fine-grained regions afford fine-grained control, and thus we may hypothesize thatregion density increases in regions frequently visited by the policy, in order to afford better control.
Revised: Fine-grained regions afford fine-grained control, and thus we may hypothesize that region density increases in regions frequently visited by the policy, in order to afford better control.

Original: Recent work in supervised-learning of image classification is inconsistent with regard to findingsabout the region density seen in the vicinity of data points, with some reporting a decrease [Novaket al., 2018] to provide better generalization and robustness to perturbation, and others not
Revised: Recent work in supervised-learning of image classification is inconsistent with regard to findings about the region density seen in the vicinity of data points, with some reporting a decrease [Novak et al., 2018] to provide better generalization and robustness to perturbation, and others not

Original: [Hanin and
Revised: [Hanin and

Original: Rolnick, 2019a].
Revised: Rolnick, 2019a].

Original: For the RL setting, we note that counting regions visited along an episode trajectoryarguably provides a meaningful and task-grounded measurement in contrast to line-segments andellipses that pass through randomly sampled points sampled from training data, which have beenused in the prior works mentioned above.
Revised: For the RL setting, we note that counting regions visited along an episode trajectory arguably provides a meaningful and task-grounded measurement in contrast to line-segments and ellipses that pass through randomly sampled points sampled from training data, which have been used in the prior works mentioned above.

Original: We further note that piecewise-affine control strategies arecommonly designed into control systems, e.g., via gain scheduling.
Revised: We further note that piecewise-affine control strategies are commonly designed into control systems, e.g., via gain scheduling.

Original: Understanding how these regionsare designed and distributed by deep RL thus helps establish bridges with these existing methods.
Revised: Understanding how these regions are designed and distributed by deep RL thus helps establish bridges with these existing methods.

Original: To the best of our knowledge, our work is the first to investigate the structure and evolution oflinear regions of ReLU-based deep RL policies in detail.
Revised: To the best of our knowledge, our work is the first to investigate the structure and evolution of linear regions of ReLU-based deep RL policies in detail.

Original: We seek to answer several basic empiricalquestions :
Revised: We seek to answer several basic empirical questions :

Original: Q1 Do findings for network expressivity, originally developed in supervised learning settings,apply to RL policies?
Revised: Q1 Do findings for network expressivity, originally developed in supervised learning settings, apply to RL policies?

Original: How are the region densities affected by the policy network configuration?
Revised: How are the region densities affected by the policy network configuration?

Original: Do deeper policy networks result in finer-grained regions and hence an increasedexpressivity?
Revised: Do deeper policy networks result in finer-grained regions and hence an increased expressivity?

Original: Q2 How do the linear regions of a policy evolve during training?
Revised: Q2 How do the linear regions of a policy evolve during training?

Original: Do we see a significantlygreater density of regions emerge along the areas of the state space frequently visited bythe episodic trajectories, thereby allowing for finer-grained control?
Revised: Do we see a significantly greater density of regions emerge along the areas of the state space frequently visited by the episodic trajectories, thereby allowing for finer-grained control?

Original: Do random-actiontrajectories see different densities?
Revised: Do random-action trajectories see different densities?

Original: The key results can be summarized as follows, for policies trained using proximal policy optimization  [Schulman et al., 2017], and evaluated on four different continuous control tasks.
Revised: The key results can be summarized as follows, for policies trained using proximal policy optimization (PPO) [Schulman et al., 2017], and evaluated on four different continuous control tasks.

Original: Q1:
Revised: Q1:

Original: Thereis a general alignment with recent theoretical and empirical results for supervised learning settings.
Revised: There is a general alignment with recent theoretical and empirical results for supervised learning settings.

Original: Region density is principally proportional to the number of neurons, with an additional small observedincrease in density for deeper networks.
Revised: Region density is principally proportional to the number of neurons, with an additional small observed increase in density for deeper networks.

Original: Q2:
Revised: Q2:

Original: Only a moderate increase of density is observed duringtraining, as measured along fixed final-policy trajectories.
Revised: Only a moderate increase of density is observed during training, as measured along fixed final-policy trajectories.

Original: Therefore, the complexity of a final learnedpolicy does not come principally from increased density on-and-around the optimal trajectories,which is a potentially surprising result.
Revised: Therefore, the complexity of a final learned policy does not come principally from increased density on-and-around the optimal trajectories, which is a potentially surprising result.

Original: In contrast, as measured along the evolving current-policytrajectories, a decrease in region density is observed during training.
Revised: In contrast, as measured along the evolving current-policy trajectories, a decrease in region density is observed during training.

Original: Across all settings, we also observe that the region-transition count, as observed during fixed time-duration episodes, growsduring training before converging to a plateau.
Revised: Across all settings, we also observe that the region-transition count, as observed during fixed time-duration episodes, grows during training before converging to a plateau.

Original: However, the trajectory length, as measured in theinput space, also grows towards a plateau, although not at the same rate, and this leads to variationsin the mean region densities as observed along current trajectories during training.
Revised: However, the trajectory length, as measured in the input space, also grows towards a plateau, although not at the same rate, and this leads to variations in the mean region densities as observed along current trajectories during training.

Original:  Related Work
Revised:  Related Work

Original: Understanding the expressivity of a neural network is fundamental to better understanding itsoperation.
Revised: Understanding the expressivity of a neural network is fundamental to better understanding its operation.

Original: Several works study exprressivity of deep neural networks with piecewise linear activationsby counting their linear regions [Arora et al., 2016, Bianchini and Scarselli, 2014].
Revised: Several works study exprressivity of deep neural networks with piecewise linear activations by counting their linear regions [Arora et al., 2016, Bianchini and Scarselli, 2014].

Original: On the theoreticalside, Pascanu et al.
Revised: On the theoretical side, Pascanu et al.

Original: [2013] show that in the asymptotic limit of many hidden layers, deep ReLUnetworks are capable of separating their input space into exponentially more linear regions comparedwith shallow networks, despite using the same number of computational units.
Revised: [2013] show that in the asymptotic limit of many hidden layers, deep ReLU networks are capable of separating their input space into exponentially more linear regions compared with shallow networks, despite using the same number of computational units.

Original: Following this,
Revised: Following this,

Original: Montúfar et al.
Revised: Montúfar et al.

Original: [2014] also explore the complexity of functions computable by deep feed-forwardneural networks with ReLU and maxout activations, and provide tighter upper and lower bounds forthe maximal number of linear regions.
Revised: [2014] also explore the complexity of functions computable by deep feed-forward neural networks with ReLU and maxout activations, and provide tighter upper and lower bounds for the maximal number of linear regions.

Original: They show that the number of linear regions is polynomialin the network width and exponential with respect to the network depth.
Revised: They show that the number of linear regions is polynomial in the network width and exponential with respect to the network depth.

Original: Furthermore, Raghu et al.[2017] improve the upper bound for ReLU networks by introducing a new set of expressivity measuresand showing that expressivity grows exponentially with network depth for ReLU and tanh activatedneural networks.
Revised: Furthermore, Raghu et al. [2017] improve the upper bound for ReLU networks by introducing a new set of expressivity measures and showing that expressivity grows exponentially with network depth for ReLU and tanh activated neural networks.

Original: Serra et al.
Revised: Serra et al.

Original: [2018] generalizes these results by providing even tighter upper andlower bounds for the number of regions for ReLU networks and show that the maximal number ofregions grows exponentially with depth when input dimension is sufficiently large.
Revised: [2018] generalizes these results by providing even tighter upper and lower bounds for the number of regions for ReLU networks and show that the maximal number of regions grows exponentially with depth when input dimension is sufficiently large.

Original: More recent work that touches on expressivity of depth shows that the effect of depth on theexpressivity of neural networks is likely far below that of the theoretical maximum proposed byprior literature.
Revised: More recent works that touch on expressivity of depth show that the effect of depth on the expressivity of neural networks is likely far below that of the theoretical maximum proposed by prior literature.

Original: Hanin and Rolnick [2019b] study the importance of depth on expressivity of neuralnetworks in practice.
Revised: Hanin and Rolnick [2019b] study the importance of depth on expressivity of neural networks in practice.

Original: They show that the average number of linear regions for ReLU networks atinitialization is bounded by the number of neurons raised to the input dimension, and is independentof network depth.
Revised: They show that the average number of linear regions for ReLU networks at initialization is bounded by the number of neurons raised to the input dimension, and is independent of network depth.

Original: They also empirically show that this bound remains tight during training.
Revised: They also empirically show that this bound remains tight during training.

Original: Similarly, 
Revised: Similarly, Hanin and

Original: Hanin and Rolnick [2019a] find that the average distance to the boundary of the linear regionsdepends only on the number of neurons and not on the network depth – both at initialization andduring training for supervised-learning tasks on ReLU networks.
Revised: Rolnick [2019a] find that the average distance to the boundary of the linear regions depends only on the number of neurons and not on the network depth – both at initialization and during training for supervised-learning tasks on ReLU networks.

Original: This strongly suggests that deepernetworks do not necessarily learn more complex functions in comparison to shallow networks.
Revised: This strongly suggests that deeper networks do not necessarily learn more complex functions in comparison to shallow networks.

Original: Priorto this, a number of works have shown that the strength of deep learning may arise in part from agood match between deep architectures and current training procedures [Mhaskar and Poggio, 2016, 
Revised: Prior to this, a number of works have shown that the strength of deep learning may arise in part from a good match between deep architectures and current training procedures [Mhaskar and Poggio, 2016, Mhaskar et al., 2016,

Original: Mhaskar et al., 2016, Zhang et al., 2021].
Revised: Zhang et al., 2021].

Original: Notably, Ba and Caruana [2013] show that, once deepnetworks are trained to perform a task successfully, their behavior can often be replicated by shallownetworks, suggesting that the advantages of depth may be linked to easier learning.
Revised: Notably, Ba and Caruana [2014] show that, once deep networks are trained to perform a task successfully, their behavior can often be replicated by shallow networks, suggesting that the advantages of depth may be linked to easier learning.

Original: Another line of work studies function complexity in terms of robustness to perturbations to the input.
Revised: Another line of work studies function complexity in terms of robustness to perturbations to the input.

Original: Sokoli ´ c et al.
Revised: Sokoli´c et al.

Original: [2017] theoretically studies the input-output Jacobian,  a measure of robustness, relates togeneralization.
Revised: [2017] theoretically studies the input-output Jacobian, which is a measure of robustness and also relates to generalization.

Original: Similarly, Zahavy et al.
Revised: Similarly, Zahavy et al.

Original: [2016b] propose a sensitivity measure in terms of adversarialrobustness, and provides theoretical and experimental insights on how it relates to generalization.
Revised: [2016b] propose a sensitivity measure in terms of adversarial robustness, and provides theoretical and experimental insights on how it relates to generalization.

Original: Novak et al.
Revised: Novak et al.

Original: [2018] also study robustness and sensitivity using the input-output Jacobian and numberof transitions along trajectories in the input space as measures of robustness.
Revised: [2018] also study robustness and sensitivity using the input-output Jacobian and number of transitions along trajectories in the input space as measures of robustness.

Original: They show that neuralnetworks trained for image classification tasks are more robust to input perturbations in the vicinityof the training data manifold, due to training points lying in regions of lower density.
Revised: They show that neural networks trained for image classification tasks are more robust to input perturbations in the vicinity of the training data manifold, due to training points lying in regions of lower density.

Original: Several otherrecent works have also focused on proposing tight generalization bounds for neural networks [Bartlettet al., 2017, Dziugaite and Roy, 2017, Neyshabur et al., 2017].
Revised: Several other recent works have also focused on proposing tight generalization bounds for neural networks [Bartlett et al., 2017, Dziugaite and Roy, 2017, Neyshabur et al., 2017].

Original: There are a number of works that touch on understanding deep neural networks by finding generalprinciples and patterns during training.
Revised: There are a number of works that touch on understanding deep neural networks by finding general principles and patterns during training.

Original: Arpit et al.
Revised: Arpit et al.

Original: [2017] empirically show that deep networksprioritize learning simple patterns of the data during training.
Revised: [2017] empirically show that deep networks prioritize learning simple patterns of the data during training.

Original: Xu et al.
Revised: Xu et al.

Original: [2019] find a similarphenomenon in the case of 2 -layer networks with Sigmoid activations.
Revised: [2019] find a similar phenomenon in the case of 2 -layer networks with Sigmoid activations.

Original: Rahaman et al.
Revised: Rahaman et al.

Original: [2019] studydeep ReLU activated networks through the lens of Fourier analysis and show that while deep neuralnetworks can approximate arbitrary functions, they favour low frequency ones and thus, they exhibit abias towards smooth functions.
Revised: [2019] study deep ReLU activated networks through the lens of Fourier analysis and show that while deep neural networks can approximate arbitrary functions, they favour low frequency ones and thus, they exhibit a bias towards smooth functions.

Original: Samek et al.
Revised: Samek et al.

Original: [2017] present two approaches in explaining predictionsof deep learning models in a classification task, with the first method computing the sensitivity of theprediction with respect to input perturbations and the second method that meaningfully decomposesthe decision in terms of input variables.
Revised: [2017] present two approaches in explaining predictions of deep learning models in a classification task, with the first method computing the sensitivity of the prediction with respect to input perturbations and the second method that meaningfully decomposes the decision in terms of input variables.

Original: While deep RL methods are widely used and extensively studied, few works focus on understandingthe policy structure in detail.
Revised: While deep RL methods are widely used and extensively studied, few works focus on understanding the policy structure in detail.

Original: Zahavy et al.
Revised: Zahavy et al.

Original: [2016a] propose a visualization method to interpret theagent’s actions by describing the Markov Decision Process as a directed graph on a t-SNE map.
Revised: [2016a] propose a visualization method to interpret the agent’s actions by describing the Markov Decision Process as a directed graph on a t-SNE map.

Original: Theythen suggest ways to interpret, debug and optimize deep neural network policies using the proposedvisualization maps.
Revised: They then suggest ways to interpret, debug and optimize deep neural network policies using the proposed visualization maps.

Original: Rupprecht et al.
Revised: Rupprecht et al.

Original: [2019] train a generative model over the state space of Atarigames to visualize states which minimize or maximize given action probabilities.
Revised: [2019] train a generative model over the state space of Atari games to visualize states which minimize or maximize given action probabilities.

Original: Luo et al.
Revised: Luo et al.

Original: [2018]adapt three visualization techniques to the domain of image-based RL using convolutional neuralnetworks in order to understand the decision making process of the RL agent.
Revised: [2018] adapt three visualization techniques to the domain of image-based RL using convolutional neural networks in order to understand the decision making process of the RL agent.

Original:  Piecewise Linear Regions
Revised:  Piecewise Linear Regions

Original: Throughout this work, we consider RL policies based on ReLU networks .
Revised: Throughout this work, we consider RL policies based on ReLU networks .

Original: A ReLU network isa ReLU-activated feed-forward neural network, or a multi-layer perceptron (MLP) which can beformulated as a scalar function f : R d → R o defined by a neural network with L hidden layers ofwidth d 1 , ..., d L and a o -dimensional output.
Revised: A ReLU network is a ReLU-activated feed-forward neural network, or a multi-layer perceptron (MLP) which can be formulated as a scalar function f : R d → R o defined by a neural network with L hidden layers of width d 1 , ..., d L and a o -dimensional output.

Original: Assuming the output to be 1-dimensional, and followingthe notation of Rahaman et al.
Revised: Assuming the output to be 1-dimensional, and following the notation of Rahaman et al.

Original: [2019], we have:
Revised: [2019], we have:

Original: [Equation]
Revised: [Equation]

Original: where T ( k ) : R d k − 1 → R d k computes the weighted sum T ( k ) ( x )
Revised: where T ( k ) : R d k − 1 → R d k computes the weighted sum T ( k ) ( x [Equation]

Original: =
Revised: =

Original: W ( k ) x
Revised: [Equation] ( k ) x

Original: + b ( k ) for some weightmatrix W ( k ) and bias vector b ( k ) .
Revised: + [Equation] ) for some weight matrix W ( k ) and bias vector b ( k ) .

Original: Here, σ ( u ) = max(0 , u ) denotes the ReLU activation functionacting element-wise on vector u
Revised: Here, σ ( u ) = max(0 , u ) denotes the ReLU activation function acting element-wise on vector u

Original: = ( u 1 , ..., u n ) .
Revised: = ( u 1 , ..., u n ) .

Original: Given the ReLU network f from Equation 1, again following Rahaman et al.
Revised: Given the ReLU network f from Equation 1, again following Rahaman et al.

Original: [2019], piecewiselinearity can be explicit written by
Revised: [2019], piecewise linearity can be explicit written by

Original: [Equation]
Revised: [Equation]

Original: where r is an index for the linear regions P r and 1 P r is the indicator function on P r .
Revised: where r is the index for the linear region P r and 1 P r is the indicator function on P r .

Original: The 1 × d matrix
Revised: The 1 × d matrix

Original: W r is given by:
Revised: W r is given by:

Original: [Equation]
Revised: [Equation]

Original: where W ( k ) r is obtained from the original weight W ( k ) by setting its j th column to zero wheneverneuron j of layer k − 1 is inactive.
Revised: where W ( k ) r is obtained from the original weight W ( k ) by setting its j th column to zero whenever neuron j of layer k − 1 is inactive for k > 1 .

Original:  Counting Linear Regions in RL Policies
Revised:  Counting Linear Regions in RL Policies

Original: To answer the key questions posed in the introduction, we need a method for counting the regionsencountered during the episodic trajectories taken during RL.
Revised: To answer the key questions posed in the introduction, we need a method for counting the linear regions encountered during the episodic trajectories taken during RL.

Original: For each input x , we encode eachneuron of the policy network with a binary code of 0 if its pre-activation is negative, and with a binarycode 1 otherwise.
Revised: For each input x , we encode each neuron of the policy network with a binary code of 0 if its pre-activation is negative, and with a binary code 1 otherwise.

Original: The linear region of the input x can thus be uniquely identified by a concatenationof binary codes of all the neurons in the network called an activation pattern .
Revised: The linear region of the input x can thus be uniquely identified by the concatenation of binary codes of all the neurons in the network called an activation pattern .

Original: Figure 2 illustrates theactivation pattern construction for a 2D input space.
Revised: Figureillustrates the activation pattern construction for a 2D input space.

Original: Figure 1 provides a schematic illustration of the linear regions for a 2D state space, together withan example trajectory that consists of sequential states encountered by the policy, connected withstraight-line segments.
Revised: Figure 1 provides a schematic illustration of the linear regions for a 2D state space, together with an example trajectory that consists of sequential states encountered by the policy, connected with straight-line segments.

Original: As seen in the figure, regions can be revisited, which leads to a distinctionbetween the number of transitions between regions and the number of unique regions visited along atrajectory.
Revised: As seen in the figure, regions can be revisited, which leads to a distinction between the number of transitions between regions and the number of unique regions visited along a trajectory.

Original: We compute both of these metrics along episodic trajectories, as enabled by keeping a listof the regions already visited at any point in time when processing a given episode trajectory.
Revised: We compute both of these metrics along episodic trajectories, as enabled by keeping a list of the regions already visited at any point in time when processing a given episode trajectory.

Original: Ourregion-counting method also includes regions that are crossed by the straight-line segments betweensuccessive trajectory states, although the policy itself does not explicitly encounter these regions dueto the discrete-time nature of typical RL environments.[Figure]
Revised: Our region-counting method also includes regions that are crossed by the straight-line segments between successive trajectory states, although the policy itself does not explicitly encounter these regions due to the discrete-time nature of typical RL environments.

Original: To represent the k -th line segment of the episodic trajectories in the input space, we develop aparameterized line segment given by s ( u )
Revised: To represent the k -th line segment of the episodic trajectories in the input space, we develop a parameterized line segment given by s ( u )

Original: =
Revised: =

Original: (1 − u )
Revised: (1 − u )

Original: s k − 1 + us k , where u ∈ [0 , 1] and s k − 1 , s k ∈ R ddenote the endpoints of the line segment.
Revised: s k − 1 + us k , where u ∈ [0 , 1] and s k − 1 , s k ∈ R d denote the endpoints of the line segment.

Original: We then calculate the exact number of the linear regionsover this line segment by considering the hidden layers of the policy network one at a time, startingfrom input towards the output, and observe how each region can be split by the neurons.
Revised: We then calculate the exact number of the linear regions over this line segment by considering the hidden layers of the policy network one at a time, starting from input towards the output, and observe how each region can be split by the neurons.

Original: Startingwith the first layer, we consider neurons one by one, and identify the point in the domain of u ,if any, that induces a change in the binary labeling for that neuron.
Revised: Starting with the first layer, we consider neurons one by one, and identify the point in the domain of u , if any, that induces a change in the binary labeling for that neuron.

Original: Each such point subdividesthe domain of u into two new regions where the pre-activation will be zero for one of them inthe next layer.
Revised: Each such point subdivides the domain of u into two new regions where the pre-activation will be zero for one of them in the next layer.

Original: By maintaining a list of these regions and the linear functions defined over them,and whether their pre-activation vanishes in the next layer, we proceed to the neurons of the nextlayer.
Revised: By maintaining a list of these regions and the linear functions defined over them, and whether their pre-activation vanishes in the next layer, we proceed to the neurons of the next layer.

Original: This process repeats for each of the regions resulting from the previous layer.
Revised: This process repeats for each of the regions resulting from the previous layer.

Original: We recordthe activation patterns of all the final regions, to track state visits during all segments of episodetrajectories.
Revised: We record the activation patterns of all the final regions, to track state visits during all segments of episode trajectories.

Original: In the end, for each trajectory τ , we compute the total region transitions, R T ( τ ) , as wellas the number of unique visited regions, R U ( τ ) , where R T ( τ ) + 1 ≥ R U ( τ ) .
Revised: In the end, for each trajectory τ , we compute the total region transitions, R T ( τ ) , as well as the number of unique visited regions, R U ( τ ) , where R T ( τ ) + 1 ≥ R U ( τ ) .

Original: We further computethe trajectory length in the input space, L ( τ ) .
Revised: We further compute the trajectory length in the input space, L ( τ ) .

Original: This allows us to compute normalized region densitiesaccording to ρ ( τ ) =
Revised: This allows us to compute normalized region densities according to ρ ( τ ) =

Original: R T ( τ ) /
Revised: R T ( τ ) /

Original: ( NL ( τ )) where N is the total number of neurons in the policy network,in accordance with Hanin and Rolnick [2019a].
Revised: ( NL ( τ )) where N is the total number of neurons in the policy network, in accordance with Hanin and Rolnick [2019a].

Original: We use the above metrics along two types of trajectories.
Revised: We use the above metrics along two types of trajectories.

Original: First, we considera fixed trajectory,τ ∗ as sampled from the final fully-trained policy.
Revised: First, we consider fixed trajectories, τ ∗ as sampled from the final fully-trained policy.

Original: Second, we consider current trajectories, τ , assampled from the current policy during training.
Revised: Second, we consider current trajectories, τ , as sampled from the current policy during training.

Original: Both of these trajectories offer informative views of the evolution of the policy.
Revised: Both of these trajectories offer informative views of the evolution of the policy.

Original: The former offers a direct picture of the linear-region density alonga meaningful, fixed region of the state space, i.e., that of the final optimized policy.
Revised: The former offers a direct picture of the linear-region density along a meaningful, fixed region of the state space, i.e., that of the final optimized policy.

Original: The latteroffers a view of what the policy trajectories actually encounter during training.
Revised: The latter offers a view of what the policy trajectories actually encounter during training.

Original: In order to betterunderstand the evolution of τ , we also track its length, L ( τ ) , given that the density is determinedby the region-transition count as well as the length of the trajectory.
Revised: In order to better understand the evolution of τ , we also track its length, L ( τ ) , given that the density is determined by the region-transition count as well as the length of the trajectory.

Original: Figure 3 shows the evolutionof linear regions and the types of trajectories τ ∗ and τ for a simple 2D toy environment, and a
Revised: Figure 3 shows the evolution of linear regions and the types of trajectories τ ∗ and τ for a simple 2D toy environment, and a

Original: ReLU-activated policy network of depth 2 and width 8.
Revised: ReLU-activated policy network of depth 2 and width 8.

Original:  Experimental Results
Revised:  Experimental Results

Original: We conduct our experiments on four continuous control tasks including HalfCheetah-v2, Walker-v2,
Revised: We conduct our experiments on four continuous control tasks including HalfCheetah-v2, Walker-v2,

Original: Ant-v2, and Swimmer-v2 environments from the OpenAI gym benchmark suits [Brockman et al.
Revised: Ant-v2, and Swimmer-v2 environments from the OpenAI gym benchmark suits [Brockman et al., 2016].

Original: We use the Stable-Baselines3 implementations of the PPO algorithm
Revised: We use the Stable-Baselines3 implementations of the PPO algorithm

Original: [Schulman et al., 2017]in all of our experiments throughout this work.
Revised: [Schulman et al., 2017] in all of our experiments throughout this work.

Original: We run each experiment with 5 differentrandomseeds and the results show the mean and the standard deviation across the random seeds.
Revised: We run each experiment with 5 different random Epoch = Epoch = Epoch =

Revised: Epoch =τ ∗ − 50 − 25 0 25 50 75 100 125 150 − 20 −− 10 − 55 1020 StateSpaceandATrajectoryVisualizedwith96Neurons − 50 − 25 0 25 50 75 100 125 150 − 20 −− 10 − 55 1020 StateSpaceandATrajectoryVisualizedwith96Neurons − 50 − 25 0 25 50 75 100 125 150 − 20 −− 10 − 55 1020 StateSpaceandATrajectoryVisualizedwith96Neurons − 50 − 25 0 25 50 75 100 125 150 − 20 −− 10 − 55 1020 StateSpaceandATrajectoryVisualizedwith96Neurons τ − 50 − 25 0 25 50 75 100 125 150 − 20 −− 10 − 55 1020 StateSpaceandATrajectoryVisualizedwith96Neurons − 50 − 25 0 25 50 75 100 125 150 − 20 −− 10 − 55 1020 StateSpaceandATrajectoryVisualizedwith96Neurons − 50 − 25 0 25 50 75 100 125 150 − 20 −− 10 − 55 1020 StateSpaceandATrajectoryVisualizedwith96Neurons − 50 − 25 0 25 50 75 100 125 150 − 20 −− 10 − 55 1020 StateSpaceandATrajectoryVisualizedwith96Neurons seeds and the results show the mean and the standard deviation across the random seeds.

Original: The policynetwork architectureused is an MLP with ReLU activations in all hidden layers.
Revised: The policy network architecture is an MLP with ReLU activations in all hidden layers in our experiments.

Original: We train 18 policy network configurations, as listed in supplementary material, and having N ∈{ 32 , 48 , 64 , 96 , 128 , 192 } neurons, widths w ∈ { 8 , 16 , 32 , 64 } , and depths d ∈ { 1 , 2 , 3 , 4 } .
Revised: We train 18 policy network configurations with N ∈ { 32 , 48 , 64 , 96 , 128 , 192 } neurons, widths w ∈ { 8 , 16 , 32 , 64 } , and depths d ∈ { 1 , 2 , 3 , 4 } .

Original: Weuse a fixed value function network structure of (64 , 64) in all of our experiments.
Revised: We use a fixed value function network structure of (64 , 64) in all of our experiments.

Original:  These networkconfigurations are chosen such that the network is fully-capable of learning the task and achievesnear state-of-the-art cumulative reward on the particular task it is trained on.
Revised: Details of the network configurations used for the policy network are available in Appendix C. These network configurations are chosen such that the network is fully-capable of learning the task and achieves near state-of-the-art cumulative reward on the particular task it is trained on.

Original: This allows us to studythe evolution of linear regions disentangled from properties such as trainability, which is outside thescope of this work.
Revised: This allows us to study the evolution of linear regions disentangled from properties such as trainability, which is outside the scope of this work.

Original: The table showing the range of the mean cumulative reward per task, across allnetwork configurations can be found in the supplementary material.
Revised: The table showing the range of the mean cumulative reward per task, across all network configurations can be found in Appendix B.

Original: We adopt the network initialization and hyperparameters of PPO from StableBaselines3 [Raffinet al., 2021] and train our policy networks on 2M samples (i.e. 2M timesteps in the environment).
Revised: We adopt the network initialization and hyperparameters of PPO from StableBaselines3 [Raffin et al., 2021] and train our policy networks on 2M samples (i.e. 2M timesteps in the environment).

Original: This initialization scheme also matches the best-practice recommendations for on-policy RL,e.g., [Andrychowicz et al., 2020], although it differs from that used in Hanin and Rolnick [2019a] fortheoretical and empirical linear region analysis.
Revised: This initialization scheme also matches the best-practice recommendations for on-policy RL, e.g., [Andrychowicz et al., 2020], although it differs from that used in Hanin and Rolnick [2019a] for theoretical and empirical linear region analysis.

Original: A detailed explanation of the initialization and choiceof hyperparameters is available in the supplementary material.
Revised: A detailed explanation of the initialization and choice of hyperparameters is available in Appendix E 1 .

Original: An anonymized version of our code isavailable in supplemental material and will be made public upon acceptance, under an MIT license.

Original: In what follows, we focus on the results for the HalfCheetah-v2 environment as a representativeexample.
Revised: In what follows, we focus on the results for the HalfCheetah-v2 environment as a representative example.

Original: Similar results for the other environments are provided in the supplemental material.
Revised: Similar results for the other environments are provided in Appendix J.

Original: 5.1 Evolution of the Density of Linear Regions during Training
Revised: 5.1 Evolution of the Density of Linear Regions during Training

Original: We begin by examining the number of transitions encountered as we sweep along the fixed final-policytrajectory, R T ( τ ∗ ) , as shown in Figure 4(a).
Revised: We begin by examining the number of transitions encountered as we sweep along the fixed final-policy trajectory, R T ( τ ∗ ) , as shown in Figure 4(a).

Original: For clarity, we present results for only three policynetwork configurations.
Revised: For clarity, we present results for only three policy network configurations.

Original: The complete set of results is available in the supplementary material.

Original: Thisplot shows a moderate and gradual increase of 50% in the number of region transitions observedin fixed-duration RL episodes during training, with larger policy networks having more regions.
Revised: This plot shows a moderate and gradual increase of 50% in the number of region transitions observed in fixed-duration RL episodes during training, with larger policy networks having more transitions.

Original: Computing the region density requires dividing by number of neurons, N , and the trajectory length, L ( τ ∗ ) , which is constant for the fixed final trajectory, τ ∗ .
Revised: Computing the region density requires dividing by number of neurons, N , and the trajectory length, L ( τ ∗ ) , which is constant for the fixed final trajectory, τ ∗ .

Original: The result is given in Figure 4(b) whichshows the mean and standard deviation of the normalized region densities across policy networkswith the same depth.
Revised: The result is given in Figure 4(b) which shows the mean and standard deviation of the normalized region densities across policy networks with the same depth.

Original: This shows a result that is consistent across all policy network dimensions towithin ± 30 %, and reflects an identical moderate-and-gradual increase during training, regardlessof the policy network configuration. 
Revised: This shows a result that is consistent across all policy network dimensions to within ± 30 %, and reflects an identical moderate-and-gradual increase during training, regardless of the policy network configuration. Thus, in response to Q2 , RL policies trained with [Figure] N u m b e r o f t r a n s i t i o n s

Revised: [Figure]

Original: Thus, in response to Q2 , RL policies trained with PPO see amoderate increase in region density along the parts of the state space that are frequently visited bythe policy.
Revised: [Figure] N [Figure] m

Revised: [Figure]

Revised: e r o f t r a n s i t i o n s

Revised: [Figure]

Revised: [Figure]

Original: We later discuss the observed impact of policy-network depth (§5.2).
Revised: [Figure] [Figure] T r a j ec t o r y l e n g t h [Figure]

Original: We next examine the number of transitions encountered as we sweep along the evolving set of currentpolicy trajectories, R T ( τ ) , shown in Figure 4(c).
Revised: [Figure] [Figure] [Figure]

Original: These begin near zero and then rapidly increaseas the policy succeeds at exploration. Again, for clarity, we show a representative sample of threepolicy network dimensions here and the complete set of results are available in the supplementarymaterial.
Revised: [Figure]

Original: The corresponding region densities are shown in Figure 4(d), together with the fixed-regiondensities which are repeated from Figure 4(b) (see the bottom dashed curve). We speculate thattheobserved densities are higher early on due to the unstructured nature of early exploration and the 
Revised: PPO see a moderate increase in region density along the parts of the state space that are frequently visited by the policy. We later discuss the observed impact of policy-network depth (§5.2)

Original: [Figure]
Revised: [Figure]

Original: N u m b e r o f t r a n s i t i o n s [Figure] [Figure] N
Revised: We next examine the number of transitions encountered as we sweep along the evolving set of current-policy trajectories, R T ( τ ) , shown in Figure 4(c).

Original: [Figure] m [Figure]
Revised: These begin near zero and then rapidly increase as the policy succeeds at exploration.

Original: e r o f t r a n s i t i o n s [Figure] [Figure] [Figure]
Revised: Again, for clarity, we show a representative sample of three policy network dimensions here.

Original: [Figure] T r a j ec t o r y l e n g t h [Figure] [Figure]
Revised: The corresponding region densities are shown in Figure 4(d), together with the fixed-region densities which are repeated from Figure 4(b) (see the bottom dashed curve).

Original: [Figure] i [Figure] form of network initialization, and then decrease over time as the trajectory lengths begin to increase,as shown in Figure 4(e).
Revised: We speculate that the observed densities are higher early on due to the unstructured nature of early exploration and the form of network initialization, and then decrease over time as the trajectory lengths begin to increase, as shown in Figure 4(e).

Original: We compute the number of repeat visits to regions as R T − R U , i.e., the region transition count minusthe unique region count.
Revised: We compute the number of repeat visits to regions as R T − R U , i.e., the region transition count minus the unique region count.

Original: In Figure 4(f), we track this for the current trajectory during training.
Revised: In Figure 4(f), we track this for the current trajectory during training.

Original: Wespeculate that repeat visits are high early in training because of limited exploration.
Revised: We speculate that repeat visits are high early in training because of limited exploration.

Original: Repeat visitsremain later in training because of the cyclic nature of the learned locomotion for HalfCheetah.
Revised: Repeat visits remain later in training because of the cyclic nature of the learned locomotion for HalfCheetah.

Original: 5.2 Impact of Policy Network Structure on Expressivity
Revised: 5.2 Impact of Policy Network Structure on Expressivity

Original: Our normalized density computation assumes that the number of transitions scales linearly with thenumber of neurons, N .
Revised: Our normalized density computation assumes that the number of transitions scales linearly with the number of neurons, N .

Original: However, we empirically observe that there remains a moderate dependenceon the network depth, as seen in Figure 4(b), with deeper networks resulting in moderately denserregions in the learned policies.
Revised: However, we empirically observe that there remains a moderate dependence on the network depth, as seen in Figure 4(b), with deeper networks resulting in moderately denser regions in the learned policies.

Original: We further examine the policy network expressivity using randominfinite lines.
Revised: We further examine the policy network expressivity using random infinite lines.

Original: Following Hanin and Rolnick [2019a], for each policy network, we sample 100 randomlines by randomly sampling 100 points from the final trajectory τ ∗ , and connecting each randomlysampled point to the origin of the policy input space.
Revised: Following Hanin and Rolnick [2019a], for each policy network, we sample 100 random lines by randomly sampling 100 points from the final trajectory τ ∗ , and connecting each randomly sampled point to the origin of the policy input space.

Original: Figure 4(g) shows the mean and standarddeviation of the normalized number of transitions, R T /N , as computed along these infinite lines inrandom directions passing through the origin,across the 100 random lines, over the 5 random seedsof each network configuration.
Revised: Figure 4(g) shows the mean and standard deviation of the normalized number of transitions, R T /N , as computed along these infinite lines in random directions passing through the origin, over the 5 random seeds of each network configuration.

Original: These produce approximately uniform results throughout training,showing no overall changes in mean density in various directions.
Revised: These produce approximately uniform results throughout training, showing no overall changes in mean density in various directions.

Original: These results are also consistentwith the findings of Hanin and Rolnick [2019a] as they show normalized region densities are closeto 1 at initialization and remain roughly constant during training.
Revised: These results are also consistent with the findings of Hanin and Rolnick [2019a] as they show normalized region densities are close to 1 at initialization and remain roughly constant during training.

Original: We repeated the same experimentwith 100 random lines through the mean point instead of the origin, by connecting each randomlysampled point to the mean of the 100 sampled points.
Revised: We repeated the same experiment with 100 random lines through the mean point instead of the origin, by connecting each randomly sampled point to the mean of the 100 sampled points.

Original: The difference between the density over linesthrough the origin and through the mean point is negligible.
Revised: The difference between the density over lines through the origin and through the mean point is negligible.

Original: To further examine the behavior of the policy network on areas that it does not focus on exploringduring training, we compute the region density along random trajectories created by taking randomactions in the environment.
Revised: To further examine the behavior of the policy network on areas that it does not focus on exploring during training, we compute the region density along random trajectories created by taking random actions in the environment.

Original: For each policy network, we sample  10 such random trajectories τ Rand compute the normalized region density over these.
Revised: For each policy network, we sample a set of 10 such random trajectories τ R and compute the normalized region density over these.

Original: Figure 4(h) shows the mean and standarddeviation of this metric across the 10 random trajectories, over the 5 random seeds of each networkconfiguration.
Revised: Figure 4(h) shows the mean and standard deviation of this metric across this set of 10 random trajectories, over the 5 random seeds of each network configuration.

Original: This shows a very moderate decrease during training, with fairly consistent densitiesfor all policy network configurations.
Revised: This shows a very moderate decrease during training, with fairly consistent densities for all policy network configurations.

Original: We speculate that the slight decrease in density over time arisesfrom the trained policy no longer visiting the same regions as the random-action policy.
Revised: We speculate that the slight decrease in density over time arises from the trained policy no longer visiting the same regions as the random-action policy.

Original: Comparingthe results of random trajectories with fixed and current (Figure 4(b) and Figure 4(d)), we can seethat the normalized region density over random-action trajectories and a fixed final trajectory arewithin the same range.
Revised: Comparing the results of random trajectories with fixed and current (Figure 4(b) and Figure 4(d)), we can see that the normalized region density over random-action trajectories and a fixed final trajectory are within the same range.

Original: Also, although this metric is higher over current trajectories early on duringtraining, it eventually decreases and converges to the same range of region densities as the fixedtrajectory.
Revised: Also, although this metric is higher over current trajectories early on during training, it eventually decreases and converges to the same range of region densities as the fixed trajectory.

Original: In the supplemental material we further directly visualize the regions of a policy networkfor HalfCheetah, as viewed via an embedding plane that either passes through three points sampledfrom the final fixed trajectory, or three points sampled from a random-action trajectory.
Revised: In Appendix G we further directly visualize the regions of a policy network for HalfCheetah, as viewed via an embedding plane that either passes through three points sampled from the final fixed trajectory, or three points sampled from a random-action trajectory.

Original: We do notobserve significant differences between these two cases.
Revised: We do not observe significant differences between these two visualizations.

Original: 5.3 Additional Experiments
Revised: 5.3 Additional Experiments

Original: We further study the evolution of linear-region densities for the stochastic actor-critic (SAC) RLalgorithm, to see how it may differ from PPO.
Revised: We further study the evolution of linear-region densities for the stochastic actor-critic (SAC) [Haarnoja et al., 2018] RL algorithm, to see how it may differ from PPO.

Original: The resulting comparison between PPO and SAC resultsis documented in detail in the supplementary material. Region densities observed early on duringtraining are quite different for SAC than they are for PPO, exhibiting high observed densities whichthen rapidly drop, before rising like the PPO case.
Revised: The resulting comparison between PPO and SAC results is documented in detail in Appendix F. Region densities observed early on during training are quite different for SAC than they are for PPO, exhibiting high observed densities which then rapidly drop, before rising like the PPO case.

Original: We hypothesize this is due to a combination of (i)the entropy bonus for SAC, which is then annealed away, and (ii) the different network initializationused for the baseline SAC and PPO implementations. 
Revised: We hypothesize this is due to a combination of (i) the entropy bonus for SAC, which is then annealed away, and (ii) the different network initialization used for the baseline SAC and PPO implementations. Despite this initial difference, the evolution pattern of densities are consistent with the PPO results later on during the course of training.

Revised: Moreover, similar to PPO results, densities over fixed, current and random-action trajectories are within the same range supporting our surprising finding that the complexity of RL policies is not principally captured by increased density on-and-around the optimal trajectories.

Original: We examine whether a non-cyclic task, such as LunarLander, exhibits different linear-region evolutionbehavior than our four default tasks, which are naturally biased towards cyclic locomotion.
Revised: We examine whether a non-cyclic task, such as LunarLander, exhibits different linear-region evolution behavior compared to our four default tasks, which are naturally biased towards cyclic locomotion.

Original: In thesupplemental material we show that the transition counts and densities along the fixed trajectory aresimilar in structure to those of the cyclic locomotion tasks, showing that a gradual increase in densityappears to be a general property for the PPO setting, even for non-cyclic tasks.
Revised: In Appendix H, we show that the transition counts and densities along the fixed trajectory are similar in structure to those of the cyclic locomotion tasks, showing that a gradual increase in density appears to be a general property for the PPO setting, even for non-cyclic tasks.

Original: Lastly, we also examine the behavior of linear regions in the value function, for the case of HalfCheetah and PPO.
Revised: Lastly, we also examine the behavior of linear regions in the value function, for the case of HalfCheetah and PPO.

Original: We find that linear-regions in the value functions largely evolve in a verysimilar way to those in the policy. 
Revised: We find that linear-regions in the value functions largely evolve in a very similar way to those in the policy. Full set of results for this experiment are available in Appendix I.

Original:  Conclusions
Revised:  Conclusions

Original: The structure of ReLU-based reinforcement learning policies remains poorly understood.
Revised: The structure of ReLU-based reinforcement learning policies remains poorly understood.

Original: In thiswork, wehave explored a key property of such policies, the density of linear regions observed alongpolicy trajectories, as a proxy for the complexity of functions they can learn.
Revised: In this work, we explored a key property of such policies, the density of linear regions observed along policy trajectories, as a proxy for the complexity of functions they can learn.

Original: We performed a setof experiments to see how this evolves during training and whether and how changes in depth, andwidth of the policy network affect it.
Revised: We performed a set of experiments to see how this evolves during training and whether and how changes in depth, and width of the policy network affect it.

Original: The hypothesis that the final policy trajectory sees an increase inregion density is supported to a limited degree, as we observe a moderate increase in density duringtraining, i.e., 50%.
Revised: The hypothesis that the final policy trajectory sees an increase in region density is supported to a limited degree, as we observe a moderate increase in density during training, i.e., 50%.

Original: This result is consistent across tasks and across policy networks of differentconfigurations.
Revised: This result is consistent across tasks and across policy networks of different configurations.

Original: When observed from the vantage point of the evolving current trajectory, the regiondensity is high to begin with, due to the limited length of early trajectories, and then decreasesasymptotically towards the observed final density.
Revised: When observed from the vantage point of the evolving current trajectory, the region density is high to begin with, due to the limited length of early trajectories, and then decreases asymptotically towards the observed final density.

Original: For the tasks we consider, trajectory lengths areobserved to grow and asymptotically approach a plateau during training.
Revised: For the tasks we consider, trajectory lengths are observed to grow and asymptotically approach a plateau during training.

Original: Overall, the surprisingimplication, for our experimental setting, is that the complexity of RL policies appears to be capturedby fine-tuning during learning, rather than a significant growth in the complexity of the functionsobserved along trajectories of the final policy.
Revised: Overall, the surprising implication, for our experimental setting, is that the complexity of RL policies appears to be captured by fine-tuning during learning, rather than a significant growth in the complexity of the functions observed along trajectories of the final policy.

Original: The key properties of linear regions as demonstrated for supervised learning of image classifiers, e.g.,[Hanin and Rolnick, 2019a], are shown to generally also hold true for reinforcement learning policies.
Revised: The key properties of linear regions as demonstrated for supervised learning of image classifiers, e.g., [Hanin and Rolnick, 2019a], are shown to generally also hold true for reinforcement learning policies.

Original: In particular, their expressivity is well modeled as being proportional to the number of neurons, andlargely independent of their width and depth, for ranges of these parameters where good policies canstill be learned.
Revised: In particular, their expressivity is well modeled as being proportional to the number of neurons, and largely independent of their width and depth, for ranges of these parameters where good policies can still be learned.

Original: The number of regions observed for randomly oriented line segments through theorigin of the input space is also in line with earlier theoretical and empirical results, and does notchange significantly during training.
Revised: The number of regions observed for randomly oriented line segments through the origin of the input space is also in line with earlier theoretical and empirical results, and does not change significantly during training.

Original: We envisage various future directions related to this work, including: (i) understanding the impact ofnon-IID data on decision regions more generally; (ii) consideration of RL algorithms that have less“learning path dependence”, e.g., via frequent (re)distillation onto randomly reinitialized policies;(iii) using visited regions to efficiently distill more interpretable non-parametric policies; and (iv) inreal-world control settings, using knowledge of decision regions, their sizes, and their orderings tobetter understand exploration and safety issues.

Original: Our work comes with a number of limitations.
Revised: Our work comes with a number of limitations.

Original: All the tasks are locomotion-based and thus eventuallyproduce cyclic trajectories.
Revised: Our experiments are mainly focused on locomotionbased tasks which produce cyclic trajectories.

Original: This could mean that the results may not generalize to other types oftasks.
Revised: This could mean that the results may not generalize to other types of tasks.

Original: For example, some tasks may not result in transition counts that grow, as generally observedin our experiments.
Revised: For example, some tasks may not result in transition counts that grow, as generally observed in our experiments.

Revised: In addition, our work mainly studies deep RL policies trained with PPO.

Revised: Thus, a broader analysis on more RL algorithms would shed light on the generality of the observations in this work.

Revised: One challenge in comparing different RL algorithms lies in the inherent difference in the initialization schemes commonly used for different RL algorithms.

Revised: This is because RL algorithms are usually sensitive to network initialization and changing it may result in instability.

Original:  Currently, we compute only the mean region density for a trajectory; it may beuseful to further understand the distribution of observed densities across trajectories.
Revised: In addition, network initialization affects the linear regions. Currently, we compute only the mean region density for a trajectory; it may be useful to further understand the distribution of observed densities across trajectories.

Original: We note that itis common practice in RL to apply input (observation) normalization based on a rolling average ofobservations seen so far [Andrychowicz et al., 2020], and thus our results also employ this strategy.
Revised: We note that it is common practice in RL to apply input (observation) normalization based on a rolling average of observations seen so far [Andrychowicz et al., 2020], and thus our results also employ this strategy.

Original: Applying RL without this normalization may impact both the performance of the RL algorithm andthe resulting evolution of transition counts and region-density.
Revised: Applying RL without this normalization may impact both the performance of the RL algorithm and the resulting evolution of transition counts and region-density.

Revised: Our work suggests opportunities for improving our understanding of deep reinforcement learning by looking at what their mapping of states to actions look like and how they evolve during training.

Original: We leave a number of questions to future work, including understanding the behavior of observedlinear regions in the contexts of other RL algorithms,behavior cloning, and more.
Revised: For instance, a number of questions for future work includes understanding the behavior of observed linear regions in the contexts of other RL algorithms, and behavior cloning.

Revised: In addition, we envisage various future directions related to this work, including: (i) understanding the impact of non-IID data on decision regions more generally; (ii) consideration of RL algorithms that have less “learning path dependence”, e.g., via frequent (re)distillation onto randomly reinitialized policies; (iii) using visited regions to efficiently distill more interpretable non-parametric policies; and (iv) in real-world control settings, using knowledge of decision regions, their sizes, and their orderings to better understand exploration and safety issues.

Original: Lastly, we believethat exploring possible connections with the lottery-ticket hypothesis [Frankle and Carbin, 2018] willbe worthwhile.
Revised: Lastly, we believe that exploring possible connections with the lottery-ticket hypothesis [Frankle and Carbin, 2018] will be worthwhile.

Original: As foundational research related to reinforcement learning, this work could be used to developimproved reinforcement learning policy structures and algorithms, with many possible applications,both good and bad in terms of societal impact. 
Revised: As foundational research related to reinforcement learning, this work could be used to develop improved reinforcement learning policy structures and algorithms, with many possible applications, both good and bad in terms of societal impact. Appendix A Non-Linearity Definitions The following activation functions are discussed or used in this work:

Revised: ReLU [Nair and Hinton, 2010]: max ( x, 0) 2.

Original: Checklist{+Tanh (Hyperbolic tangent): ( e x − e − x ) / ( e x + e − x ) B Experimental Setup All experiments are implemented in Pytorch [Paszke et al., 2019], using the RL codebase from Stable Baselines
+}
Revised: {+Tanh (Hyperbolic tangent): ( e x − e − x ) / ( e x + e − x ) B Experimental Setup All experiments are implemented in Pytorch [Paszke et al., 2019], using the RL codebase from Stable Baselines
+}

Revised: [Raffin et al., 2021].

Revised: We conduct our analysis on four continuous control tasks from the OpenAI gym benchmark suits [Brockman et al., 2016] including HalfCheetah-v2, Walker-v2,

Revised: Ant-v

Original: For all authors...
Revised: [Table] and Swimmer-v2 environments, using PPO algorithm [Schulman et al., 2017].

Revised: Each of our experiments are performed over 5 trials with distinct random seeds.

Revised: All policy networks configurations are chosen such that the network is fully-capable of learning the task and achieve near state-of-the-art cumulative rewards on the particular task it is trained on.

Revised: Except where specified, network initialization and hyperparameters are set to the defaults of the

Original: (a) Do the main claims made in the abstract and introduction accurately reflect the paper’s
Revised: PPO implementation of Stable Baselines3. We train our policy networks on 2M samples (i [Table] e. 2M timesteps in the environment).

Revised: Table 1 shows the range of the return per environment, across all network configurations and random seeds.

Revised: Return is measured as the mean trajectory cumulative reward across the batch collected at each epoch

Revised: [Table]

Revised: [Table]

Revised: C Network Dimensions

Revised: In all experiments, the policy and value function network architectures used are MLPs with ReLU activations in all hidden layers.

Original: contributions and scope?
Revised: The value function has N = 128 neurons with layer widths 64 , 64 in all experiments, while the policy network has 18 structures listed in Table [Table] [Table] D Plots and Error Bars

Revised: Each policy network architecture is trained with 5 random seeds.

Revised: All metric plots are shown as the mean and standard deviation across these seeds.

Revised: For the state space visualization of Figure 3, the sampling grid in input space is obtained by sampling a 300 × 300 grid with equally distanced points on a window of size 40 × 200 where x ∈ [ − 50 , 150] and ˙ x ∈ [ − 20 , 20] .

Revised: Next, we feed each point of the sampling grid into the policy network to compute its activation pattern.

Revised: Then, we group all points with the same activation pattern into a single linear region uniquely colored according to its activation pattern.

Revised: Note that the way of encoding a linear region of a point as described in Section 4 guarantees that each region will be uniquely identified by an activation pattern.

Revised: We create a color map for regions based on their activation patterns.

Revised: For the state space visualization of Figure 21, we plot regions within a 2D plane that intersects the 17-dimensional input space of HalfCheetah-v2.

Revised: To obtain the 2D plane, we sample three random points from a trajectory (final trajectory τ ∗ or random-action trajectory τ R ) and find the plane that passes through these points.

Revised: We consider all the points within a square centered at the circumcenter of the three sampled points.

Revised: Square is scaled such that it is slightly bigger than the circle.

Revised: In order to avoid missing small regions, which are dominant in higher dimensional spaces, we do not use the subsampling method used for the visualization of the 2D environment.

Revised: Instead, we compute the exact locations of the boundaries of the regions using our counting method describe in Section 4.

Revised: Each region is then colored using a randomly sampled color.

Revised: E Initialization and Hyperparameters

Revised: The initialization of the policy network has a high impact on the training performance with PPO [Andrychowicz et al., 2020].

Revised: To be able to focus on the evolution of linear regions disentangled from properties such as trainability, which is outside the scope of this work, we use the default initialization of PPO from Stable Baselines3.

Revised: This initialization scheme is consistent with the bestpractice recommendations for on-policy RL [Andrychowicz et al., 2020], but it differs from that used in Hanin and Rolnick [2019a].

Revised: In this initialization, for both the policy and value function networks, weights of the hidden layers use orthogonal initialization with scaling √ 2 , and the biases are set to 0 .

Revised: The weights of the policy network’s output layer are initialized with the scale of 0 . 01 , and the weights of the value function network’s output layer are initialized with the scale of 1 .

Revised: In Hanin and

Revised: Rolnick [2019a], networks are initialized with He normalization and biases are drawn i.i.d from a normal distribution centered at 0 with variance 10 − 6 .

Revised: We mainly adopt the default hyperparameters of PPO from the implementation of Stable Baselines in all of our experiments.

Revised: We present the details of the choices of hyperparameters in Table 3.

Revised: [Table]

Revised: F Comparison of PPO and SAC

Revised: To shed light on the effect of the choice of RL algorithm, we repeat our experiments with the Soft

Revised: Actor Critic (SAC) algorithm [Haarnoja et al., 2018].

Revised: Similar to our main experimental setup for PPO, we use the Stable-Baselines3 implementation of the SAC algorithm and conduct our experiments on the four continuous control tasks of HalfCheetah-v2, Walker-v2, Ant-v2, and Swimmer-v2 from the

Revised: OpenAI gym benchmark suits.

Revised: Again, we run each experiment with 5 different random seeds and the results show the mean and the standard deviation across the random seeds.

Revised: The policy network architecture used is an MLP with ReLU activations in all hidden layers.

Revised: To ensure full training capacity, we choose more parameterized networks in this setup.

Revised: The value function has two hidden layers with 256 neurons in each layer, while the policy network has 12 structures as listed in Table 4.

Revised: We adopt the network initialization and hyperparameters of SAC from Stable-Baselines3 and train our policy network on 1M samples.

Revised: Table 5 shows the range of the random return per environment, across all network configurations and random seeds.

Revised: Return is measured as the mean trajectory return of ten trajectories collected by running the deterministic policy without action noise once everysteps.

Revised: We present the details of the choices of hyperparameters in Table 6.

Revised: Figures 5-12 of this section, show the side-by-side comparison between the results of SAC trained on

Revised: HalfCheetah and results of PPO trained on HalfCheetah previously shown in Figure 4.

Revised: We can see that the observed region densities during training are quite different for SAC than they are for PPO, early on in training.

Revised: We hypothesize that the many transitions (and therefore corresponding high densities) observed early on in training for SAC is due to a combination of (i) the entropy bonus for

Revised: SAC, which is then annealed away, and (ii) the different network initialization used for the baseline

Revised: SAC and PPO implementations.

Revised: Figures 13-20 of this section, show the same set of plots for all four environments, now grouped by metric type to enable easier comparison between environments.

Revised: As can be observed the results for normalized region densities on the fixed final trajectory (Figure 13) are broadly consistent across environments (tasks), with Swimmer being an exception.

Original: [Yes]
Revised: [Table]

Revised: N= - 16, -

Revised: N= - 32, -

Revised: N= - - 32,32,

Revised: N=

Revised: [Table]

Revised: [Table]

Revised: [Figure]

Revised: r

Revised: [Figure]

Revised: f t r a n s i t i o n

Revised: [Figure]

Revised: [Figure]

Revised: [Figure]

Revised: i

Revised: [Figure]

Revised: i

Original: (b) Did you describe the limitations of your work?
Revised: [Figure] n [Figure] [Figure]

Original: [Yes] See Section 6.
Revised: [Figure]

Original: (c) Did you discuss any potential negative societal impacts of your work? [Yes] SeeSection 6.(d) Have you read the ethics review guidelines and ensured that your paper conforms tothem?
Revised: t

Original: [Yes]
Revised: [Figure]

Original: If you are including theoretical results... (a) Did you state the full set of assumptions of all theoretical results?
Revised: l

Original: [N/A]
Revised: [Figure]

Original: (b) Did you include complete proofs of all theoretical results?
Revised: n

Original: [N/A]3.
Revised: [Figure]

Original: If you ran experiments... (a) Did you include the code, data, and instructions needed to reproduce the main ex- perimental results (either in the supplemental material or as a URL)?
Revised: h

Original: [Yes] Code is
Revised: [Figure] [Figure]

Original: provided in the supplemental material. (b) Did you specify all the training details (e
Revised: [Figure]

Original: g., data splits, hyperparameters, how they
Revised: compute the density of transitions as we sweep along these lines.

Original: were chosen)?
Revised: We then report the mean density observed over these 100 lines.

Original: [Yes] See Section 5.
Revised: [Figure] i [Figure]

Original: (c) Did you report error bars (e g., with respect to the random seed after running experi- ments multiple times)?
Revised: d

Original: [Yes] We show min/max bars.
Revised: [Figure] n s i t y [Figure]

Original: See Section 5. (d) Did you include the total amount of compute and the type of resources used (e.g., typeof GPUs, internal cluster, or cloud provider)?
Revised: and compute

Original: [No] Our experiments require modest
Revised: [Figure] [Figure] [Figure]

Original: compute resources.
Revised: r a [Figure]

Original: If you are using existing assets (e
Revised: i t i [Figure] n [Figure]

Original: g., code, data, models) or curating/releasing new assets...
Revised: [Figure]

Original: (a) If your work uses existing assets, did you cite the creators?
Revised: [Figure]

Original: [N/A]
Revised: [Figure]

Original: (b) Did you mention the license of the assets?
Revised: r o f r e p e a t v i s i t

Original: [N/A]
Revised: [Figure]

Original: (c) Did you include any new assets either in the supplemental material or as a URL?
Revised: t

Original: [N/A]
Revised: [Figure]

Original: (d) Did you discuss whether and how consent was obtained from people whose data you’re using/curating?
Revised: r

Original: [N/A]
Revised: [Figure]

Original: (e) Did you discuss whether the data you are using/curating contains personally identifiable information or offensive content?
Revised: i

Original: [N/A]
Revised: [Figure]

Original: If you used crowdsourcing or conducted research with human subjects...
Revised: i s

Original: (a) Did you include the full text of instructions given to participants and screenshots, if
Revised: [Figure] [Figure] For each policy network configuration, we sample 100 random lines and compute the density of transitions as we sweep along these lines.

Original: applicable?
Revised: We then report the mean density observed over these 100 lines.

Original: [N/A]
Revised: [Figure]

Revised: G Decision Regions viewed via Embedding Planes

Revised: To gain insights on what the linear regions may look like in our high dimensional setting, similar to Novak et al.

Revised: [2018] and Hanin and Rolnick [2019a], we visualize the linear regions over a 2-dimensional slice through the input space defined by three points sampled from a trajectory emerged from the policy.

Revised: Figure 21 shows the linear regions of a (32 , 32) policy network trained on

Revised: HafCheetah in the 17-dimensional input space, over a 2-dimensional plane crossing three projection points sampled from the final trajectory ( τ ∗ ) in the first row, and sampled from the random-action trajectory ( τ R ) in the second row.

Revised: Comparing the visualizations of projected on points from τ ∗ and τ R (first and second row), we do not observe a significant difference between the granularity of regions over points of these two trajectories.

Revised: Moreover, surprisingly, our visualizations are more consistent with the findings of Novak et al.

Original: (b) Did you describe any potential participant risks, with links to Institutional Review
Revised: [2018] with the projection points lying in regions of lower density. [Equation] Epoch [Equation]

Revised: Epoch =

Revised: Epoch =

Revised: [Figure]

Revised: H Decision Regions for a Non-Cyclic Task: LunarLander

Revised: In this section, we aim to shed light on the possible effects of cyclic nature of locomotion tasks on our previous PPO results.

Revised: Therefore, we repeat our experiments by training PPO on

Revised: LunarLanderContinuous-v2 from OpenAI gym.

Revised: Figure 22 shows the plots from this experiment.

Original: Board (IRB) approvals, if applicable?
Revised: The linear-region evolution behavior is in fact still similar with the only discrepancy being the evolution pattern of observed density over current trajectories. For LunarLander, observed density over current trajectories does not decrease during training while having the same range of values as the density over fixed and random-action trajectories. This is due to the difference between the nature of non-cyclic and cyclic tasks. For locomotion tasks, the length of the cyclic trajectories increased during training, while for LunarLander, the trajectory length initially increases, then plateaus

Revised: once the the agent converges.

Original: [N/A]
Revised: [Figure]

Revised: r a j ec t o r y l e n g t h

Revised: [Figure]

Revised: [Figure]

Revised: [Figure]

Revised: [Figure]

Revised: I Value Network Analysis

Revised: We also explore decision regions defined by the value-function network.

Revised: We repeat our main experiments on the value network of PPO agents.

Revised: More particularly, we train a policy network with a fixed network structure of (64 , 64) with 18 different value network configurations on HalfCheetah using the PPO algorithm.

Revised: The value network configurations used here are the same as the ones used for the policy network and are listed in Table 2, having N ∈ { 32 , 48 , 64 , 96 , 128 , 192 } neurons, widths w ∈ { 8 , 16 , 32 , 64 } , and depths d ∈ { 1 , 2 , 3 , 4 } .

Revised: These network configurations are chosen such that the network is fully-capable of learning the task and achieves near state-of-the-art cumulative reward on the particular task it is trained on.

Revised: To compute the metrics, we now use the weights and biases of the value-function network, instead of the policy network.

Revised: Figure 23 shows the resulting plots.

Revised: In comparing Figure 23 and Figure 4, we see that the evolution of the region densities are remarkably similar in structure, for both fixed and current trajectories.

Revised: [Figure]

Revised: N u m b e r o f t r a n s i t i o n s

Revised: [Figure]

Revised: N u m b e r o f t r a n s i t i o n s

Revised: [Figure]

Revised: [Figure]

Revised: [Figure]

Revised: T r a j ec t o r y l e n g t h

Revised: [Figure]

Revised: [Figure]

Revised: [Figure]

Revised: i

Revised: [Figure]

Revised: d

Revised: [Figure]

Revised: i

Revised: [Figure]

Revised: origin

Revised: [Figure]

Revised: J Additional Results

Revised: We previously provided the results for the HalfCheetah environment in Figure 4.

Revised: Figures 24-31 of this section, show the same set of plots for the three remaining environments.

Revised: Plots are now grouped by metric type instead of environment, to enable easier comparison between environments.

Original: (c) Did you include the estimated hourly wage paid to participants and  the total amount
Revised: Figureshows the full set of results of Figures 4(a) and 4(c) for all policy network architectures trained on HalfCheetah. We previously provided the results for the HalfCheetah environment in Figure [Figure]

Revised: [Figure]

Revised: [Figure]

Original: spent on participant compensation?
Revised: [Figure] [Figure] , d corresponds to the depth of the policy network. These plots show that the density over fixed and current trajectories converges to the same values over training, while it increases for former and decreases for the latter.

Revised: We speculate that the density is higher for current trajectories earlier during training due to early exploration and the form of network initialization.

Revised: [Figure]

Revised: [Figure]

Revised: i

Original: [N/A]
Revised: [Figure]

Revised: r

Revised: [Figure]

Revised: g i o n s

Revised: [Figure]

Revised: [Figure]

Revised: [Figure]

Revised: i t

Revised: [Figure]

Revised: [Figure]

Revised: [Figure]

Revised: [Figure]

Revised: [Figure]