lsst.pex.config¶
The lsst.pex.config module provides a configuration system for the LSST Science Pipelines.
The lsst.pex.config.Config class is an integral part of the task framework (see lsst.pipe.base), though lsst.pex.config is also useful on its own.
Configuration parameters can be validated, documented, and even record the history of their values for provenance.
Using lsst.pex.config¶
Contributing¶
lsst.pex.config is developed at https://github.com/lsst/pex_config.
You can find Jira issues for this module under the pex_config component.
Python API reference¶
lsst.pex.config Package¶
Functions¶
| compareConfigs(name, c1, c2[, shortcut, …]) | Compare two lsst.pex.config.Configinstances for equality. | 
| compareScalars(name, v1, v2, output[, rtol, …]) | Compare two scalar values for equality. | 
| getComparisonName(name1, name2) | Create a comparison name that is used for printed output of comparisons. | 
| makeConfigClass(ctrl[, name, base, doc, …]) | Create a Configclass that matches a  C++ control object class. | 
| makePolicy(config) | Convert a configuration into a lsst.pex.policy.Policy. | 
| makePropertySet(config) | Convert a configuration into a lsst.daf.base.PropertySet. | 
| makeRegistry(doc[, configBaseType]) | Create a Registry. | 
| registerConfig(name, registry, target) | Decorator that adds a class as a ConfigClassin aRegistryand associates it with the given configurable. | 
| registerConfigurable(name, registry[, …]) | A decorator that adds a class as a configurable in a Registryinstance. | 
| wrap(ctrl) | Decorator that adds fields from a C++ control class to a lsst.pex.config.Configclass. | 
Classes¶
| ChoiceField(doc, dtype, allowed[, default, …]) | A configuration field ( Fieldsubclass) that allows a user to select from a predefined set of values. | 
| Config | Base class for configuration (config) objects. | 
| ConfigChoiceField(doc, typemap[, default, …]) | A configuration field ( Fieldsubclass) that allows a user to choose from a set ofConfigtypes. | 
| ConfigDictField(doc, keytype, itemtype[, …]) | A configuration field ( Fieldsubclass) that is a mapping of keys toConfiginstances. | 
| ConfigField(doc, dtype[, default, check, …]) | A configuration field ( Fieldsubclass) that takes aConfig-type as a value. | 
| ConfigurableField(doc, target[, …]) | A configuration field ( Fieldsubclass) that can be can be retargeted towards a different configurable (often alsst.pipe.base.Tasksubclass). | 
| ConfigurableInstance(config, field[, at, label]) | A retargetable configuration in a ConfigurableFieldthat proxies aConfig. | 
| DictField(doc, keytype, itemtype[, default, …]) | A configuration field ( Fieldsubclass) that maps keys and values. | 
| Field(doc, dtype[, default, check, …]) | A field in a Configthat supportsint,float,complex,bool, andstrdata types. | 
| FieldValidationError(field, config, msg) | Raised when a ~lsst.pex.config.Fieldis not valid in a particular~lsst.pex.config.Config. | 
| ListField(doc, dtype[, default, optional, …]) | A configuration field ( Fieldsubclass) that contains a list of values of a specific type. | 
| RangeField(doc, dtype[, default, optional, …]) | A configuration field ( lsst.pex.config.Fieldsubclass) that requires the value to be in a specific numeric range. | 
| Registry([configBaseType]) | A base class for global registries, which map names to configurables. | 
| RegistryField(doc, registry[, default, …]) | A configuration field whose options are defined in a Registry. | 
lsst.pex.config.callStack Module¶
Functions¶
| getCallerFrame([relative]) | Get the frame for the user’s caller. | 
| getStackFrame([relative]) | Get the StackFramefor the user’s caller. | 
| getCallStack([skip]) | Retrieve the call stack for the caller. | 
Classes¶
| StackFrame(filename, lineno, function[, content]) | A single element of the stack trace. |