The Velo/VeloFullDataMonitor package

This package has been provided for the analysis of non-zero suppressed data (NZS) within VETRA. On this page we introduce its simple structure and explain how you can modify it (write your c/c++) for your purposes.

~lhcbvelo/scripts/startACDC.csh 
cd $VELOFULLDATAMONITORROOT/src

The structure of Velo/VeloFullDataMonitor

If you look in the src directory of this package you will see several classes. Each bit of independant analysis of the NZS data has its own class; this keeps the code modular and easier to understand. Each analysis class inherits a base class which, in turn, inherits from GaudiTupleAlg.

The functions of the base class are:

  • interact with the event store, to 'get' the data
  • to put the data into simple-to-understand vectors ready to be delivered to the analysis algorthm
  • perform some simple and general manipulation from which several algorthms will benefit (eg. common-mode noise suppression). This is to avoid duplication of code in many algorithms.

The execution of the FullDataMonitor is guided by the options file options/VeloFullDataMonitor.opts. Here you will see that the same algorithms can be reused for many TELL1s just by creating multiple instances (with different names, of course!) and making sure the correct TELL1 number is set in each instance of the algorithm.

How to add your code

In short, use the FullDataMonitorExample class as a template.

Please take a look at FullDataMonitorExample.h. Note that, like any other algorthm in Gaudi it has an intialize() (that is run at the beginning of running, a execute() that is run once every event and a _finalize(). Also note that the this algorithm does indeed inherit from the base class: FullDataMonitorBase.

Now look at the execute() method in FullDataMonitorExample.cpp. The general flow of the this example is as follows:

  1. run the execute() method of the base class. This will get the data [ADC counts] from the event store and put them in convenient vectors
  2. get a vector of data that is ready for processing. In this example the data is in the form of a sdataVecVec. This is a "vector of vectors of data" or a 2D matrix, if you like. Its structure is a vector containing 64 vectors of integers, each 32 in length. This structure comes from the fact that the TELL1 processes data from 64 analogue links, each carrying data from 32 Beetle channels.
  3. loop over 2048 channels (64x32) and plot something. Now that the use of the plot() method is encouraged as demonstrated in this example.
  4. histograms will be placed in the output root file at the location file:/Vetra/ so it is important that the instance of your algorithm is unambiguously named.

Please send all comment and questions to me: malcolm.john@cernNOSPAMNOSPAMPLEASE.ch

-- Malcolm John - 17 Jul 2006

Edit | Attach | Watch | Print version | History: r5 < r4 < r3 < r2 < r1 | Backlinks | Raw View | WYSIWYG | More topic actions
Topic revision: r5 - 2006-11-09 - MalcolmJohn
 
    • Cern Search Icon Cern Search
    • TWiki Search Icon TWiki Search
    • Google Search Icon Google Search

    LHCb All webs login

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