Giter VIP home page Giter VIP logo

ttcmsdas's Introduction

Download the code

Download the code from github:

git clone https://github.com/GonzalezFJR/ttCMSDAS.git

or using ssh:

git clone [email protected]:GonzalezFJR/ttCMSDAS.git

The analysis

By default, the output of the analysis are histograms, filled at different levels of selection. The MC histograms are normalized to 1 pb-1 for a given input cross section. The weight is computed as:

self.weight = (cross\_section * genWeight)/(sum\_of\_gen\_weights)

Anyway, this is fully customizable.

Run the test

cd test/

This is an easy analysis that selects events with two leptons and save two histograms for the lepton pT and invariant mass. You can run the analysis by executing the file executeTest.sh:

source executeTest.sh

Or just executing the command:

python -c 'from testAnalysis import testAnalysis; testAnalysis("/gpfs/ddn/cms/user/cmsdas/2019/ttbar/dilepton_skim/", "DYJetsToLL_MLL50", eventRange = [0, 100000], xsec = 10, run = True, nSlots = 4)'

If you are not running on lxplus or you wish to run on another sample, just modify the path and sample name. By default, divides the sample in 4 pieces. The output is saved in a folder called temp. You can merge the output rootfiles:

python ../framework/merger.py -frv temp/

Secuential or multicore processing

Example of how to run the analysis on a sample (WWTo2L2Nu):

python -c 'from myAnalysis import myAnalysis; myAnalysis("/gpfs/ddn/cms/user/cmsdas/2019/ttbar/dilepton_skim/", "WWTo2L2Nu", xsec = 10, run = True)'

Example of how to run the analysis on a sample (WWTo2L2Nu) using :

python -c 'from myAnalysis import myAnalysis; myAnalysis("/gpfs/ddn/cms/user/cmsdas/2019/ttbar/dilepton_skim/", "WWTo2L2Nu", xsec = 10, nSlots = 5, run = True)'

Merge the rootfiles

You can automatically merge any number of rootfies with a name SAMPLE_[number].root into a SAMPLE.root file. Use the command:

python framework/merge.py [folder]

Explore the trees

You can explore the input samples and trees by executing the following python scritp:

python framework/fileReader.py

ttcmsdas's People

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.