|
def | __init__ (self, Optional[Log] log=None) |
|
def | __str__ (self) |
|
def | addRule (self, KeyHandler handler, Optional[str] instrument=None, Optional[str] datasetTypeName=None, Iterable[str] gen2keys=(), bool consume=True) |
|
def | addGenericInstrumentRules (self, str instrumentName, str calibFilterType="physical_filter", str detectorKey="ccd", str exposureKey="visit") |
|
def | makeMatching (self, str datasetTypeName, Dict[str, type] gen2keys, Optional[str] instrument=None, Optional[BaseSkyMap] skyMap=None, Optional[str] skyMapName=None) |
|
A class that manages a system of rules for translating Gen2 data IDs
to Gen3 data IDs, and uses these to construct translators for particular
dataset types.
Parameters
----------
log : `lsst.log.Log`, optional
A logger for diagnostic messages.
Definition at line 281 of file translators.py.
def lsst.obs.base.gen2to3.translators.TranslatorFactory.addGenericInstrumentRules |
( |
|
self, |
|
|
str |
instrumentName, |
|
|
str |
calibFilterType = "physical_filter" , |
|
|
str |
detectorKey = "ccd" , |
|
|
str |
exposureKey = "visit" |
|
) |
| |
Add translation rules that depend on some properties of the
instrument but are otherwise generic.
Parameters
----------
instrument : `str`
The short (dimension) name of the instrument that conversion is
going to be run on.
calibFilterType : `str`, optional
One of ``physical_filter`` or ``band``, indicating which
of those the gen2 calibRegistry uses as the ``filter`` key.
detectorKey : `str`, optional
The gen2 key used to identify what in gen3 is `detector`.
exposureKey : `str`, optional
The gen2 key used to identify what in gen3 is `exposure`.
Definition at line 411 of file translators.py.
def lsst.obs.base.gen2to3.translators.TranslatorFactory.makeMatching |
( |
|
self, |
|
|
str |
datasetTypeName, |
|
|
Dict[str, type] |
gen2keys, |
|
|
Optional[str] |
instrument = None , |
|
|
Optional[BaseSkyMap] |
skyMap = None , |
|
|
Optional[str] |
skyMapName = None |
|
) |
| |
Construct a Translator appropriate for instances of the given
dataset.
Parameters
----------
datasetTypeName : `str`
Name of the dataset type.
gen2keys: `dict`
Keys of a Gen2 data ID for this dataset.
instrument: `str`, optional
Name of the Gen3 instrument dimension for translated data IDs.
skyMap: `~lsst.skymap.BaseSkyMap`, optional
The skymap instance that defines any tract/patch data IDs.
`~lsst.skymap.BaseSkyMap` instances.
skyMapName : `str`, optional
Gen3 SkyMap Dimension name to be associated with any tract or patch
Dimensions.
Returns
-------
translator : `Translator`
A translator whose translate() method can be used to transform Gen2
data IDs to Gen3 dataIds.
Definition at line 475 of file translators.py.