Class to define plugins for the deblender.
The new deblender executes a series of plugins specified by the user.
Each plugin defines the function to be executed, the keyword arguments required by the function,
and whether or not certain portions of the deblender might need to be rerun as a result of
the function.
Definition at line 63 of file plugins.py.
def lsst.meas.deblender.plugins.DeblenderPlugin.__init__ |
( |
|
self, |
|
|
|
func, |
|
|
|
onReset = None , |
|
|
|
maxIterations = 50 , |
|
|
** |
kwargs |
|
) |
| |
Initialize a deblender plugin
Parameters
----------
func: `function`
Function to run when the plugin is executed. The function should always take
`debResult`, a `DeblenderResult` that stores the deblender result, and
`log`, an `lsst.log`, as the first two arguments, as well as any additional
keyword arguments (that must be specified in ``kwargs``).
The function should also return ``modified``, a `bool` that tells the deblender whether
or not any templates have been modified by the function.
If ``modified==True``, the deblender will go back to step ``onReset``,
unless the has already been run ``maxIterations``.
onReset: `int`
Index of the deblender plugin to return to if ``func`` modifies any templates.
The default is ``None``, which does not re-run any plugins.
maxIterations: `int`
Maximum number of times the deblender will reset when the current plugin
returns ``True``.
Definition at line 71 of file plugins.py.