init_fromDict¶
- lsst.pipe.tasks.functors.init_fromDict(initDict, basePath='lsst.pipe.tasks.functors', typeKey='functor', name=None)¶
Initialize an object defined in a dictionary.
The object needs to be importable as f’{basePath}.{initDict[typeKey]}’. The positional and keyword arguments (if any) are contained in “args” and “kwargs” entries in the dictionary, respectively. This is used in
from_yaml
to initialize a composite functor from a specification in a YAML file.- Parameters:
- initDictdictionary
Dictionary describing object’s initialization. Must contain an entry keyed by
typeKey
that is the name of the object, relative tobasePath
.- basePathstr
Path relative to module in which
initDict[typeKey]
is defined.- typeKeystr
Key of
initDict
that is the name of the object (relative tobasePath
).