mlrl.testbed.runnables module¶
Author: Michael Rapp (michael.rapp.ml@gmail.com)
Provides base classes for programs that can be configured via command line arguments.
- class mlrl.testbed.runnables.Runnable¶
Bases:
ABCAn abstract base class for all programs that can be configured via the command line API. The programs functionality is implemented by individual extensions that are applied to the runnable.
- class PredictionDatasetExtension(*dependencies: Extension)¶
Bases:
ExtensionAn extension that configures the functionality to predict for different datasets.
- PREDICT_FOR_TEST_DATA = <mlrl.util.cli.BoolArgument object>¶
- PREDICT_FOR_TRAINING_DATA = <mlrl.util.cli.BoolArgument object>¶
- configure_experiment(args: Namespace, experiment_builder: Builder)¶
See
mlrl.testbed.extensions.extension.Extension.configure_experiment()
- configure_arguments(cli: CommandLineInterface)¶
Configures the command line interface according to the extensions applied to the runnable.
- Parameters:
cli – The command line interface to be configured
- abstractmethod create_experiment_builder(args: Namespace) Builder¶
Must be implemented by subclasses in order to create the builder that allows to configure the experiment to be run by the program.
- Parameters:
args – The command line arguments specified by the user
- Returns:
The builder that has been created
- get_algorithmic_arguments(known_args: Namespace) Set[Argument]¶
May be overridden by subclasses in order to return the arguments for configuring algorithmic parameters that should be added to the command line API.
- Parameters:
known_args – The command line arguments specified by the user
- Returns:
A set that contains the arguments that should be added to the command line API
- get_extensions() Set[Extension]¶
May be overridden by subclasses in order to return the extensions that should be applied to the runnable.
- Returns:
A set that contains the extensions to be applied to the runnable
- get_program_info() ProgramInfo | None¶
May be overridden by subclasses in order to provide information about the program to be printed via the command line argument ‘-v’ or ‘–version’.
- Returns:
A ProgramInfo or None, if no information is provided