DataPredict

API Reference - QuickSetups - DiagonalGaussianPolicy

DiagonalGaussianPolicy is a base class for setuping up reinforcement learning functions.

Constructors

new()

Create new model object. If any of the arguments are nil, default argument values for that argument will be used.

DiagonalGaussianPolicy.new(numberOfReinforcementsPerEpisode: integer): DiagonalGaussianPolicyObject

Parameters:

Returns:

Functions

setParameters()

Set model’s parameters. When any of the arguments are nil, previous argument values for that argument will be used.

DiagonalGaussianPolicy:setParameters(numberOfReinforcementsPerEpisode: integer)

Parameters:

setModel()

DiagonalGaussianPolicy:setModel(Model: ModelObject)

Parameters:

getModel()

DiagonalGaussianPolicy:getModel(): ModelObject

Returns:

extendUpdateFunction()

Sets a new function on update alongside with the current model’s update() function.

DiagonalGaussianPolicy:extendUpdateFunction(updateFunction)

Parameters:

extendEpisodeUpdateFunction()

Sets a new function on episode update alongside with the current model’s episodeUpdate() function.

DiagonalGaussianPolicy:extendEpisodeUpdateFunction(episodeUpdateFunction)

Parameters:

reinforce()

Reward or punish model based on the current state of the environment.

DiagonalGaussianPolicy:reinforce(currentFeatureVector: matrix, actionStandardDeviationVector: matrix, rewardValue: number): matrix

Parameters:

Returns:

reset()

Resets the current parameters values.

DiagonalGaussianPolicy:reset()

setPrintOutput()

Set whether or not to show the current number of episodes and current epsilon.

DiagonalGaussianPolicy:setPrintOutput(option: boolean)

Parameters:

getCurrentNumberOfEpisodes()

DiagonalGaussianPolicy:getCurrentNumberOfEpisodes(): integer

Returns

getCurrentNumberOfReinforcements()

DiagonalGaussianPolicy:getCurrentNumberOfReinforcements(): integer

Returns