plkit.runner
abstract class
plkit.runner.
Runner
(
)
The base class for runner
abstract method
run
(
config
, data_class
, model_class
, optuna=None
)
Run the whole pipeline using the runner
Parameters
config
(dict(str: any)) — A dictionary of configuration, must have following items: - batch_size: The batch size - num_classes: The number of classes for classification 1 means regressiondata_class
(type of DataModule) — The data class subclassed fromData
model_class
(type of Module) — The model class subclassed fromModule
optuna
(Optuna, optional) — The optuna objectrunner
— The runner object
Returns (Trainer)
The trainer object
class
plkit.runner.
LocalRunner
(
)
Bases
The local runner for the pipeline
class
plkit.runner.
SGERunner
(
*args
, **opts
)
The SGE runner for the pipeline
Parameters
opts
— The options for SGE runner, which will be translated as arguments forqsub
. For exampleopts={'notify': True}
will be translated asqsub --notify ...
from command line.
there are two special optionsqsub
andworkdir
.qsub
specified the path toqsub
executable andworkdir
specifies a location to save outputs, errors and scripts of each job.
Attributes
qsub
— The path to qsub executableworkdir
— The path to the workdir