9.2.6. Pipeline¶
Pipeline components.
- class junifer.pipeline.MarkerCollection(markers, datareader=None, preprocessors=None, storage=None)¶
Class for marker collection.
- Parameters:
- Raises:
ValueErrorIf
markershave same names.
- fit(input)¶
Fit the pipeline.
- Parameters:
- input
dict The input data to fit the pipeline on. Should be the output of indexing the Data Grabber with one element.
- input
- Returns:
- validate(datagrabber)¶
Validate the pipeline.
Without doing any computation, check if the marker collection can be fitted without problems i.e., the data required for each marker is present and streamed down the steps. Also, if a storage is configured, check that the storage can handle the markers’ output.
- Parameters:
- datagrabberDataGrabber-like
The DataGrabber to validate.
- class junifer.pipeline.PipelineStepMixin¶
Mixin class for a pipeline step.
- fit_transform(input, **kwargs)¶
Fit and transform.
- get_output_type(input_type)¶
Get output type.
- validate(input)¶
Validate the the pipeline step.
- validate_input(input)¶
Validate the input to the pipeline step.
- Parameters:
- Returns:
- Raises:
ValueErrorIf the input does not have the required data.
- class junifer.pipeline.UpdateMetaMixin¶
Mixin class for updating meta.
9.2.7. Registry¶
Provide functions for registry.
- junifer.pipeline.registry.build(step, name, baseclass, init_params=None)¶
Ensure that the given object is an instance of the given class.
- Parameters:
- Returns:
- object
An instance of the given base class.
- Raises:
RuntimeErrorIf there is a problem creating the instance.
ValueErrorIf the created object with the given name is not an instance of the base class.
- junifer.pipeline.registry.get_class(step, name)¶
Get the class of the registered function for a given step.
- Parameters:
- Returns:
- class
Registered function class.
- Raises:
ValueErrorIf the
stepornameis invalid.
- junifer.pipeline.registry.get_step_names(step)¶
Get the names of the registered functions for a given step.
- Parameters:
- step
str Name of the step.
- step
- Returns:
listList of registered function names.
- Raises:
ValueErrorIf the
stepis invalid.
- junifer.pipeline.registry.register(step, name, klass)¶
Register a function to be used in a pipeline step.
- Parameters:
- Raises:
ValueErrorIf the
stepis invalid.