EPSFStar#
- class photutils.psf.EPSFStar(data, *, weights=None, cutout_center=None, origin=(0, 0), wcs_large=None, id_label=None)[source]#
Bases:
object
A class to hold a 2D cutout image and associated metadata of a star used to build an ePSF.
- Parameters:
- data
ndarray
A 2D cutout image of a single star.
- weights
ndarray
orNone
, optional A 2D array of the weights associated with the input
data
.- cutout_centertuple of two floats or
None
, optional The
(x, y)
position of the star’s center with respect to the input cutoutdata
array. IfNone
, then the center of the input cutoutdata
array will be used.- origintuple of two int, optional
The
(x, y)
index of the origin (bottom-left corner) pixel of the input cutout array with respect to the original array from which the cutout was extracted. This can be used to convert positions within the cutout image to positions in the original image.origin
andwcs_large
must both be input for a linked star (a single star extracted from different images).- wcs_large
None
or WCS object, optional A WCS object associated with the large image from which the cutout array was extracted. It should not be the WCS object of the input cutout
data
array. The WCS object must support the astropy shared interface for WCS (e.g.,astropy.wcs.WCS
,gwcs.wcs.WCS
).origin
andwcs_large
must both be input for a linked star (a single star extracted from different images).- id_labelint, str, or
None
, optional An optional identification number or label for the star.
- data
Attributes Summary
The minimal
BoundingBox
for the cutout region with respect to the original (large) image.A
ndarray
of the(x, y)
position of the star's center in the original (large) image (not the cutout image).A
ndarray
of the(x, y)
position of the star's center with respect to the input cutoutdata
array.The 2D cutout image.
A tuple of two slices representing the cutout region with respect to the original (large) image.
Methods Summary
compute_residual_image
(epsf)Compute the residual image of the star data minus the registered/scaled ePSF.
Estimate the star's flux by summing values in the input cutout array.
register_epsf
(epsf)Register and scale (in flux) the input
epsf
to the star.Attributes Documentation
- bbox#
The minimal
BoundingBox
for the cutout region with respect to the original (large) image.
- center#
A
ndarray
of the(x, y)
position of the star’s center in the original (large) image (not the cutout image).
- cutout_center#
A
ndarray
of the(x, y)
position of the star’s center with respect to the input cutoutdata
array.
- data#
The 2D cutout image.
- slices#
A tuple of two slices representing the cutout region with respect to the original (large) image.
Methods Documentation
- compute_residual_image(epsf)[source]#
Compute the residual image of the star data minus the registered/scaled ePSF.