Base class for configuration of `IdGenerator` instances.
This class is abstract (it cannot use `abc.ABCMeta` due to a metaclass
conflict), and it should mostly be considered an implementation detail
of how the attributes it defines are included in its concrete derived
classes. Derived classes must implemented `_make_dimension_packer`.
See `IdGenerator` for usage.
Definition at line 55 of file _id_generator.py.
IdGenerator lsst.meas.base._id_generator.BaseIdGeneratorConfig.apply |
( |
|
self, |
|
|
DataCoordinate |
data_id, |
|
|
**Any |
kwargs |
|
) |
| |
Construct an `IdGenerator` instance from this configuration.
Parameters
----------
data_id : `DataCoordinate`
The data ID the `IdGenerator` will embed into all IDs. This
generally must be a fully-expanded data ID (i.e. have dimension
records attached), that identifies the "instrument" or "skymap"
dimension, though this requirement may be relaxed for certain
dimension packer types.
**kwargs
Additional keyword arguments are interpreted as dimension value
pairs to include in the data ID. This may be used to provide
constraints on dimensions for which records are not available.
Returns
-------
id_generator : `IdGenerator`
Object that generates integer IDs for catalogs and their rows by
embedding the given data ID and a configurably-optional release ID.
Notes
-----
This method is called `apply` for consistency with the pattern of using
`lsst.pex.config.ConfigurableField` and `lsst.pex.config.RegistryField`
to construct the objects whose configuration they hold. It doesn't
actually use those mechanisms because we have many config classes for
the one `IdGenerator` class, instead of the other way around, and as a
result a "config as factory" approach works better.
Definition at line 113 of file _id_generator.py.