Main Content

Policies and Value Functions

Define policy and value function representations, such as deep neural networks and Q tables

A reinforcement learning policy is a mapping that selects an action to take based on observations from the environment. During training, the agent tunes the parameters of its policy representation to maximize the long-term reward.

Reinforcement Learning Toolbox™ software provides objects for actor and critic representations. The actor represents the policy that selects the best action to take. The critic represents the value function that estimates the value of the current policy. Depending on your application and selected agent, you can define policy and value functions using deep neural networks, linear basis functions, or look-up tables. For more information, see Create Policies and Value Functions.

Functions

expand all

rlTableValue table or Q table
rlValueFunctionValue function approximator object for reinforcement learning agents
rlQValueFunction Q-Value function approximator object for reinforcement learning agents
rlVectorQValueFunction Vector Q-Value function approximator for reinforcement learning agents
rlContinuousDeterministicActor Deterministic actor with a continuous action space for reinforcement learning agents
rlDiscreteCategoricalActorStochastic categorical actor with a discrete action space for reinforcement learning agents
rlContinuousGaussianActorStochastic Gaussian actor with a continuous action space for reinforcement learning agents
rlOptimizerOptionsOptimization options for actors and critics
quadraticLayerQuadratic layer for actor or critic network
scalingLayerScaling layer for actor or critic network
softplusLayerSoftplus layer for actor or critic network
featureInputLayerFeature input layer
reluLayerRectified Linear Unit (ReLU) layer
tanhLayerHyperbolic tangent (tanh) layer
fullyConnectedLayerFully connected layer
lstmLayerLong short-term memory (LSTM) layer
softmaxLayerSoftmax layer
getActorGet actor from reinforcement learning agent
setActorSet actor of reinforcement learning agent
getCriticGet critic from reinforcement learning agent
setCriticSet critic of reinforcement learning agent
getLearnableParametersObtain learnable parameter values from actor or critic function object
setLearnableParametersSet learnable parameter values of actor or critic function object
getModelGet function approximator from actor or critic
setModelSet function approximator for actor or critic
getActionObtain action from agent or actor given environment observations
getValueObtain estimated value from a critic given environment observations and actions
getMaxQValueObtain maximum estimated value over all possible actions from a Q-value function critic with discrete action space, given environment observations
evaluateEvaluates a function approximator object given observation (or observation-action) input data
gradientEvaluate gradient of function approximator object given observation and action input data
accelerateOption to accelerate the computation of the gradient for approximator object based on neural network

Topics