WTI/Experiment Electronics/Data Processing: Go4 |
Previous tutorial 7 | | Go4 | Example 8 | | Next tutorial 9 |
> . go4loginNow the variable GO4SYS should point to the top Go4 directory. Copy the tarball tut08.tar from Example above into your directory and unpack it to your new directory:
> tar xvf tut08.tarAs before this should create a libGo4UserAnalysis.so library which is used by the standard Go4 analysis main program..
> . ./rename.sh XXX St5
> make all
TSt5Analysis | setup.C |
TSt5MakeUnp1 | TSt5EventUnp1 |
TSt5MakeCal1 | TSt5EventCal1 |
TSt5MakeUnp2 | TSt5EventUnp2 |
TSt5MakeCal2 | TSt5EventCal2 |
TSt5MakePhys | TSt5EventPhys |
TSt5Param |
We have five steps: 2 unpack, 2 calibrate and physics. Each step has a processor (Make) producing an output event (Event). The first step uses the MBS input provided by Go4 as in the previous example. But it processes only subevents with ID 1 and copies it into the output event. Similarly the first calibration step calibrates only data from this subevent. The second unpack and calibration steps do the same for subevents with ID 2. Naturally the last step needs both outputs of the calibration steps to do the final analysis. The table below shows the setup as it is done in the setup file.
Step | Input | Processor | Output |
Unpack1 | MBS | MakeUnp1 | EventUnp1 |
Calib1 | EventUnp1 | MakeCal1 | EventCal1 |
Unpack2 | Input of Unpack1 MBS | MakeUnp2 | EventUnp2 |
Calib2 | EventUnp2 | MakeCal2 | EventCal2 |
Physics | Output of Calib1 and Calib2 | MakePhys | EventPhys |
In comparison with tutorial 7 you may notice, that there are breaks in the
chain of output/input events, namely in steps
Unpack2 and
Physics.
Unpack2 needs the MBS event as input to get
the data of subevent 2. This event has already been read for step 1.
In the TSt5MakeUnp2.cxx
you will see that in fact the event source of step
Unpack1 is used.
Similarly TSt5MakePhys.cxx
uses the two outputs from
Calib1 and
Calib2, respectively.
In the setup file for these two steps no input event is declared. Because the
chain of steps is controlled by the framework, we must disable the checking
of the IO chain. This is done by the line
go4->SetStepChecking(kFALSE);The steps are created and setup in setup.C as before.
> go4analysis -events 100000The output shows in detail what happens like in the previous examples. After having processed the 100000 events, the program terminates and has produced a root file which we now inspect using the Go4 browser.
If you look into the folders you will see subfolders for the steps: