-
- Downloads
Merge pull request #19 from lcorcodilos/module_dev
# Change log Added tested C++ modules (with documentation) and documented those that existed without docs. Testing obviously led to other fixes and improvements throughout. ## Setup/install - Added `boost` dependency information to main README.md (needed for `LumiFilter.h`) ## Modules - Added **GenMatching.h** which can be used to reconstruct the entire generator particle decay tree from the mother indexes stored in the NanoAOD. This is useful for traversing the entire decay chain with relative ease. Example added in `How to use GenMatching.h`. - Added **LumiFilter.h** which can be used in conjunction with the newly added golden JSONs to filter data based on the JSONs. - Added **HistLoader.h** which can be used to load in a histogram once before processing, with access to the histogram via the class methods while looping over the RDataFrame entries. The `eval` module returns based on the input axis value and `eval_bybin` returns based on the provided bin number. - Added **TopPt_weight.cc** which calculates the top pT correction from the [TOP group](https://twiki.cern.ch/twiki/bin/viewauth/CMS/TopPtReweighting) based on the data/POWHEG+Pythia8 fit. The nominal correction is calculated with the `corr()` method and variations of the constants in the exponential form can be calculated using the `alpha()` and `beta()` methods. - Added **Trigger_weight.cc** which is uses `HistLoader.h` to load a trigger efficiency histogram. The `eval()` method returns the efficiency for that event (based on the input variable, of course) and calculates the uncertainty as one-half the trigger inefficiency. - **Rename "analyzer" namespace to "hardware" in `common.h`**. Done for clarity in the documentation to avoid confusion with the `Analyzer` python namespace (aka Analyzer.py). - Change `hardware::invariantMass()` argument to be a vector of Lorentz vectors. Invariant mass of all provided vectors is calculated. - Moved `Framework/src/Collection.cc` to `Framework/include/Collection.h` ## Testing - Added a draft of **test_modules.py** which features an example for TopPt_weight.cc but it is currently commented out because the test file does not have the `GenPart` collection or the `FatJet` collection (and is also not a ttbar set) - Added **make_test_file.py** to make a small testing histogram. - Added small testing histogram generated by `make_test_file.py`. ## Data - Added golden JSONs for 2017 and 2018 and added info to the README ledger. It seems 2016 does not have a golden JSON anymore (?) ## Analyzer - Add `corr` type for `Correction()` class. It represents a corrections with no uncertainty. The clang parsing CANNOT currently derive it automatically from the C++ script but it can be assigned as the `corrtype` via the argument to `Correction()` constructor. - Optimized `MakeTemplateHistos()` to book histogram actions before looping. They previously looped over the dataframe one after the other. This provides a significant speed up. ## More documentation - Added page on how to use GenMatching.h in a custom C++ module with the example of finding how many prongs are merged in a top jet. - Added docs to `Pythonic.h` - Added docs to `common.h` - Added docs to `PDFweight_uncert.cc` - Added docs to `SJBtag_SF.cc` - Consolidate the READMEs for sections so the webpage makes more sense. - Switch to MathJax for formula rendering ## Small bug fixes - More robust python version checking for ASCII encoding in `OpenJSON()`.
Showing
- README.md 4 additions, 0 deletionsREADME.md
- TIMBER/Analyzer.py 35 additions, 18 deletionsTIMBER/Analyzer.py
- TIMBER/Framework/GenMatching.md 136 additions, 0 deletionsTIMBER/Framework/GenMatching.md
- TIMBER/Framework/README.md 2 additions, 4 deletionsTIMBER/Framework/README.md
- TIMBER/Framework/in_development/TopPt_weight.cc 0 additions, 56 deletionsTIMBER/Framework/in_development/TopPt_weight.cc
- TIMBER/Framework/in_development/Trigger_weight.cc 0 additions, 39 deletionsTIMBER/Framework/in_development/Trigger_weight.cc
- TIMBER/Framework/include/Collection.h 19 additions, 0 deletionsTIMBER/Framework/include/Collection.h
- TIMBER/Framework/include/GenMatching.h 416 additions, 0 deletionsTIMBER/Framework/include/GenMatching.h
- TIMBER/Framework/include/LumiFilter.h 74 additions, 0 deletionsTIMBER/Framework/include/LumiFilter.h
- TIMBER/Framework/include/Pythonic.h 67 additions, 6 deletionsTIMBER/Framework/include/Pythonic.h
- TIMBER/Framework/include/common.h 72 additions, 39 deletionsTIMBER/Framework/include/common.h
- TIMBER/Framework/src/HistLoader.cc 120 additions, 0 deletionsTIMBER/Framework/src/HistLoader.cc
- TIMBER/Framework/src/PDFweight_uncert.cc 29 additions, 10 deletionsTIMBER/Framework/src/PDFweight_uncert.cc
- TIMBER/Framework/src/SJBtag_SF.cc 19 additions, 0 deletionsTIMBER/Framework/src/SJBtag_SF.cc
- TIMBER/Framework/src/TopPt_weight.cc 185 additions, 0 deletionsTIMBER/Framework/src/TopPt_weight.cc
- TIMBER/Framework/src/Trigger_weight.cc 79 additions, 0 deletionsTIMBER/Framework/src/Trigger_weight.cc
- TIMBER/Tools/Common.py 7 additions, 20 deletionsTIMBER/Tools/Common.py
- TIMBER/data/LumiJSON/Cert_294927-306462_13TeV_EOY2017ReReco_Collisions17_JSON.txt 1 addition, 0 deletions...t_294927-306462_13TeV_EOY2017ReReco_Collisions17_JSON.txt
- TIMBER/data/LumiJSON/Cert_314472-325175_13TeV_17SeptEarlyReReco2018ABC_PromptEraD_Collisions18_JSON.txt 1 addition, 0 deletions...17SeptEarlyReReco2018ABC_PromptEraD_Collisions18_JSON.txt
- TIMBER/data/OfficialSFs/README.md 0 additions, 8 deletionsTIMBER/data/OfficialSFs/README.md
Loading
Please register or sign in to comment