Implements reweighting to account for self-veto due to ECAL L1T prefiring. More...
#include <L1TPrefiringWeight.h>
Public Member Functions | |
L1TPrefiringWeight (Dataset &dataset, Options const &options) | |
virtual double | NominalWeight () const override |
Returns nominal weight for the current event. | |
virtual int | NumVariations () const override |
Returns number of supported systematic variations. | |
virtual double | operator() () const override |
Returns the default weight. | |
virtual double | RelWeight (int variation) const override |
Returns relative weight for requested systematic variation. | |
virtual std::string_view | VariationName (int variation) const override |
Returns the label of the systematic variation with the given index. | |
Private Attributes | |
bool | enabled_ |
std::optional < TTreeReaderValue< Float_t > > | srcWeightNominal_ |
std::optional < TTreeReaderValue< Float_t > > | srcWeightUp_ |
std::optional < TTreeReaderValue< Float_t > > | srcWeightDown_ |
TTreeReaderValue< Float_t > * | defaultWeight_ |
Non-owning pointer to one of the source weights. |
Implements reweighting to account for self-veto due to ECAL L1T prefiring.
The prefiring problem is described here. The reweighting is enabled only when running on simulation and only if the master configuration contains key l1t_prefiring
set to true.
virtual int L1TPrefiringWeight::NumVariations | ( | ) | const [inline, override, virtual] |
Returns number of supported systematic variations.
Up and down variations are counted separately. The nominal weight is not included.
Reimplemented from WeightBase.
virtual double L1TPrefiringWeight::operator() | ( | ) | const [inline, override, virtual] |
Returns the default weight.
This might be different from the nominal weight if a specific variation has been requested via command line options.
Reimplemented from WeightBase.
double L1TPrefiringWeight::RelWeight | ( | int | ) | const [override, virtual] |
Returns relative weight for requested systematic variation.
The relative weight is computed with respect to the nominal weight. The argument must satisfy 0 <= variation < NumVariations()
.
Reimplemented from WeightBase.
std::string_view L1TPrefiringWeight::VariationName | ( | int | ) | const [override, virtual] |
Returns the label of the systematic variation with the given index.
If the variation has the meaning of an "up" or "down" one, the label must end with "_up" or "_down" respectively. The argument must satisfy 0 <= variation < NumVariations()
.
Reimplemented from WeightBase.
TTreeReaderValue<Float_t>* L1TPrefiringWeight::defaultWeight_ [private] |
Non-owning pointer to one of the source weights.
Used to provide the default weight by operator(). Only initialized if the reweighting is enabled.