FirstLastDiaSourceTime#
- class lsst.meas.base.FirstLastDiaSourceTime(config, name, metadata)#
Bases:
DiaObjectCalculationPluginDetermine the min and max time DiaSources have been observed.
Attributes Summary
This plugin requires a filter to be specified.
DiaObject column names output by the plugin.
Does the plugin operate on a single source or the whole catalog (
str)? If the plugin operates on a single source at a time, this should be set to"single"; if it expects the whoe catalog, to"multi".Methods Summary
calculate(diaObjects, diaSources, **kwargs)Store the first and last DiaSource times per DiaObject.
Used to set the relative order of plugin execution.
Attributes Documentation
- needsFilter = False#
This plugin requires a filter to be specified. Plugin’s using filter names usually deal with fluxes and only a sub-set of the DiaSource catalog. Plugins that to not use the filter name usually run over a value common across all observations/detections such as position.
- outputCols = ['firstDiaSourceMjdTai', 'lastDiaSourceMjdTai']#
DiaObject column names output by the plugin. DiaCalculationTask should raise an error if another pluging is run output to the same column. Output columns should be defined in the DPDD/cat/Apdb schema. Filter dependent columns should be specified without the filter name perpended to them. eg
psfFluxMeaninstead ofu_psfFluxMean.
- plugType = 'multi'#
Does the plugin operate on a single source or the whole catalog (
str)? If the plugin operates on a single source at a time, this should be set to"single"; if it expects the whoe catalog, to"multi". If the plugin is of type"multi", thefailmethod must be implemented to accept the whole catalog. If the plugin is of type"single",failshould accept a single source record.
Methods Documentation
- calculate(diaObjects, diaSources, **kwargs)#
Store the first and last DiaSource times per DiaObject.
Stores the smaller of the stored value of
firstDiaSourceMjdTaiand the minimummidpointMjdTaiin the provided DiaSources, and the larger of the stored value oflastDiaSourceMjdTaiand the maximummidpointMjdTaiin the provided DiaSources. This allows the stored values to persist even when only a shorter history of DiaSources is loaded from the APDB. DiaSources with NaNmidpointMjdTaiare ignored.Parameters#
- diaObjects
pandas.DataFrame Summary objects to store values in, which may include prior values of
firstDiaSourceMjdTaiandlastDiaSourceMjdTaifor some objects.- diaSources
pandas.DataFrameorpandas.DataFrameGroupBy Catalog of DiaSources summarized by these DiaObjects.
- **kwargs
Any additional keyword arguments that may be passed to the plugin.
- diaObjects
- classmethod getExecutionOrder()#
Used to set the relative order of plugin execution.
The values returned by
getExecutionOrderare compared across all plugins, and smaller numbers run first.Notes#
CatalogCalculationPlugins must run withBasePlugin.DEFAULT_CATALOGCALCULATIONor higher.All plugins must implement this method with an appropriate run level