28 namespace lsst {
namespace meas {
namespace base {
31 flux(std::numeric_limits<
Flux>::quiet_NaN()),
37 std::string
const &
name,
38 std::string
const & doc
43 "1-sigma flux uncertainty",
"count");
61 std::string
const &
name
85 std::string
const &
name,
91 mapper.addMapping(mapper.getInputSchema().find<afw::table::Flag>(
name +
"_flag").key);
111 for (; inSrc != inputCatalog.
end() && outSrc != outputCatalog.
end(); ++inSrc, ++outSrc) {
Defines the fields and offsets for a table.
table::Key< std::string > name
virtual void set(afw::table::BaseRecord &record, FluxResult const &other) const
Set a FluxResult in the given record.
A custom container class for records, based on std::vector.
afw::table::Schema schema
A mapping between the keys of two Schemas, used to copy data between them.
A FunctorKey for MagResult.
Temporarily replace negative fluxes with NaNs.
A reusable result struct for magnitudes.
Implementation of the WCS standard for a any projection.
afw::table::Key< Mag > _magKey
std::string join(std::string const &a, std::string const &b) const
Join strings using the field delimiter appropriate for this Schema.
static FluxResultKey addFields(afw::table::Schema &schema, std::string const &name, std::string const &doc)
Add a pair of _flux, _fluxSigma fields to a Schema, and return a FluxResultKey that points to them...
FluxResult()
Default constructor; initializes everything to NaN.
void set(Key< T > const &key, U const &value)
Set value of a field for the given key.
Describe an exposure's calibration.
afw::table::Key< MagErrElement > _magErrKey
iterator begin()
Iterator access.
Custom catalog class for record/table subclasses that are guaranteed to have an ID, and should generally be sorted by that ID.
afw::table::Key< Flux > _flux
static void setThrowOnNegativeFlux(bool raiseException)
Set whether Calib should throw an exception when asked to convert a flux to a magnitude.
Iterator class for CatalogT.
virtual FluxResult get(afw::table::BaseRecord const &record) const
Get a FluxResult from the given record.
Flux flux
Measured flux in DN.
Schema getSchema() const
Return the schema associated with the catalog's table.
Field< T >::Value get(Key< T > const &key) const
Return the value of a field for the given key.
A FunctorKey for FluxResult.
static MagResultKey addFields(afw::table::Schema &schema, std::string const &name)
Add a pair of _mag, _magErr fields to a Schema, and return a MagResultKey that points to them...
Base class for all records.
virtual MagResult get(afw::table::BaseRecord const &record) const
Get a MagResult from the given record.
NoThrowOnNegativeFluxContext()
virtual void set(afw::table::BaseRecord &record, MagResult const &magResult) const
Set a MagResult in the given record.
iterator end()
Iterator access.
static bool getThrowOnNegativeFlux()
Tell me whether Calib will throw an exception if asked to convert a flux to a magnitude.
Key< T > addField(Field< T > const &field, bool doReplace=false)
Add a new field to the Schema, and return the associated Key.
FluxErrElement fluxSigma
1-Sigma error (sqrt of variance) on flux in DN.
~NoThrowOnNegativeFluxContext()
afw::table::Key< FluxErrElement > _fluxSigma
A reusable result struct for flux measurements.
double getMagnitude(double const flux) const
Return a magnitude given a flux.