mlpy.modules.Module¶
-
class
mlpy.modules.Module(mid=None)[source]¶ Bases:
mlpy.modules.UniqueModuleBase module class from which most modules inherit from.
The base module class handles processing of the program loop. A module inherits from the unique module class, thus every module has a unique name.
Parameters: mid : str
The module’s unique identifier
Examples
To create a module handling the program loop, write
>>> from mlpy.modules import Module >>> class MyClass(Module): >>> pass
Attributes
midThe module’s unique identifier. Methods
enter(t)Enter the module and perform initialization tasks. exit()Exit the module and perform cleanup tasks. load(filename)Load the state of the module from file. reset(t, **kwargs)Reset the module. save(filename)Save the current state of the module to file. update(dt)Update the module at every delta time step dt.