Extract bright star cutouts, and warp to the same pixel grid.
The BrightStarCutoutTask is used to extract, process, and store small image
cutouts (or "postage stamps") around bright stars.
This task essentially consists of two principal steps.
First, it identifies bright stars within an exposure using a reference
catalog and extracts a stamp around each.
Second, it shifts and warps each stamp to remove optical distortions and
sample all stars on the same pixel grid.
Definition at line 193 of file brightStarCutout.py.
| BrightStarStamps | None lsst.pipe.tasks.brightStarSubtraction.brightStarCutout.BrightStarCutoutTask._get_bright_star_stamps |
( |
| self, |
|
|
ExposureF | input_exposure, |
|
|
BackgroundList | None | input_background, |
|
|
SourceCatalog | np.ndarray | footprints, |
|
|
Table | bright_stars ) |
|
protected |
Extract and warp bright star stamps.
For each bright star, extract a stamp from the input exposure centered
on the star's pixel coordinates.
Then, shift and warp the stamp to recenter on the star and align each
to the same orientation.
Finally, check the fraction of the stamp area that is masked
(e.g. due to neighboring sources or bad pixels), and only retain stamps
with sufficient unmasked area.
Parameters
----------
input_exposure : `~lsst.afw.image.ExposureF`
The science image to extract bright star stamps.
input_background : `~lsst.afw.math.BackgroundList` | None
The background model associated with the input exposure.
If provided, this will be added back on to the input image.
footprints : `~lsst.afw.table.SourceCatalog` | `numpy.ndarray`
The source catalog containing footprints on the input exposure, or
a 2D numpy array with the same dimensions as the input exposure
where each pixel value corresponds to the source footprint ID.
bright_stars : `~astropy.table.Table`
Table of bright stars for which to extract stamps.
Returns
-------
bright_star_stamps : `~lsst.meas.algorithms.BrightStarStamps` | None
A set of postage stamp cutouts, each centered on a bright star.
If no bright star stamps are retained post-masking, returns `None`.
Definition at line 369 of file brightStarCutout.py.
| Table lsst.pipe.tasks.brightStarSubtraction.brightStarCutout.BrightStarCutoutTask._get_bright_stars |
( |
| self, |
|
|
ReferenceObjectLoader | ref_obj_loader, |
|
|
ExposureF | input_exposure ) |
|
protected |
Get a table of bright stars from the reference catalog.
Trim the reference catalog to only those objects within the exposure
bounding box.
Then, select bright stars based on the specified magnitude range,
isolation criteria, and optionally focal plane radius criteria.
Finally, add columns with pixel coordinates and focal plane coordinates
for each bright star.
Parameters
----------
ref_obj_loader : `~lsst.meas.algorithms.ReferenceObjectLoader`
Loader to find objects within a reference catalog.
input_exposure : `~lsst.afw.image.ExposureF`
The exposure for which bright stars are being selected.
Returns
-------
bright_stars : `~astropy.table.Table`
Table of bright stars within the exposure.
Definition at line 260 of file brightStarCutout.py.