24#ifndef LSST_MEAS_BASE_SdssShape_h_INCLUDED
25#define LSST_MEAS_BASE_SdssShape_h_INCLUDED
183 template <
typename ImageT>
196 template <
typename ImageT>
table::Key< std::string > name
Implementation of the Photometric Calibration class.
table::Key< table::Array< std::uint8_t > > wcs
A 2-dimensional celestial WCS that transform pixels to ICRS RA/Dec, using the LSST standard for pixel...
An ellipse core with quadrupole moments as parameters.
A class to contain the data, WCS, and other information needed to describe an image of the sky.
The photometric calibration of an exposure.
Base class for all records.
Convenience base class that combines the OutputFunctorKey and InputFunctorKey.
A class used as a handle to a particular field in a table.
A FunctorKey used to get or set a geom::ellipses::Quadrupole from a tuple of constituent Keys.
Defines the fields and offsets for a table.
A mapping between the keys of two Schemas, used to copy data between them.
Record class that contains measurements made on a single exposure.
A proxy type for name lookups in a Schema.
A FunctorKey for CentroidResult.
vector-type utility class to build a collection of FlagDefinitions
FlagDefinition getDefinition(std::size_t index) const
get a reference to the FlagDefinition with specified index.
Utility class for handling flag fields that indicate the failure modes of an algorithm.
A FunctorKey for FluxResult.
Exception to be thrown when a measurement algorithm experiences a known failure mode.
Measure the image moments of source using adaptive Gaussian weights.
static FlagDefinition const SHIFT
static FlagDefinitionList const & getFlagDefinitions()
virtual void measure(afw::table::SourceRecord &measRecord, afw::image::Exposure< float > const &exposure) const
Called to measure a single child source in an image.
static Result computeAdaptiveMoments(ImageT const &image, geom::Point2D const &position, bool negative=false, Control const &ctrl=Control())
Compute the adaptive Gaussian-weighted moments of an image.
static FlagDefinition const FAILURE
static unsigned int const N_FLAGS
static FluxResult computeFixedMomentsFlux(ImageT const &image, afw::geom::ellipses::Quadrupole const &shape, geom::Point2D const &position)
Compute the instFlux within a fixed Gaussian aperture.
static FlagDefinition const MAXITER
static FlagDefinition const UNWEIGHTED
SdssShapeResultKey ResultKey
static FlagDefinition const PSF_SHAPE_BAD
static FlagDefinition const UNWEIGHTED_BAD
SdssShapeAlgorithm(Control const &ctrl, std::string const &name, afw::table::Schema &schema)
virtual void fail(afw::table::SourceRecord &measRecord, MeasurementError *error=nullptr) const
Handle an exception thrown by the current algorithm by setting flags in the given record.
A C++ control class to handle SdssShapeAlgorithm's configuration.
double maxShift
"Maximum centroid shift, limited to 2-10" ;
int maxIter
"Maximum number of iterations" ;
float tol2
"Convergence tolerance for FWHM" ;
bool doMeasurePsf
"Whether to also compute the shape of the PSF model" ;
float tol1
"Convergence tolerance for e1,e2" ;
double background
"Additional value to add to background" ;
Result object SdssShapeAlgorithm.
ErrElement instFlux_yy_Cov
instFlux, yy term in the uncertainty covariance matrix
SdssShapeResult()
Constructor; initializes everything to NaN.
bool getFlag(unsigned int index) const
Flag getter for Swig, which doesn't understand std::bitset.
ErrElement instFlux_xy_Cov
instFlux, xy term in the uncertainty covariance matrix
bool getFlag(std::string const &name) const
std::bitset< SdssShapeAlgorithm::N_FLAGS > flags
Status flags (see SdssShapeAlgorithm).
ErrElement instFlux_xx_Cov
instFlux, xx term in the uncertainty covariance matrix
A FunctorKey that maps SdssShapeResult to afw::table Records.
SdssShapeResultKey()
Default constructor; instance will not be usuable unless subsequently assigned to.
bool operator!=(SdssShapeResultKey const &other) const
virtual SdssShapeResult get(afw::table::BaseRecord const &record) const
Get an SdssShapeResult from the given record.
static SdssShapeResultKey addFields(afw::table::Schema &schema, std::string const &name, bool doMeasurePsf)
Add the appropriate fields to a Schema, and return a SdssShapeResultKey that manages them.
virtual afw::geom::ellipses::Quadrupole getPsfShape(afw::table::BaseRecord const &record) const
Get a Quadrupole for the Psf from the given record.
bool isValid() const
Return True if the key is valid.
bool operator==(SdssShapeResultKey const &other) const
Compare the FunctorKey for equality with another, using the underlying Keys.
virtual void set(afw::table::BaseRecord &record, SdssShapeResult const &value) const
Set an SdssShapeResult in the given record.
virtual void setPsfShape(afw::table::BaseRecord &record, afw::geom::ellipses::Quadrupole const &value) const
Set a Quadrupole for the Psf at the position of the given record.
FlagHandler const & getFlagHandler() const
A FunctorKey for ShapeResult.
An abstract base classes for which the same implementation can be used for both SingleFrameAlgorithm ...
#define LSST_CONTROL_FIELD(NAME, TYPE, DOC)
A preprocessor macro used to define fields in C++ "control object" structs.
Backwards-compatibility support for depersisting the old Calib (FluxMag0/FluxMag0Err) objects.
A base class for image defects.
A reusable struct for centroid measurements.
Simple class used to define and document flags The name and doc constitute the identity of the FlagDe...
A reusable result struct for instFlux measurements.
A reusable struct for moments-based shape measurements.