Hyperiso 1.0.3
Modular flavour-physics calculations, Wilson coefficients and statistical inference
Loading...
Searching...
No Matches
LambdaObservableConfig Struct Reference

Registration and compute function for one runtime/custom observable. More...

#include <LambdaDecay.h>

Public Member Functions

 LambdaObservableConfig ()=default
 
 LambdaObservableConfig (std::string canonical_, LambdaObservableComputer compute_)
 Construct a custom observable from a vector-valued compute lambda.
 

Static Public Member Functions

static LambdaObservableConfig scalar (std::string canonical_, std::function< double(LambdaDecay &, ObservableId)> compute_)
 Convenience factory for a scalar, unbinned observable.
 
static LambdaObservableConfig binned_scalar (std::string canonical_, std::function< double(LambdaDecay &, std::pair< double, double >, ObservableId)> compute_)
 Convenience factory for a scalar binned observable.
 

Public Attributes

std::string canonical
 Canonical observable name, for example "BR_MY_DECAY".
 
std::vector< std::string > aliases {}
 Optional alternative names accepted by ObservableMapper::id_of().
 
std::optional< LhaIDflha = std::nullopt
 Optional FLHA id used for experimental values / binned encodings.
 
std::unordered_set< ParamIddependencies {}
 Optional dependency list used by scans/profilers/likelihood tooling.
 
LambdaObservableComputer compute {}
 User-provided observable computation.
 

Detailed Description

Registration and compute function for one runtime/custom observable.

A LambdaDecay must own at least one LambdaObservableConfig. Each observable is registered dynamically through ObservableMapper and attached to the parent dynamic DecayId through DecayMapper.

Definition at line 59 of file LambdaDecay.h.

Constructor & Destructor Documentation

◆ LambdaObservableConfig() [1/2]

LambdaObservableConfig::LambdaObservableConfig ( )
default

◆ LambdaObservableConfig() [2/2]

LambdaObservableConfig::LambdaObservableConfig ( std::string  canonical_,
LambdaObservableComputer  compute_ 
)
inline

Construct a custom observable from a vector-valued compute lambda.

Definition at line 80 of file LambdaDecay.h.

Member Function Documentation

◆ binned_scalar()

LambdaObservableConfig LambdaObservableConfig::binned_scalar ( std::string  canonical_,
std::function< double(LambdaDecay &, std::pair< double, double >, ObservableId)>  compute_ 
)
inlinestatic

Convenience factory for a scalar binned observable.

If bins were registered on the decay through ObsManager::add_obs(BinnedObservableId), the lambda is evaluated once per bin and the returned ObservableValue stores the corresponding bin. Without bins, it behaves like a scalar observable and calls the lambda with the conventional bin {0,0}.

Definition at line 310 of file LambdaDecay.h.

◆ scalar()

static LambdaObservableConfig LambdaObservableConfig::scalar ( std::string  canonical_,
std::function< double(LambdaDecay &, ObservableId)>  compute_ 
)
inlinestatic

Convenience factory for a scalar, unbinned observable.

The user lambda returns only the central value. The factory wraps it into a single ObservableValue whose id is the dynamic id passed at evaluation.

Definition at line 89 of file LambdaDecay.h.

Member Data Documentation

◆ aliases

std::vector<std::string> LambdaObservableConfig::aliases {}

Optional alternative names accepted by ObservableMapper::id_of().

Definition at line 64 of file LambdaDecay.h.

◆ canonical

std::string LambdaObservableConfig::canonical

Canonical observable name, for example "BR_MY_DECAY".

Definition at line 61 of file LambdaDecay.h.

◆ compute

LambdaObservableComputer LambdaObservableConfig::compute {}

User-provided observable computation.

Definition at line 73 of file LambdaDecay.h.

◆ dependencies

std::unordered_set<ParamId> LambdaObservableConfig::dependencies {}

Optional dependency list used by scans/profilers/likelihood tooling.

Definition at line 70 of file LambdaDecay.h.

◆ flha

std::optional<LhaID> LambdaObservableConfig::flha = std::nullopt

Optional FLHA id used for experimental values / binned encodings.

Definition at line 67 of file LambdaDecay.h.


The documentation for this struct was generated from the following file: