|
def | __init__ (self, starStamps, innerRadius=None, outerRadius=None, metadata=None, use_mask=True, use_variance=False) |
|
def | initAndNormalize (cls, starStamps, innerRadius, outerRadius, metadata=None, use_mask=True, use_variance=False, imCenter=None, statsControl=afwMath.StatisticsControl(), statsFlag=afwMath.stringToStatisticsProperty("MEAN"), badMaskPlanes=('BAD', 'SAT', 'NO_DATA')) |
|
def | readFits (cls, filename) |
|
def | readFitsWithOptions (cls, filename, options) |
|
def | append (self, item, innerRadius=None, outerRadius=None) |
|
def | extend (self, bss) |
|
def | getMagnitudes (self) |
|
def | getGaiaIds (self) |
|
def | getAnnularFluxes (self) |
|
def | selectByMag (self, magMin=None, magMax=None) |
|
def | writeFits (self, filename) |
|
def | __len__ (self) |
|
def | __getitem__ (self, index) |
|
def | __iter__ (self) |
|
def | getMaskedImages (self) |
|
def | metadata (self) |
|
Collection of bright star stamps and associated metadata.
Parameters
----------
starStamps : `collections.abc.Sequence` [`BrightStarStamp`]
Sequence of star stamps. Cannot contain both normalized and
unnormalized stamps.
innerRadius : `int`, optional
Inner radius value, in pixels. This and ``outerRadius`` define the
annulus used to compute the ``"annularFlux"`` values within each
``starStamp``. Must be provided if ``normalize`` is True.
outerRadius : `int`, optional
Outer radius value, in pixels. This and ``innerRadius`` define the
annulus used to compute the ``"annularFlux"`` values within each
``starStamp``. Must be provided if ``normalize`` is True.
metadata : `lsst.daf.base.PropertyList`, optional
Metadata associated with the bright stars.
use_mask : `bool`
If `True` read and write mask data. Default `True`.
use_variance : `bool`
If ``True`` read and write variance data. Default ``False``.
Raises
------
ValueError
Raised if one of the star stamps provided does not contain the
required keys.
AttributeError
Raised if there is a mix-and-match of normalized and unnormalized
stamps, stamps normalized with different annulus definitions, or if
stamps are to be normalized but annular radii were not provided.
Notes
-----
A butler can be used to read only a part of the stamps, specified by a
bbox:
>>> starSubregions = butler.get("brightStarStamps_sub", dataId, bbox=bbox)
Definition at line 132 of file brightStarStamps.py.
def lsst.meas.algorithms.brightStarStamps.BrightStarStamps.append |
( |
|
self, |
|
|
|
item, |
|
|
|
innerRadius = None , |
|
|
|
outerRadius = None |
|
) |
| |
Add an additional bright star stamp.
Parameters
----------
item : `BrightStarStamp`
Bright star stamp to append.
innerRadius : `int`, optional
Inner radius value, in pixels. This and ``outerRadius`` define the
annulus used to compute the ``"annularFlux"`` values within each
``BrightStarStamp``.
outerRadius : `int`, optional
Outer radius value, in pixels. This and ``innerRadius`` define the
annulus used to compute the ``"annularFlux"`` values within each
``BrightStarStamp``.
Definition at line 309 of file brightStarStamps.py.
def lsst.meas.algorithms.brightStarStamps.BrightStarStamps.initAndNormalize |
( |
|
cls, |
|
|
|
starStamps, |
|
|
|
innerRadius, |
|
|
|
outerRadius, |
|
|
|
metadata = None , |
|
|
|
use_mask = True , |
|
|
|
use_variance = False , |
|
|
|
imCenter = None , |
|
|
|
statsControl = afwMath.StatisticsControl() , |
|
|
|
statsFlag = afwMath.stringToStatisticsProperty("MEAN") , |
|
|
|
badMaskPlanes = ('BAD', 'SAT', 'NO_DATA') |
|
) |
| |
Normalize a set of bright star stamps and initialize a
BrightStarStamps instance.
Since the center of bright stars are saturated and/or heavily affected
by ghosts, we measure their flux in an annulus with a large enough
inner radius to avoid the most severe ghosts and contain enough
non-saturated pixels.
Parameters
----------
starStamps : `collections.abc.Sequence` [`BrightStarStamp`]
Sequence of star stamps. Cannot contain both normalized and
unnormalized stamps.
innerRadius : `int`
Inner radius value, in pixels. This and ``outerRadius`` define the
annulus used to compute the ``"annularFlux"`` values within each
``starStamp``.
outerRadius : `int`
Outer radius value, in pixels. This and ``innerRadius`` define the
annulus used to compute the ``"annularFlux"`` values within each
``starStamp``.
metadata : `lsst.daf.base.PropertyList`, optional
Metadata associated with the bright stars.
use_mask : `bool`
If `True` read and write mask data. Default `True`.
use_variance : `bool`
If ``True`` read and write variance data. Default ``False``.
imCenter : `collections.abc.Sequence`, optional
Center of the object, in pixels. If not provided, the center of the
first stamp's pixel grid will be used.
statsControl : `lsst.afw.math.statistics.StatisticsControl`, optional
StatisticsControl to be used when computing flux over all pixels
within the annulus.
statsFlag : `lsst.afw.math.statistics.Property`, optional
statsFlag to be passed on to ``afwMath.makeStatistics`` to compute
annularFlux. Defaults to a simple MEAN.
badMaskPlanes : `collections.abc.Collection` [`str`]
Collection of mask planes to ignore when computing annularFlux.
Raises
------
ValueError
Raised if one of the star stamps provided does not contain the
required keys.
AttributeError
Raised if there is a mix-and-match of normalized and unnormalized
stamps, stamps normalized with different annulus definitions, or if
stamps are to be normalized but annular radii were not provided.
Definition at line 187 of file brightStarStamps.py.