CoaddInjectConfig#

class lsst.source.injection.CoaddInjectConfig(*args, **kw)#

Bases: BaseInjectConfig

Coadd-level configuration for source injection tasks.

Attributes Summary

add_noise

Whether to randomly vary the injected flux in each pixel by an amount consistent with the injected variance.

bad_mask_names

List of mask plane names indicating pixels to ignore when fitting flux vs variance in preparation for variance plane modification.

calib_flux_radius

Aperture radius (in pixels) that was used to define the calibration for this image+catalog.

col_dec

Column name for declination (in degrees).

col_draw_size

Column name providing pixel size of the region into which the source profile will be drawn.

col_mag

Column name for magnitude.

col_ra

Column name for right ascension (in degrees).

col_source_type

Column name for the source type used in the input catalog.

col_stamp

Column name to identify FITS file postage stamps for direct injection.

col_trail_length

Column name for specifying a satellite trail length (in pixels).

connections

Field which refers to a dynamically added configuration class which is based on a PipelineTaskConnections class.

fits_alignment

How should injections from FITS files be aligned? (str, default 'pixel')

inject_variance

Whether, when injecting flux into the image plane, to inject a corresponding amount of variance into the variance plane.

mask_plane_name

Name assigned to the injected mask plane which is attached to the output exposure.

noise_seed

Initial seed for random noise generation.

process_all_data_ids

If True, all input data IDs will be processed, even those where no synthetic sources were identified for injection.

saveLogOutput

Flag to enable/disable saving of log output for a task, enabled by default.

selection

A string that can be evaluated as a boolean expression to select rows in the input injection catalog.

stamp_prefix

String to prefix to the entries in the col_stamp column, for example, a directory path.

trim_padding

Size of the pixel padding surrounding the image.

Attributes Documentation

add_noise#

Whether to randomly vary the injected flux in each pixel by an amount consistent with the injected variance. (bool, default True)

bad_mask_names#

List of mask plane names indicating pixels to ignore when fitting flux vs variance in preparation for variance plane modification. (List, default ['BAD', 'CR', 'CROSSTALK', 'INTRP', 'NO_DATA', 'SAT', 'SUSPECT', 'UNMASKEDNAN'])

calib_flux_radius#

Aperture radius (in pixels) that was used to define the calibration for this image+catalog. This will be used to produce the correct instrumental fluxes within the radius. This value should match that of the field defined in slot_CalibFlux_instFlux. (float, default 12.0)

col_dec#

Column name for declination (in degrees). (str, default 'dec')

col_draw_size#

Column name providing pixel size of the region into which the source profile will be drawn. If this column is not provided as an input, the GalSim method getGoodImageSize will be used instead. (str, default 'draw_size')

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. (str, default 'source_type')

col_stamp#

Column name to identify FITS file postage stamps for direct injection. The strings in this column will be prefixed with a string given in stamp_prefix, to assist in providing the full path to a FITS file. (str, default 'stamp')

col_trail_length#

Column name for specifying a satellite trail length (in pixels). (str, default 'trail_length')

connections: pexConfig.ConfigField#

Field which refers to a dynamically added configuration class which is based on a PipelineTaskConnections class.

fits_alignment#

How should injections from FITS files be aligned? (str, default 'pixel')

Allowed values:

'wcs'

Input image will be transformed such that the local WCS in the FITS header matches the local WCS in the target image. I.e., North, East, and angular distances in the input image will match North, East, and angular distances in the target image.

'pixel'

Input image will not be transformed. Up, right, and pixel distances in the input image will match up, right and pixel distances in the target image.

'None'

Field is optional

inject_variance#

Whether, when injecting flux into the image plane, to inject a corresponding amount of variance into the variance plane. (bool, default True)

mask_plane_name#

Name assigned to the injected mask plane which is attached to the output exposure. (str, default 'INJECTED')

noise_seed#

Initial seed for random noise generation. This value increments by 1 for each injected object, so each object has an independent noise realization. (int, default 0)

process_all_data_ids#

If True, all input data IDs will be processed, even those where no synthetic sources were identified for injection. In such an eventuality this returns a clone of the input image, renamed to the output_exposure connection name and with an empty mask_plane_name mask plane attached. (bool, default False)

saveLogOutput#

Flag to enable/disable saving of log output for a task, enabled by default. (bool, default True)

selection#

A string that can be evaluated as a boolean expression to select rows in the input injection catalog. To make use of this configuration option, the internal object name injection_catalog must be used. For example, to select all sources with a magnitude in the range 20.0 < mag < 25.0, set selection="(injection_catalog['mag'] > 20.0) & (injection_catalog['mag'] < 25.0)". The {visit} field will be substituted for the current visit ID of the exposure being processed. For example, to select only visits that match a user-supplied visit column in the input injection catalog, set selection="np.isin(injection_catalog['visit'], {visit})". (str, default None)

stamp_prefix#

String to prefix to the entries in the col_stamp column, for example, a directory path. (str, default '')

trim_padding#

Size of the pixel padding surrounding the image. Only those synthetic sources with a centroid falling within the image + trim_padding region will be considered for source injection. (int, default 100)