, view all tags
-- PeterWinter - 16 Feb 2009

This page will keep a description of how I use to create the final lifetime histograms from the output shrubs from ./mta....

Subdividing the data sets into groups of same magnet setting

First thing is to separate the runs into data sets according to Sara's classification scheme. One important step for that is to sort them into according groups of magnet settings (mainly +125A and -125A). That can be done from the MySQL database. The extracted data set files are at ~/jobscripts/lists/datasets. The files in there are named prod_rn10_mu+_a_125 or prod_rn11_mu-_c and comprise a list of run numbers that belong to this data set.

Creating the links

After the mta has produced the intermediate shrubs, it might be necessary to create appropriate links to the data sets. The original trees live usually on Abe in /cfs/projects/lqo/bkiburg/run11_4/treepass2/mta/, where treepass2 must be replaced with the according production that you are interested (currently ProdMay09). Then, to create the links for each of the data sets, I have a macro in /u/ac/pwinter/jobscripts called MakeLinksForDatasets.pl. It will make the links according to the run numbers that are listed in the current $datasetfile = $HOME."/jobscripts/lists/datasets/".$dataset.".txt"; . To for example create the links for run 10 data set a_125 for mu+, you have to run: > ./MakeLinksForDatasets.pl 11 prod_rn11_mu+_a_125 Pixel_;
Here the argument 11 denotes that this is run 11. The second argument is the data set name and the last states, that you want to do this for the Pixel shrubs, i.e. the Pixel_treeNNNNN.root files. You might need to adapt some directory paths in the script to your needs.

Merging the shrubs on the nodes and transfering to NPL

I have combined these steps into one macro

Conversion to lifetime histograms

  1. In order to create histograms, I have a script on NPL at ~/jobscripts/MakeHistogramExe.pl. If you run it, it requires thre input parameters:
    MakeHistogramExe.pl input_directory data_set_name prefix where
    • input_directory: Is the directory, where your shrub files are
    • data_set_name: It's the name of the current data_set
    • prefix: Is the beginning of your shrub file names before the run number, i.e. if your shrubs are Pixel_34536-36776.root, then prefix="Pixel_"
      If you run this script, it will loop over all the root files with this prefix and create a HistogramCreation _$data_set_name.pl file. You might need to adapt the script since it now expects shrub file names with a range of run numbers, i.e. Pixel_34536-36776.root rather than Pixel_34536.root! You should also edit the output directory in this MakeHistogramExe.pl to match your needs.
  2. You can now launch the HistCreate_$data_set_name.pl files from the step before. This script expects a single argument indicating which of the root files that were found in the step above to run, i.e. 0=first ROOT file, 1=second ROOT file etc.
    Launching can be done with a small condor job. Use the launch_condor example setup file from CVS and change necessary directories/paths in there to adapt to your needs.
    The HistCreate_$data_set_name.pl will then call a ROOT script with appropriate arguments. This CreateHistogramsFromTreeWithLoop.C will mainly produce various TH3 histogams with the axis:
    • x-axis: Time dt (electron-muon)
    • y-axis: Some parameter of your choice like gondola number, nContEH, extraEL (Depending on what you want to do, you need to create other histograms with the y-axis being adapted to the parameter of interest.)
    • z-axis: TPC subvolume number

Fitting the data using the class TAllScans

Parameter scan for nContEH, nExtraEL

Gondola scan

Edit | Attach | Watch | Print version | History: r12 < r11 < r10 < r9 < r8 | Backlinks | Raw View | Raw edit | More topic actions...
Topic revision: r9 - 2009-07-23 - PeterWinter
  • Edit
  • Attach
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2020 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback