An IntegralModel that returns a Parameter-dependent fraction of the flux of another IntegralModel.
More...
#include <fractionalintegralmodel.h>
|
|
typedef std::pair< std::reference_wrapper< const Channel >, std::shared_ptr< ProperFractionParameterD > > | ChannelIntegralParameterD |
|
typedef std::vector< ChannelIntegralParameterD > | Data |
|
|
| FractionalIntegralModel (const FractionalIntegralModel &)=delete |
|
FractionalIntegralModel & | operator= (const FractionalIntegralModel &)=delete |
|
std::shared_ptr< ProperFractionParameterD > | at (const Channel &channel) |
|
std::shared_ptr< const ProperFractionParameterD > | at (const Channel &channel) const |
|
Data::iterator | begin () noexcept |
|
Data::const_iterator | cbegin () const noexcept |
|
Data::iterator | end () noexcept |
|
Data::const_iterator | cend () const noexcept |
| std::vector< std::reference_wrapper< const Channel > > | get_channels () const override |
| | Get the set of channels this instance is applicable for.
|
|
const IntegralModel & | get_parent_model () const |
| double | get_integral (const Channel &channel) const override |
| | Get the value of the integral in a single Channel.
|
| std::vector< std::pair< ParamBaseCRef, ExtraParamFactorValues > > | get_integral_derivative_factors (const Channel &channel) const override |
| | Return the partial derivative of the model w.r.t. each metaparameter.
|
|
double | get_integral_remainder (const Channel &channel) const |
|
ProperFractionParameterD & | get_parameter_frac (const Channel &channel) const |
| ParamRefs & | get_parameters (ParamRefs ¶ms, ParamFilter *filter=nullptr) const override |
| ParamCRefs & | get_parameters_const (ParamCRefs ¶ms, ParamFilter *filter=nullptr) const override |
| | Same as get_parameters(), but for const refs.
|
|
bool | is_final () const |
|
size_t | size () const |
|
std::string | repr (bool name_keywords=false, std::string_view namespace_separator=Object::CC_NAMESPACE_SEPARATOR) const override |
|
std::string | str () const override |
|
ParamRefs | get_parameters_new (ParamFilter *filter=nullptr) const |
| | Same as get_parameters(), but returning a new vector.
|
|
ParamCRefs | get_parameters_const_new (ParamFilter *filter=nullptr) const |
| | Same as get_parameters_const(), but returning a new vector.
|
|
| static std::shared_ptr< FractionalIntegralModel > | find_model (const IntegralModel &model) |
| static std::shared_ptr< FractionalIntegralModel > | make (std::optional< const Data > data, std::shared_ptr< const IntegralModel > model, bool is_final=false) |
|
static const std::shared_ptr< const FractionalIntegralModel > | make_const (std::optional< const Data > data, std::shared_ptr< const IntegralModel > model, bool is_final=false) |
An IntegralModel that returns a Parameter-dependent fraction of the flux of another IntegralModel.
FractionalIntegralModel instances can be chained but are registered to enforce having at most one dependent FractionalIntegralModel. Chains should end in a single fixed ProperFractionParameter of value 1; this is not yet fully enforced.
- Note
- For longer chains, a single ProperFractionParameter of value 1 will render all downstream models zero-valued, regardless of their own ProperFractionParameter values. Consider setting Limits to prevent such situations if they become problematic.
◆ find_model()
| std::shared_ptr< FractionalIntegralModel > lsst::gauss2d::fit::FractionalIntegralModel::find_model |
( |
const IntegralModel & | model | ) |
|
|
inlinestatic |
◆ get_channels()
| std::vector< std::reference_wrapper< const Channel > > lsst::gauss2d::fit::FractionalIntegralModel::get_channels |
( |
| ) |
const |
|
overridevirtual |
Get the set of channels this instance is applicable for.
- Note
- Implementers must return a set (all unique items). This cannot be enforced (yet).
Implements lsst::gauss2d::fit::Chromatic.
◆ get_integral()
| double lsst::gauss2d::fit::FractionalIntegralModel::get_integral |
( |
const Channel & | channel | ) |
const |
|
overridevirtual |
◆ get_integral_derivative_factors()
| std::vector< std::pair< ParamBaseCRef, ExtraParamFactorValues > > lsst::gauss2d::fit::FractionalIntegralModel::get_integral_derivative_factors |
( |
const Channel & | channel | ) |
const |
|
overridevirtual |
Return the partial derivative of the model w.r.t. each metaparameter.
This is generally needed only for nonlinear Parameter instances.
- Parameters
-
| channel | The Channel to return derivatives for. |
- Returns
- A vector of Parameter/derivative pairs, with values ordered as specified in GaussianEvaluator (L, sigma_x, sigma_y).
Implements lsst::gauss2d::fit::IntegralModel.
◆ get_parameters()
| ParamRefs & lsst::gauss2d::fit::FractionalIntegralModel::get_parameters |
( |
ParamRefs & | params, |
|
|
ParamFilter * | filter = nullptr ) const |
|
overridevirtual |
Add Parameter refs matching the filter to a vector, in order.
- Parameters
-
| params | The vector to add to. |
| filter | The filter to apply to this Object's parameters. |
- Returns
- A ref to params (for method chaining)
Implements lsst::gauss2d::fit::Parametric.
◆ get_parameters_const()
| ParamCRefs & lsst::gauss2d::fit::FractionalIntegralModel::get_parameters_const |
( |
ParamCRefs & | params, |
|
|
ParamFilter * | filter = nullptr ) const |
|
overridevirtual |
◆ make()
| std::shared_ptr< FractionalIntegralModel > lsst::gauss2d::fit::FractionalIntegralModel::make |
( |
std::optional< const Data > | data, |
|
|
std::shared_ptr< const IntegralModel > | model, |
|
|
bool | is_final = false ) |
|
static |
Construct a FractionalIntegralModel and add to registry
- Parameters
-
| data | The map of ProperFractionParameter instances for each channel. |
| model | The IntegralModel that ProperFractionParameter instances multiply by. |
| is_final | Whether these fractions are the last in the chain. |
- Note
- Input parameters are validated and will throw exceptions if invalid, e.g. if data and model do not cover the same channels.
- Returns
- A new FractionalIntegralModel instance
The documentation for this class was generated from the following files: