mlpy.learners.online.IOnlineLearner

class mlpy.learners.online.IOnlineLearner(filename=None)[source]

Bases: mlpy.learners.ILearner

The online learner base class.

The learning step is performed during the episode or iteration after each step.

Parameters:

filename : str, optional

The name of the file to save the learner state to after each iteration. If None is given, the learner state is not saved. Default is None.

Attributes

mid The module’s unique identifier.
type This learner is of type online.

Methods

choose_action(state) Choose the next action
end(experience) End the episode.
init() Initialize the learner.
learn(experience) Learn a policy from the experience.
load(filename) Load the state of the module from file.
save(filename) Save the current state of the module to file.
start() Start an episode.
step(experience) Execute learning specific updates.