Update 'Utils.hpp'
parent
3fbe51a434
commit
7c6e2305e7
90
Utils.hpp.md
90
Utils.hpp.md
@ -1,3 +1,4 @@
|
|||||||
|
In this file, various helper functions are defined. Unfortunately, as we are trying to compile and run things within ROOT, it is orders of magnitute easier to have the funcitons defined fully in the header. Including cross-refrences with [[Paths.hpp|Paths.hpp]].
|
||||||
|
|
||||||
|
|
||||||
## Global variables:
|
## Global variables:
|
||||||
@ -33,75 +34,13 @@
|
|||||||
|
|
||||||
|
|
||||||
# Functions
|
# Functions
|
||||||
### string GetInputFile()
|
## Basic names and trees
|
||||||
|
|
||||||
* **Parameters**
|
|
||||||
* string year
|
|
||||||
* string magnet
|
|
||||||
* bool preSelected
|
|
||||||
* bool MC
|
|
||||||
* bool ReferenceChannel
|
|
||||||
* bool PHSP
|
|
||||||
* bool B0
|
|
||||||
* bool K1
|
|
||||||
* bool Inc
|
|
||||||
* bool smallSample);
|
|
||||||
* **Return**
|
|
||||||
|
|
||||||
### string GetBDTinputFile()
|
|
||||||
|
|
||||||
* **Parameters**
|
|
||||||
* string year
|
|
||||||
* bool MC
|
|
||||||
* bool ReferenceChannel
|
|
||||||
* bool PHSP
|
|
||||||
* bool KshortDecayInVelo);
|
|
||||||
* **Return**
|
|
||||||
|
|
||||||
### string GetBDToutputFile()
|
|
||||||
|
|
||||||
* **Parameters**
|
|
||||||
* string year
|
|
||||||
* int Run
|
|
||||||
* bool MC
|
|
||||||
* bool ReferenceChannel
|
|
||||||
* bool PHSP
|
|
||||||
* bool KshortDecayInVelo
|
|
||||||
* bool UseLowQ2Range
|
|
||||||
* bool reweighted);
|
|
||||||
* **Return**
|
|
||||||
|
|
||||||
### string GetBDToutputFile()
|
|
||||||
|
|
||||||
* **Parameters**
|
|
||||||
* int Run
|
|
||||||
* bool MC
|
|
||||||
* bool ReferenceChannel
|
|
||||||
* bool PHSP
|
|
||||||
* bool KshortDecayInVelo
|
|
||||||
* bool UseLowQ2Range
|
|
||||||
* bool reweighted);
|
|
||||||
* **Return**
|
|
||||||
|
|
||||||
### string returnFileAddress()
|
|
||||||
|
|
||||||
* **Parameters**
|
|
||||||
* string year
|
|
||||||
* int Run
|
|
||||||
* string magnet
|
|
||||||
* bool Preselected
|
|
||||||
* bool BDTed
|
|
||||||
* bool MC
|
|
||||||
* bool ReferenceChannel
|
|
||||||
* bool PHSP
|
|
||||||
* bool KshortDecayInVelo);
|
|
||||||
* **Return**
|
|
||||||
|
|
||||||
### string correct_magnet_string()
|
### string correct_magnet_string()
|
||||||
|
|
||||||
* **Parameters**
|
* **Parameters**
|
||||||
* string magnet
|
* string magnet
|
||||||
* **Return**
|
* **Return**
|
||||||
|
* Parsed magnet string name
|
||||||
|
|
||||||
### string treeName()
|
### string treeName()
|
||||||
|
|
||||||
@ -109,12 +48,14 @@
|
|||||||
* bool MC
|
* bool MC
|
||||||
* bool Preselected
|
* bool Preselected
|
||||||
* **Return**
|
* **Return**
|
||||||
|
* Correct tree name for given sample
|
||||||
|
|
||||||
### vector \<string> get_magnet_vector()
|
### vector \<string> get_magnet_vector()
|
||||||
|
|
||||||
* **Parameters**
|
* **Parameters**
|
||||||
* string magnet
|
* string magnet (up, down or both)
|
||||||
* **Return**
|
* **Return**
|
||||||
|
* vector of given polarity(ies), either "up", "down" or both
|
||||||
|
|
||||||
### TChain \*get_basic_TChain()
|
### TChain \*get_basic_TChain()
|
||||||
|
|
||||||
@ -129,6 +70,7 @@
|
|||||||
* bool K1
|
* bool K1
|
||||||
* bool Inc
|
* bool Inc
|
||||||
* **Return**
|
* **Return**
|
||||||
|
* TChain of all stripped or preselected events
|
||||||
|
|
||||||
### TChain \*get_weighted_TChain()
|
### TChain \*get_weighted_TChain()
|
||||||
|
|
||||||
@ -139,6 +81,7 @@
|
|||||||
* bool PHSP
|
* bool PHSP
|
||||||
* bool KshortDecayInVelo
|
* bool KshortDecayInVelo
|
||||||
* **Return**
|
* **Return**
|
||||||
|
* TChain of all weighted events
|
||||||
|
|
||||||
### TChain \*get_BDT_TChain()
|
### TChain \*get_BDT_TChain()
|
||||||
|
|
||||||
@ -150,6 +93,7 @@
|
|||||||
* bool KshortDecayInVelo
|
* bool KshortDecayInVelo
|
||||||
* bool reweighted
|
* bool reweighted
|
||||||
* **Return**
|
* **Return**
|
||||||
|
* TChain of all events with their MVA response
|
||||||
|
|
||||||
### TChain \*get_BDT_TChain()
|
### TChain \*get_BDT_TChain()
|
||||||
|
|
||||||
@ -162,6 +106,7 @@
|
|||||||
* bool KshortDecayInVelo
|
* bool KshortDecayInVelo
|
||||||
* bool reweighted
|
* bool reweighted
|
||||||
* **Return**
|
* **Return**
|
||||||
|
* TChain of all events with their MVA response
|
||||||
|
|
||||||
### TChain \*get_FinalOutput_TChain()
|
### TChain \*get_FinalOutput_TChain()
|
||||||
|
|
||||||
@ -172,6 +117,7 @@
|
|||||||
* bool PHSP
|
* bool PHSP
|
||||||
* bool KshortDecayInVelo //TODO fix Run vs year
|
* bool KshortDecayInVelo //TODO fix Run vs year
|
||||||
* **Return**
|
* **Return**
|
||||||
|
* TChain of all events passing the MVA response cut
|
||||||
|
|
||||||
### string getTMcut()
|
### string getTMcut()
|
||||||
|
|
||||||
@ -181,20 +127,16 @@
|
|||||||
* string customTMbranch
|
* string customTMbranch
|
||||||
* bool gammaTM
|
* bool gammaTM
|
||||||
* **Return**
|
* **Return**
|
||||||
|
* String with a ROOT-readable cut on the truth matching variables depending on the input parameters
|
||||||
|
|
||||||
### string getJpsicut()
|
### string getJpsicut()
|
||||||
|
|
||||||
* **Parameters**
|
|
||||||
*
|
|
||||||
* **Return**
|
* **Return**
|
||||||
|
* Cut to keep only the Jpsi Q2 region
|
||||||
|
|
||||||
|
|
||||||
### string getMuMucut()
|
### string getMuMucut()
|
||||||
|
|
||||||
* **Parameters**
|
|
||||||
*
|
|
||||||
* **Return**
|
* **Return**
|
||||||
|
* Cut to remove the resonant (phi, Jpsi and Psi2s) Q2 regions
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -210,6 +152,7 @@
|
|||||||
* int nExtraBin
|
* int nExtraBin
|
||||||
* double TMVAcut
|
* double TMVAcut
|
||||||
* **Return**
|
* **Return**
|
||||||
|
* String with a ROOT-readable cut on Q2, MVA resonse and extra variable in the given bin
|
||||||
|
|
||||||
### string getAloneBranch()
|
### string getAloneBranch()
|
||||||
|
|
||||||
@ -219,6 +162,7 @@
|
|||||||
* string customTMbranch
|
* string customTMbranch
|
||||||
* bool gammaTM
|
* bool gammaTM
|
||||||
* **Return**
|
* **Return**
|
||||||
|
* Returns the branch with the MVA response at which there are no multiple candidates depending on the TM options
|
||||||
|
|
||||||
### string getMultipleCut()
|
### string getMultipleCut()
|
||||||
|
|
||||||
@ -229,6 +173,7 @@
|
|||||||
* bool gammaTM
|
* bool gammaTM
|
||||||
* double TMVAcut
|
* double TMVAcut
|
||||||
* **Return**
|
* **Return**
|
||||||
|
* Reutrns a string with the cut on the corresponding [getAloneBranch()](#string-getalonebranch) depending on the TMVA cut
|
||||||
|
|
||||||
### string getFinalCut()
|
### string getFinalCut()
|
||||||
|
|
||||||
@ -248,6 +193,7 @@
|
|||||||
* double TMVAcut
|
* double TMVAcut
|
||||||
* bool removeMultiple
|
* bool removeMultiple
|
||||||
* **Return**
|
* **Return**
|
||||||
|
* A string combining [getFullCut()](#string-getfullcut), [getTMcut()](#string-gettmcut) and [getMultipleCut()](#string-getmultiplecut)
|
||||||
|
|
||||||
### string checkIf2015MC()
|
### string checkIf2015MC()
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user