DonutStamps#

class lsst.ts.wep.task.DonutStamps(stamps, metadata=None, use_mask=True, use_variance=True, use_archive=False)#

Bases: StampsBase

Holds a list of DonutStamp objects with additional functions to get metadata as well as save as FITS files. This storage class is able to be used with the Gen 3 Butler and is storable and readable within a Gen 3 repository.

Methods Summary

append(newStamp)

Add an additional stamp.

extend(newStampList)

Extend DonutStamps instance by appending elements from another instance.

getBandpasses()

Get the bandpass for each stamp.

getBlendCentroids()

Get the X,Y centroid positions of the blended sources in pixels.

getCameraNames()

Get the instrument name for each stamp.

getCentroidPositions()

Get the centroid positions of the DonutStamps in the original image.

getDefocalDistances()

Get the defocal distance for each stamp.

getDefocalTypes()

Get the defocal type for each stamp.

getDetectorNames()

Get the detector name for each stamp.

getIds()

Get the id for each stamp.

getSkyPositions()

Get the ra, dec coordinates in degrees of the DonutStamps.

getXY0Positions()

Get the corner position of the DonutStamp BBox locations.

readFits(filename)

Build an instance of this class from a file.

readFitsWithOptions(filename, options)

Build an instance of this class with options.

Methods Documentation

append(newStamp)#

Add an additional stamp.

Parameters:

newStamp (DonutStamp) – DonutStamp object to append.

Raises:

ValueError – newStamp must be a DonutStamp object.

Return type:

None

extend(newStampList)#

Extend DonutStamps instance by appending elements from another instance.

Parameters:

newStampList (list [DonutStamp]) – List of DonutStamp object to append.

Raises:

ValueError – newStampList must only contain DonutStamp objects.

Return type:

None

getBandpasses()#

Get the bandpass for each stamp.

Returns:

Bandpass name for each stamp.

Return type:

list [str]

getBlendCentroids()#

Get the X,Y centroid positions of the blended sources in pixels.

Returns:

X,Y pixel locations of centers of sources blended with the central source.

Return type:

list [[str], [str]]

getCameraNames()#

Get the instrument name for each stamp.

Returns:

Camera names for each stamp.

Return type:

list [str]

getCentroidPositions()#

Get the centroid positions of the DonutStamps in the original image.

Returns:

X,Y pixel locations of center of DonutStamp images.

Return type:

list [lsst.geom.Point2I]

getDefocalDistances()#

Get the defocal distance for each stamp.

Returns:

Defocal distances for each stamp in mm.

Return type:

list [float]

getDefocalTypes()#

Get the defocal type for each stamp.

Returns:

Defocal types for each stamp.

Return type:

list [str]

getDetectorNames()#

Get the detector name for each stamp.

Returns:

Detector Names for each stamp.

Return type:

list [str]

getIds()#

Get the id for each stamp.

Returns:

Id name for each stamp.

Return type:

list [str]

getSkyPositions()#

Get the ra, dec coordinates in degrees of the DonutStamps.

Returns:

Ra, Dec locations of donuts.

Return type:

list [lsst.geom.SpherePoint]

getXY0Positions()#

Get the corner position of the DonutStamp BBox locations.

Returns:

Corner of BBox of DonutStamp lsst.afw.image.MaskedImage.

Return type:

list [lsst.geom.Point2I]

classmethod readFits(filename)#

Build an instance of this class from a file.

Parameters:

filename (str) – Name of the file to read.

Returns:

An instance of this class.

Return type:

DonutStamps

classmethod readFitsWithOptions(filename, options)#

Build an instance of this class with options.

Parameters:
  • filename (str) – Name of the file to read.

  • options (lsst.daf.base.PropertyList or dict) – Collection of metadata parameters.

Returns:

An instance of this class.

Return type:

DonutStamps