Difference: WorkBookMuonAnalysis (91 vs. 92)

Revision 922017-08-30 - JhovannyMejia

Line: 1 to 1
 
META TOPICPARENT name="WorkBook"

7.8 Muon Analysis

<!-- Enter an integer between 0 (zero) and 5 after the word COMPLETE, below, to indicate how complete the page/topic is; 0 means empty, 1 is for very incomplete, ascending to 5 for complete.  -->
Changed:
<
<
Complete: 5
>
>
Complete: 4
 

Detailed Review status

Line: 194 to 194
 

Examples

Changed:
<
<
The example provided is for FWLite since it allows for quick demonstration of some basic concepts on how to get access to information. The framework side of the code is fairly similar. See SWGuideFWLite for details. Let's assume that you have some collection or local data file that you want to look at. To get a proper path so that FWLite can open the collection one can use EdmFileUtil:

> EdmFileUtil -d /store/mc/2007/10/20/RelVal-RelValTTbar-1192895175/0000
/00C41641-2A81-DC11-B6EA-0019DB29C620.root

dcap://cmsdca3.fnal.gov:24142/pnfs/fnal.gov/usr/cms/WAX/11/store/mc/2007/10/20/
RelVal-RelValTTbar-1192895175/0000/00C41641-2A81-DC11-B6EA-0019DB29C620.root

Now start ROOT in the project area of one of the recent releases and enable Cintex, load FWLite library, enable auto-loading and load the file:

root [0] Cintex::Enable()
root [1] gSystem->Load("libFWCoreFWLite");
root [2] AutoLibraryLoader::enable();
root [3] f = TFile::Open("events.root")

For each muon candidate in the event, let's look at the global-muon pT, inner-track pT, and ECAL energy deposition associated with the candidate:

root [4] Events->Scan("muons.globalTrack().pt():muons.innerTrack().pt():muons.calEnergy().em")
***********************************************************
*    Row   * Instance * muons.p4( * muons.tra * muons.get *
***********************************************************
*        0 *        0 * 26.570809 * 26.387926 * 0.1964492 *
*        1 *        0 * 9.6703965 * 9.6947574 * 5.2962083 *
*        1 *        1 * 25.099496 * 25.039489 * 0.3504051 *

Isolation variables for the muon candidates (e.g., sum of pT's of tracks and sum of ET's for ECAL in a cone of R = 0.5) can be obtained with the following command:

root [5] Events->Scan("muons.isolationR05().sumPt:muons.isolationR05().emEt")
***********************************************
*    Row   * Instance * muons.get * muons.get *
***********************************************
*        0 *        0 *         0 * 4.5468702 *
*        1 *        0 * 16.282365 * 66.035476 *
*        1 *        1 * 7.0197601 * 2.9328436 *
>
>
The example provided is for "CMSSW_9_2_3_patch2", it allows for quick demonstration of some basic concepts on how to get access to information.
We will created an EDAnalyzer within our CMSSW work area. The analyzer should iterate over the reconstructed muons stored in the miniAOD and fill histograms with the momenta components of the reconstructed muons. Use the TFileService object to store the histograms. We also make a vertex to reconstruct the "Jpsi" particle (see figure).
source /cvmfs/cms.cern.ch/cmsset_default.sh 
export SCRAM_ARCH=slc6_amd64_gcc530
cmsrel CMSSW_9_2_3_patch2
cd CMSSW_9_2_3_patch2/src/
cp -r /afs/cern.ch/user/j/jmejiagu/public/miniAODmuonexample/CMSSW_9_2_3_patch2/src/myAnalyzers .
cmsenv
voms-proxy-init -voms cms -valid 192:00
scram b -j8
cd myAnalyzers/JPsiKsPAT/test/
cmsRun miniAODmuonsRootupler.py
 

Review status

Reviewer/Editor and Date (copy from screen) Comments
Line: 251 to 211
 
MartijnMulders - 07 Oct 2008 Updated muon identification part
SlavaValuev - Feb 2009 Updated in course of documentation review
PiotrTraczyk - 31 Aug 2010 Muon timing part made up-to-date
Added:
>
>
JhovannyMejia 30 Aug 2017 Some information made up-to-date. Update all the links. Create a example on how to get access to Muon information in the miniAOD.
 Responsible: DmytroKovalskyi
Last reviewed by: SlavaValuev - 04 Mar 2009
Line: 258 to 219
 
META FILEATTACHMENT attr="" autoattached="1" comment="" date="1160411299" name="res.gif" path="res.gif" size="10441" user="Main.RiccardoBellan" version="1"
META FILEATTACHMENT attachment="muonreco.png" attr="" comment="Muon reconstruction overview" date="1203229923" name="muonreco.png" path="muonreco.png" size="6064" stream="muonreco.png" user="Main.DmytroKovalskyi" version="2"
META FILEATTACHMENT attachment="lastLoose.gif" attr="" comment="" date="1289567615" name="lastLoose.gif" path="lastLoose.gif" size="7848" stream="lastLoose.gif" tmpFilename="/usr/tmp/CGItemp489" user="pshukla" version="1"
Added:
>
>
META FILEATTACHMENT attachment="Jpsimass.png" attr="" comment="" date="1504057290" name="Jpsimass.png" path="Jpsimass.png" size="3888" user="jmejiagu" version="1"
 
META TOPICMOVED by="CMSUserSupport" date="1203411004" from="WorkBookMuonGlobalReco" to="WorkBookMuonAnalysis"
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright & 2008-2019 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback