If (by chance :-) you have correct environment, then PHAST could be compiled simply by typing
In the same time (inside "user function") one may also create a simple NTUPLE (10-20-30 variables) for interactive analysis in ROOT ('a la PAW').
Reading of mDSTs could be done recursively many times, i.e. at each iteration you may read mDST and write an output microDST with events selected by your algorithm(s). Such microDSTs could be read in again for further event selection etc. etc.
How to do it you may find in examples of user's code:
The only place user suppose to work with is ./user/ directory
(and maybe ./fortran/ for Fortraners)
Main user's "working place" is UserEventN() function(s) (N=0,1,2...)
(i.e. files ./user/UserEventN.cc).
For every N there is really 3 user's functions:
Which set of user functions will be called is controlled by -uN option. Multiple "-u" options are allowed. If more then one "-u" was specified, user functions will be called one after another in the arithmetic order.
All *.h , *.cc files in ./user/ directory will be compiled automatically,
than put to shared library and linked to executable by means of "make" command executed in top PHAST directory.
For users' ROOT derived classes ROOT dictionary will be created and compiled automatically.
./user/Makefile* should never be modified by user.
If PHAST has to be compiled on a platform different from default one (lxplus.cern.ch), user has to reset symbolic link
Makefile in PHAST top directory to Makefile.your_platform
Example of how to start PHAST with UserEvent0 (filtering out of events with K0 candidate): ./phast -u0 -o events_with_K0.root path-to-mDST-directory/mDST*.root
Some defaults:
Input file(s) (as well as output file and histograms)
could be CASTOR files (if CASTOR is accessible from
your machine). But in this case wildcards in file names are not supported
(it's a property of CASTOR itself).
In this case one may create text file with file names you want to process (e.g.
files.txt) and give it to PHAST input by -l option. For example:
./phast -l files.txt -u0 -o out.root
To get help on PHAST options, type
./phast
(without arguments)
To force normal termination of PHAST job before it ends itself, just send HUP signal to process:
kill -HUP pid
or type once CTRL-C if you are running interactively.
Description of classes and functions for data access could be found in
HTML documentation generated out of PHAST code
comments. PDF version is also available.
It's advisable to look first into PaEvent class documentation as it's top class in the event data hierarchy and to PaSetup as
top class for geometry description and other event-independent information.
There are also other (less recommended) ways to access mDST data.
22.07.2011 S.Gerassimov