banffprocessor.procedures package#
Subpackages#
- banffprocessor.procedures.banff_procedures package
- Submodules
- banffprocessor.procedures.banff_procedures.deterministic module
- banffprocessor.procedures.banff_procedures.donorimputation module
- banffprocessor.procedures.banff_procedures.editstats module
- banffprocessor.procedures.banff_procedures.errorloc module
- banffprocessor.procedures.banff_procedures.estimator module
- banffprocessor.procedures.banff_procedures.job_proc module
- banffprocessor.procedures.banff_procedures.massimputation module
- banffprocessor.procedures.banff_procedures.outlier module
- banffprocessor.procedures.banff_procedures.prorate module
- banffprocessor.procedures.banff_procedures.verifyedits module
- Module contents
Submodules#
banffprocessor.procedures.factory module#
Register and unregister ProcedureInterface instances with the Banff Processor.
- banffprocessor.procedures.factory.get_procedure(procedure_name: str) type[ProcedureInterface] [source]#
Get a Procedure class under a specified name.
- Parameters:
procedure_name (str) – The name of the procedure to fetch
- Raises:
ValueError – If procedure_name is not found
- Returns:
The class reference registered under procedure_name
- Return type:
type[ProcedureInterface]
- banffprocessor.procedures.factory.register(procedure_name: str | list[str], cls: type[ProcedureInterface]) None [source]#
Register plugin class cls under procedure_name.
- Parameters:
procedure_name (str) – The name to register the procedure under
cls (type[ProcedureInterface]) – The class reference to register
banffprocessor.procedures.loader module#
Load plugin files from a defined location as python modules.
- banffprocessor.procedures.loader.load_plugins(plugin_dir: str | Path) None [source]#
Load plugins from the plugin directory.
Load all python files that include a register function from plugin_dir as modules and call these register functions to load plugin classes.
- Parameters:
plugin_dir (str | Path) – The directory where the plugin files to load are located
- Raises:
ValueError – If plugin_dir is an empty string or None
banffprocessor.procedures.procedure_interface module#
- class banffprocessor.procedures.procedure_interface.ProcedureInterface(*args, **kwargs)[source]#
Bases:
Protocol
An Interface class for custom User Defined Procedures to implement in order to be used in a Banff Job.
- classmethod execute(processor_data: ProcessorData) int [source]#
Perform the work in a procedure call (i.e. forms a banff call and executes it) and return the return code (0 for success and no errors, any non-0 value means one or more errors occured).