ConsolidateInjectedCatalogsConfig#
- class lsst.source.injection.ConsolidateInjectedCatalogsConfig(*args, **kw)#
Bases:
PipelineTaskConfigBase configuration for source injection tasks.
Attributes Summary
Column name for declination (in degrees).
Column name for magnitude.
Column name for right ascension (in degrees).
Column name for the source type used in the input catalog.
Extra columns to be copied from the injection catalog (e.g. for shapes) (
List, default[]).Field which refers to a dynamically added configuration class which is based on a PipelineTaskConnections class.
Optional parameter to specify whether or not the input catalogs are loaded with a Butler.
Key for the group id column to merge sources on, if any (
str, defaultNone)True if the source was successfully injected.
The size of the drawn injection box (
str, default'injection_draw_size')True if source is in the inner region of a coadd patch.
True if the source was successfully injected and is in both the inner region of a coadd patch and tract.
True if source is in the inner region of a coadd tract.
Radius for matching catalogs across different bands.
Optional parameter to remove patch overlap duplicate sources.
Flag to enable/disable saving of log output for a task, enabled by default.
Methods Summary
consolidate_deepCoadd(catalog_dict, skymap, ...)Consolidate all tables in catalog_dict into one table.
make_multiband_catalog(bands, catalog_dict, ...)Combine multiple band-specific catalogs into one multiband catalog.
setPrimaryFlags(catalog, skyMap, tractInfo, ...)Set isPrimary and related flags on sources.
Attributes Documentation
- col_dec#
Column name for declination (in degrees). (
str, default'dec')
- col_mag#
Column name for magnitude. (
str, default'mag')
- col_ra#
Column name for right ascension (in degrees). (
str, default'ra')
- col_source_type#
Column name for the source type used in the input catalog. Must match one of the surface brightness profiles defined by GalSim. For more information see the Galsim docs at https://galsim-developers.github.io/GalSim/_build/html/sb.html (
str, default'source_type')
- columns_extra#
Extra columns to be copied from the injection catalog (e.g. for shapes) (
List, default[])
- connections: pexConfig.ConfigField#
Field which refers to a dynamically added configuration class which is based on a PipelineTaskConnections class.
- get_catalogs_from_butler#
Optional parameter to specify whether or not the input catalogs are loaded with a Butler. (
bool, defaultTrue)
- groupIdKey#
Key for the group id column to merge sources on, if any (
str, defaultNone)
- injectionKey#
True if the source was successfully injected. (
str, default'injection_flag')
- injectionSizeKey#
The size of the drawn injection box (
str, default'injection_draw_size')
- isPatchInnerKey#
True if source is in the inner region of a coadd patch. (
str, default'injected_isPatchInner')
- isPrimaryKey#
True if the source was successfully injected and is in both the inner region of a coadd patch and tract. (
str, default'injected_isPrimary')
- isTractInnerKey#
True if source is in the inner region of a coadd tract. (
str, default'injected_isTractInner')
- pixel_match_radius#
Radius for matching catalogs across different bands. (
float, default0.1)
- remove_patch_overlap_duplicates#
Optional parameter to remove patch overlap duplicate sources. (
bool, defaultFalse)
- saveLogOutput#
Flag to enable/disable saving of log output for a task, enabled by default. (
bool, defaultTrue)
Methods Documentation
- consolidate_deepCoadd(catalog_dict: dict[str, Table], skymap: BaseSkyMap, tract: int, copy_catalogs: bool = False) Table#
Consolidate all tables in catalog_dict into one table.
Parameters#
- catalog_dict:
dict A dictionary with photometric bands for keys and astropy tables for items.
- skymap:
lsst.skymap.BaseSkyMap A base skymap.
- tract:
int The tract where sources have been injected.
- copy_catalogs:
bool Whether to copy the input catalogs; if False, they will be modified in-place.
Returns#
- multiband_catalog:
astropy.table.Table A single table containing all information of the separate tables in catalog_dict
- catalog_dict:
- make_multiband_catalog(bands: list, catalog_dict: dict[str, Table], match_radius: float, copy_catalogs: bool = False) Table#
Combine multiple band-specific catalogs into one multiband catalog.
Parameters#
- bands:
list A list of string photometry bands.
- catalog_dict:
dict A dictionary with photometric bands for keys and astropy tables for items.
- match_radius:
float The radius for matching catalogs across bands in arcsec.
- copy_catalogs:
bool Whether to copy the input catalogs; if False, they will be modified in-place.
Returns#
- multiband_catalog:
astropy.table.Table A catalog with sources that have magnitude information across all bands.
- bands:
- setPrimaryFlags(catalog, skyMap, tractInfo, patches: list)#
Set isPrimary and related flags on sources.
For co-added imaging, the
isPrimaryflag returns True when an object has no children, is in the inner region of a coadd patch, is in the inner region of a coadd tract, and is not detected in a pseudo-filter (e.g., a sky_object). For single frame imaging, the isPrimary flag returns True when a source has no children and is not a sky source.Parameters#
- catalog:
astropy.table.Table A catalog of sources. Writes is-patch-inner, is-tract-inner, and is-primary flags.
- skyMap
lsst.skymap.BaseSkyMap Sky tessellation object
- tractInfo
lsst.skymap.TractInfo Tract object
- patches
list List of coadd patches
- catalog: