Skip to content

romeof/PicoFrameworkOld

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 

Repository files navigation

PicoFramework/TreeProducer

It reads centrally-produced NanoAOD and saves the information you need in your analysis-tree. The master branch contains a very simple example of analysis selecting 2 muons. Hints are provided for exending it to the case of an analysis interested in multi-channels (e.g. ee,mumu or tautau->tauhtauh, mutauh, eletauh, elemu).

Installation

Install CMSSW

scram p -n CMSSW_10_2_9_Label CMSSW CMSSW_10_2_9 #It is the equivalent of cmsrel CMSSW_10_2_9, with the possibility to add a "Label" to the working directory.
cd CMSSW_10_2_9_Label/src
cmsenv

Install the centrally-maintained PhysicsTools/NanoAODTools

git cms-init #not really needed unless you later want to add some other cmssw stuff
git clone https://github.com/cms-nanoAOD/nanoAOD-tools.git PhysicsTools/NanoAODTools

Install the framework PicoFramework/TreeProducer

git clone https://github.com/romeof/PicoFramework.git PicoFramework

Make PhysicsTools/NanoAODTools compatible with PicoFramework/TreeProducer

cp ./PicoFramework/TreeProducer/utils/postprocessor.py ./PhysicsTools/NanoAODTools/python/postprocessing/framework/postprocessor.py

Compile all

scram b 

Analysis code

The files you are interested in to set up your analysis are in PicoFramework/TreeProducer/python. They are

analyzer.py Here you fix your analysis deciding analysis quantities (e.g. mu_minPt), input files, and modules (how to process the events).

ModuleMuMu.py Here you implement the code on how to process the events (e.g. dimuon selection).

TreeProducerMuMu.py Here you specify the quantities you want to save.

TreeProducerCommon.py Here you implement the functions useful for your analysis.

Run

Locally

In PicoFramework/TreeProducer/python

Note that you need p = PostProcessor(outputDir=".",inputFiles=infiles,modules=[module2run()],noOut=True) in analyzer.py. This can be automatized.

python analyzer.py

Crab

In PicoFramework/TreeProducer/crab

Note that you need p = PostProcessor(outputDir=".",inputFiles=inputFiles(),modules=[module2run()],noOut=True,fwkJobReport=True) in analyzer.py. This can be automatized.

python multicrab.py

Notes

NanoAOD

More notes.

Samples

Luminosity

Pileup

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published