1 #ifndef ConfigurationBase_h 2 #define ConfigurationBase_h 11 #include <BasicTypes.hxx> 12 #include "SystematicManager.hxx" 13 #include "ToyMaker.hxx" 16 const UInt_t NMAXPARAMETERS = 500;
25 Float_t variations[NMAXPARAMETERS];
26 Float_t weights[NMAXPARAMETERS];
27 Int_t par_index[NMAXPARAMETERS];
37 ConfigurationBase(Int_t index,
const std::string& conf_name, UInt_t ntoys=1, Int_t randomSeed=-1,
ToyMaker* toyMaker=NULL);
44 void EnableSystematics(
const std::vector<Int_t>& indices);
90 bool IsEnabled()
const {
return _enabled;}
94 bool GetToyEnabled(Int_t n)
const {
return _toyEnabled[n];}
98 void SetNToys(Int_t ntoys){_ntoys= ntoys;}
105 void SetToyRandomSeed(UInt_t seed){_toy_randomSeed = (Int_t)seed;}
126 const std::string&
Name()
const {
return _name;}
179 std::vector< ToyVariationWrite >
_toys;
std::string _name
Name of the configuration.
void EnableEventWeight(Int_t index)
Enable the systematic registered with the given name.
ToyMaker * _toyMaker
The ToyMaker, which fills the toy.
void SetIndex(Int_t index)
Sets the configuration index.
void EnableEventVariations(const std::vector< Int_t > &indices)
Enable the systematic registered with the given name.
Int_t GetNToys() const
Get and sets the number of toys.
std::vector< Int_t > _systematicsEnabled
Vector of indices of the systematics enabled in this configuration.
std::vector< Int_t > _variationsEnabled
Vector of indices of the variations enabled in this configuration.
void EnableEventVariation(Int_t index)
Enable the systematic registered with the given name.
void SetToyMaker(ToyMaker *toyMaker)
Sets the ToyMaker.
void EnableSystematic(Int_t index)
Enable the systematic registered with the given name.
const std::vector< Int_t > & GetEnabledEventVariations()
Get the variations enabled for this configuration.
ToyMaker & GetToyMaker()
Returns the ToyMaker.
std::vector< Int_t > _weightsEnabled
Vector of indices of the weights enabled in this configuration.
void SetToyEnabled(Int_t n, bool ena)
Set and gets enable flags for a given toy.
void DisableEventVariation(Int_t index)
Disable the systematic registered with the given name.
std::vector< bool > _toyEnabled
Tell wether a toy is enabled or not.
Int_t GetRefToyIndex() const
Returns the refernce toy experiment index.
void DisableAllEventWeights()
Disable the systematic registered with the given name.
A Class that allows saving the variations in the config tree.
const std::string & Name() const
Returns the name of this configuration.
void DisableAllEventVariations()
Disable the systematic registered with the given name.
const std::vector< Int_t > & GetEnabledEventWeights()
Get the weights enabled for this configuration.
Int_t GetToyRandomSeed() const
Get and sets the random seed used to generate the toys.
The maximum number of systematics that is supported.
Int_t GetTreeIndex() const
Returns the index of the tree associated to this configuration in the TreeManager.
std::vector< ToyVariationWrite > _toys
The variations for each of the toys.
Int_t _toy_ref
The reference toy with the nominal selection.
void DisableSystematic(Int_t index)
Disable the systematic registered with the given name.
void DisableAllSystematics()
Disable the systematic registered with the given name.
void SetTreeIndex(Int_t index)
Sets the tree index.
void SetEnabled(bool ena)
Is this configuration enabled ?
void EnableEventWeights(const std::vector< Int_t > &indices)
Enable the systematic registered with the given name.
bool _enabled
Is this configuration enabled ?
const std::vector< Int_t > & GetEnabledSystematics()
Get the systematics enabled for this configuration.
Int_t GetIndex() const
Returns the configuration index (should match the one in the Configuration Manager) ...
Int_t _tree_index
the index of the tree associated to this configuration in the TreeManager
Int_t _conf_index
Configuration index.
void DisableEventWeight(Int_t index)
Disable the systematic registered with the given name.
Int_t _ntoys
Number of Toy experiments or virtual analyses.
Int_t _toy_randomSeed
The random seed used to generate the toys.