2 #ifndef LSST_AFW_TABLE_slots_h_INCLUDED
3 #define LSST_AFW_TABLE_slots_h_INCLUDED
9 namespace daf {
namespace base {
62 return (version > 0 ?
"slot_" :
"slot.") +
_name;
228 template <
typename MeasTagT,
typename ErrTagT>
254 template <
typename MeasurementT>
256 typename MeasurementT::MeasKey
meas;
257 typename MeasurementT::ErrKey
err;
265 typename MeasurementT::MeasKey
const & meas_,
266 typename MeasurementT::ErrKey
const & err_,
276 KeyTuple<Shape>
addShapeFields(Schema &
schema, std::string
const & name, std::string
const & doc);
279 KeyTuple<Flux>
addFluxFields(Schema &
schema, std::string
const & name, std::string
const & doc);
287 #endif // !LSST_AFW_TABLE_slots_h_INCLUDED
bool isValid() const
Return true if the key was initialized to valid offset.
An ellipse core with quadrupole moments as parameters.
Defines the fields and offsets for a table.
Field< MeasTag >::Value MeasValue
the value type used for the measurement
KeyTuple< Shape > addShapeFields(Schema &schema, std::string const &name, std::string const &doc)
Convenience function to setup fields for shape measurement algorithms.
Key< Flag > getFlagKey() const
Return the cached Key used to access the slot failure flag.
MeasKey getMeasKey() const
Return the cached Key used to access the slot measurement.
Key< double > ErrKey
Key type used to access the slot uncertainty.
QuadrupoleKey MeasKey
Key type used to access the slot measurement.
ErrKey getErrKey() const
Return the cached Key used to access the slot uncertainty.
Key< Flag > getFlagKey() const
Return the cached Key used to access the slot failure flag.
std::string getName() const
Return the name of the slot (e.g. "Centroid" or "PsfFlux")
MeasTagT MeasTag
the tag (template parameter) type used for the measurement
Key< ErrTag > ErrKey
the Key type for the error on the measurement
SlotDefinition(std::string const &name)
Construct a SlotDefinition from the name of the slot (e.g. "Centroid" or "PsfFlux") ...
bool isValid() const
Return True if all the constituent Keys are valid.
FluxSlotDefinition defPsfFlux
Key< MeasTag > MeasKey
the Key type for the actual measurement
Key< Flag > flag
Failure bit; set if the measurement did not fully succeed.
KeyTuple()
Default-constructor; all keys will be invalid.
CentroidSlotDefinition defCentroid
void setKeys(std::string const &alias, Schema const &schema)
A collection of types useful for shape measurement algorithms.
CovarianceMatrixKey< float, 3 > ErrKey
Key type used to access the slot uncertainty.
A collection of types useful for flux measurement algorithms.
bool isValid() const
Return True if both the x and y Keys are valid.
CovarianceMatrixKey< float, 2 > ErrKey
Key type used to access the slot uncertainty.
MeasurementT::MeasKey meas
Key used for the measured value.
std::string getAlias(int version) const
bool isValid() const
Return true if the key associated with the measurement is valid.
KeyTuple< Flux > addFluxFields(Schema &schema, std::string const &name, std::string const &doc)
Convenience function to setup fields for flux measurement algorithms.
bool isValid() const
Return true if the key associated with the measurement is valid.
Point2DKey MeasKey
Key type used to access the slot measurement.
ErrTagT ErrTag
the tag (template parameter) type used for the uncertainty
ErrKey getErrKey() const
Return the cached Key used to access the slot uncertainty.
ShapeSlotDefinition(std::string const &name)
Construct a SlotDefinition from the name of the slot (e.g. "Shape")
Key< double > MeasKey
Key type used to access the slot measurement.
ShapeSlotDefinition defShape
Eigen::Matrix< float, 3, 3 > ErrValue
Type returned by accessing the slot uncertainty.
FluxSlotDefinition defModelFlux
Key< Flag > getFlagKey() const
Return the cached Key used to access the slot failure flag.
geom::ellipses::Quadrupole MeasValue
Type returned by accessing the slot measurement.
KeyTuple(typename MeasurementT::MeasKey const &meas_, typename MeasurementT::ErrKey const &err_, Key< Flag > const &flag_)
Main constructor.
FluxSlotDefinition(std::string const &name)
Construct a SlotDefinition from the name of the slot (e.g. "PsfFlux")
FluxSlotDefinition defInstFlux
SlotSuite(Schema const &schema)
Initialize the slots.
MeasKey getMeasKey() const
Return the cached Key used to access the slot measurement.
MeasKey getMeasKey() const
Return the cached Key used to access the slot measurement.
bool isValid() const
Return true if the key associated with the measurement is valid.
T Value
the type returned by BaseRecord::get
Key specialization for Flag.
Class for storing generic metadata.
SlotDefinition specialization for centroids.
void setKeys(std::string const &alias, Schema const &schema)
Eigen::Matrix< float, 2, 2 > ErrValue
Type returned by accessing the slot uncertainty.
A three-element tuple of measurement, uncertainty, and flag keys.
CentroidSlotDefinition(std::string const &name)
Construct a SlotDefinition from the name of the slot (e.g. "Centroid")
geom::Point2D MeasValue
Type returned by accessing the slot measurement.
KeyTuple< Centroid > addCentroidFields(Schema &schema, std::string const &name, std::string const &doc)
Convenience function to setup fields for centroid measurement algorithms.
void setKeys(std::string const &alias, Schema const &schema)
double ErrValue
Type returned by accessing the slot uncertainty.
SlotDefinition specialization for shapes.
A FunctorKey used to get or set a geom::ellipses::Quadrupole from an (xx,yy,xy) tuple of Keys...
ErrKey getErrKey() const
Return the cached Key used to access the slot uncertainty.
double MeasValue
Type returned by accessing the slot measurement.
SlotDefinition specialization for fluxes.
Field< ErrTag >::Value ErrValue
the value type used for the uncertainty
A collection of types useful for centroid measurement algorithms.
FluxSlotDefinition defApFlux
void handleAliasChange(std::string const &alias, Schema const &schema)
Handle a callback from an AliasMap informing the table that an alias has changed. ...
MeasurementT::ErrKey err
Key used for the uncertainty.