Two basic classes of JSF (JLC Study Framework) are JSFSteer and JSFModule. JSFMoulde is a basic class for data analysis. It includes Initialize(), BeginRun(run), Process(event), EndRun(), and Terminate(). In a job of data analysis, several analysis module is performed sequentially, and the JSFSteer class is provided to control execution of modules.
General structure of JSF job is shown below. This flow is provided
by ROOT macro. User writes a class for data analysis. The class should
be derived from JSFModule ( or class derived from JSFModule.) If
user's analysis module is construced, JSFSteer execute it properly. Typical
JSF analysis flow is show below.
Where is it ?
JSF is currently installed in ccjlc ( HI-UX ) in /proj.hi/phys/lclib/jsf
directory. Binary codes for Redhat 5.1 linux system is also available.
Is there example ?
Two types of examples are included in the current release (version 0.4.3).
One for JLC detector simulation with lclib libarries,
and the other for beam test data analysis.
Input and Output of JSF
The event data are stored in the ROOT Tree. The input are (1) the event object stored in the ROOT file, (2) data generated within JSF process ( such as the case of the event generator), or (3) non-root file such as the beam test data. The output of JSF is the ROOT file where analized event data and/or histograms are stored.
The root file (TFile object) must be created before JSFSteer object
is created. JSFSteer class has pointers to the input file and output
file, inaddition to the input tres and the output tree. When TFile
object is created, ROOT stores the pointer in the global variable gFile.
When the JSFSteer object is created, JSFSteer assumes gFile is output
file if gFile is Writable, otherwise it is considered as the input file.
If user needs to specify both input and output, or does not happy with
the default behaviour, specify the pointers for input and/or output file
using the JSFSteer's SetInput(TFile *file) and/or SetOutput(TFile *file)
method. SetInput and SetOutput must be called prior to the JSFSteer::Initialize()
where input and output files are accessed to create tree or set branch
addresses.
How to read/store module's data
Event data is stored in the JSFEventBuf class or classes derived from
it. The pointer to the JSFEventBuf is the data member of the JSFModule
class. JSFSteer::MakeBranch() is called during the Initialize() of
JSFSteer to create a branch for JSFEventBuf. If user want to creates
branches differentlly, MakeBranch() method must overwritten. Other
non-event data are data member of JSFModule class. They are stored
in ( read from ) the conf directory of the output (input) root file at
Initialize(), BeginRun(), EndRun(), and/or Terminate(). Histogram
objects are written in the top directory.
ROOT/JSF analysis style
On the HI-UX system, there are some problem related to the dynamical shared library loading. Therefore, JSF libary must be statically linked to its application. Imakefile to create JSF application are found in the example directory. The JSF application is the ROOT with pre-linked JSF library. Any ROOT and CINT command can be executed in the JSF application.
Most of the C++ language are supported by CINT, but classes defined in the macro can not process properly. So user need to define new class, it must be compiled and linked and his/hers own JSF application must be prepared. If what user want to do is just the use of class member and the function, he/she can do it by macro.
According to the ROOT convension, meanings of the file prefix are as
follows.
.h ; header file
.C ; root macro file
.cxx ; C++ source code for the pre-compiled library
.o ; object file.
.root ; root file.
Command line options
Format of the JSF application command is,
jsf -l -b -q -conf=file macrowhere options are
-l ; don't show initial dialog.
-b ; run with batch mode no graphics )
-q ; quit at the end of macro
-conf=file ; specify JSF parameter file.
macro ; macro file name.All options are optional. Default file name of JSF Parameter filename is jsf.conf, where parameters for jsf modules are specified similary to the .rootrc file.
Among several method to display histograms in the root file, the easiest is to use TBorwser. To do it,
ROOT file system