Baobao Documentation
Classes
Pipeline
baobao.Pipeline
(root_node, pipeline=(), opts=PipelineOpts(memory=None, in_place=True, push_options=False)):param root_node: Callable or initial input data to run the pipeline
:param pipeline: Iterable composed of baobao.Step instances
:param opts: Instance of baobao.PipelineOpts
run
(self)baobao.PipelineOpts
(memory=None, in_place=True, push_options=False):param memory: Instance of joblib.Memory or anything that implements its API
:param inplyce: True / False, if true the input is transformed, if false a copy is produced
:push_options: True / False, if true, options of root pipeline are applied to all contained pipelines
:param step_prefix: String to prefix steps, is repeated depending on depth within the complete pipeline
:param pipeline_prefix: String to prefix pipelines, is repeated depending on depth within the complete pipeline
Step
baobao.Step
(func, *args, **kwargs):param func: A function or callable that takes the result of a previous pipeline stet as input and transforms it as output of this step
:param args: Positional arguments passed to func when called by pipeline
:param kwargs: Keyword arguments passed to func when called by pipeline
Utils
Print Pipeline
baobao.utils.print_pipeline
(pipeline)baobao.utils.run_parallel
(pipeline, n_jobs=2)