asc:tutorials:2014october28
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
asc:tutorials:2014october28 [2014/10/28 19:47] – [Lesson 3: C++/ROOT program to read xAOD] asc | asc:tutorials:2014october28 [2014/10/28 20:47] – [Lesson 3: C++/ROOT program to read xAOD] asc | ||
---|---|---|---|
Line 95: | Line 95: | ||
__Method 1. If you are at ANL, copy it__: | __Method 1. If you are at ANL, copy it__: | ||
<code bash> | <code bash> | ||
- | cp / | + | cp / |
- | AOD.01482225._000140.pool.root | + | |
</ | </ | ||
Line 104: | Line 103: | ||
localSetupFAX --rootVersion=current-SL6 | localSetupFAX --rootVersion=current-SL6 | ||
voms-proxy-init -voms atlas | voms-proxy-init -voms atlas | ||
- | xrdcp $STORAGEPREFIX/ | + | xrdcp $STORAGEPREFIX/ |
</ | </ | ||
Line 120: | Line 119: | ||
setMeUpData anl-oct2014 mydata | setMeUpData anl-oct2014 mydata | ||
</ | </ | ||
- | The file will appear in " | + | The file will appear in " |
Line 196: | Line 195: | ||
Using this code, one can fill histograms. But the code runs slow. Below we will show how to use C++/ROOT compiled code to | Using this code, one can fill histograms. But the code runs slow. Below we will show how to use C++/ROOT compiled code to | ||
run over this file. | run over this file. | ||
+ | |||
+ | How do you know about methods of " | ||
+ | |||
+ | <code python> | ||
+ | print dir(el.trackParticle()) | ||
+ | </ | ||
How will you find xAOD variables without using ROOT TBrowser? Try this code: | How will you find xAOD variables without using ROOT TBrowser? Try this code: | ||
Line 204: | Line 209: | ||
</ | </ | ||
- | You will see a table with the names of the variables. | + | |
+ | <note warning> | ||
+ | To run the next example, please start from a new terminal, run rcSetup. This is needed to avoid a conflict with asetup</ | ||
Now you can fill a histogram in this Python code. You should create a histogram before the event loop: | Now you can fill a histogram in this Python code. You should create a histogram before the event loop: | ||
Line 285: | Line 293: | ||
python Make_input < | python Make_input < | ||
</ | </ | ||
+ | |||
+ | In case if you need xAOD data, do this: | ||
+ | |||
+ | <code bash> | ||
+ | mkdir data | ||
+ | cd data | ||
+ | localSetupFAX --rootVersion=current-SL6 | ||
+ | voms-proxy-init -voms atlas | ||
+ | xrdcp $STORAGEPREFIX/ | ||
+ | xrdcp $STORAGEPREFIX/ | ||
+ | xrdcp $STORAGEPREFIX/ | ||
+ | </ | ||
+ | |||
+ | and run: | ||
+ | |||
+ | < | ||
+ | cd .. | ||
+ | python Make_input data | ||
+ | </ | ||
+ | Now inputdata.txt should pick up your xAOD files. | ||
+ | |||
+ | |||
Now the input file is ready and we run the example as: | Now the input file is ready and we run the example as: | ||
asc/tutorials/2014october28.txt · Last modified: 2014/10/29 13:55 by asc