23 #if !defined(LSST_DETECTION_THRESHOLD_H) 24 #define LSST_DETECTION_THRESHOLD_H 59 bool const polarity =
true,
60 double const includeMultiplier = 1.0
62 : _value(value), _type(
type), _polarity(polarity), _includeMultiplier(includeMultiplier) {}
81 double getValue(
const double param = -1)
const;
88 template <
typename ImageT>
104 _includeMultiplier = includeMultiplier;
111 double _includeMultiplier;
Threshold(double const value, ThresholdType const type=VALUE, bool const polarity=true, double const includeMultiplier=1.0)
Threshold constructor.
static std::string getTypeString(ThresholdType const &type)
void setIncludeMultiplier(double const includeMultiplier)
set includeMultiplier
bool getPolarity() const noexcept
return Threshold's polarity
Use (pixels & (given mask))
A Threshold is used to pass a threshold value to detection algorithms.
Use number of sigma given s.d.
A base class for image defects.
double getValue(const double param=-1) const
return value of threshold, to be interpreted via type
double getIncludeMultiplier() const noexcept
return includeMultiplier
Threshold createThreshold(const double value, const std::string type="value", const bool polarity=true)
Factory method for creating Threshold objects.
void setPolarity(bool const polarity) noexcept
set Threshold's polarity
ThresholdType
Types of threshold:
Use number of sigma given variance.
static ThresholdType parseTypeString(std::string const &typeStr)
Backwards-compatibility support for depersisting the old Calib (FluxMag0/FluxMag0Err) objects...
Use number of sigma given per-pixel s.d.
~Threshold() noexcept=default
Threshold & operator=(Threshold const &) noexcept=default
ThresholdType getType() const noexcept
return type of threshold