Using the FRED Event Display
FRED is the new event
display in Glast. Below you will find instruction on how to use it. There is
also a section about FRED in the SAS Offline
Workbook.
- Startup:
- FRED
should be in
your path when you log onto noric-new. Just type 'fred'
to start it.
- You can also start it with:
'ruby
/nfs/slac/g/svac/common/builds/Fred/FredRelease/fred.rb'
There are several ways to run FRED. Three of
them are detailed here. If you follow these instruction you will run the version
of the EngineeringModel release that is used by the pipeline i.e. for data
processing. You can of course choose to use any release you want by changing the
entries in the
GLAST panel.
- To just look at digi.root, recon.root
and mc.root that you have already made i.e. not rerunning recon:
- Start FRED by typing 'fred'.
- Click on the
GLAST panel and fill in:
- Personal Setup:
/nfs/slac/g/svac/common/builds/Fred/FredGlastLinks/GlastRelease.sh
- GAUDI package setup:
/nfs/slac/g/svac/common/builds/Fred/FredGlastLinks/setup.sh
- GAUDI package executable:
/nfs/slac/g/svac/common/builds/Fred/FredGlastLinks/Gleam.exe
- GAUDI jobOptions file: An
example jobOptions file can be found
in
/nfs/slac/g/svac/common/builds/Fred/jobOptions/Read_Root_noRecon/jobOptions-readRoot-noRecon.txt
- Please copy the jobOptions file to your directory, edit it and put that
path in the Glast panel.
- Put the digi file name in
'digiRootReaderAlg.digiRootFile="digi.root'"
.
- Put the recon
file name in
'reconRootReaderAlg.reconRootFile="recon.root'"
.
- If you also want to look at
MC generator information, put the mc file name in
'mcRootReaderAlg.mcRootFile = "mc.root"'
and uncomment 'Top.Members += {
"mcRootReaderAlg"};'.
- Choose the geometry file you
are interested in.
- Working dir: Any directory you
want to be your working directory.
- Save your options (so you don't
have to fill them in again the next time).
- This will make you use the
current EM release used by the pipeline. You can of course choose to
use any release you want by changing the entries in the Glast Panel.
- Click on 'Run'.
An iconized xterm window will pop up and if you click on it you will see output from Gleam.
There will also be a small message window saying it is trying to
connect.
- After a while there will be a
message in the window saying that it has been given to Fred.
- At this point you should see three
arrows and a
red stop sign in
the Fred panel:
- Click on it right arrow to
start/go to the next event.
- The left arrow takes you back to
the previous event.
- The middle arrow refreshes the
event in case you have made any changes to for example the geometry
details you want to see.
- You can also directly type in the
event index or the 'run-eventNumber'.
- Click on the 'Stop'
button to kill the Gleam/EM application.
- To run Gleam/EngineeringModel from FRED:
- Start FRED by typing 'fred'.
- Click on the
GLAST panel and fill in:
- Personal Setup:
/nfs/slac/g/svac/common/builds/Fred/FredGlastLinks/GlastRelease.sh
- GAUDI package setup:
/nfs/slac/g/svac/common/builds/Fred/FredGlastLinks/setup.sh
- GAUDI package executable:
/nfs/slac/g/svac/common/builds/Fred/FredGlastLinks/Gleam.exe
- GAUDI jobOptions file: Examples
are
in /nfs/slac/g/svac/common/builds/Fred/jobOptions/Read_Root_runRecon/jobOptions-readRoot-runRecon.txt
and /nfs/slac/g/svac/common/builds/Fred/jobOptions/Generate_MC/jobOptions-mc.txt
- Please copy one of the
jobOptions.txt files to your directory, edit it and put that
path in the Glast panel.
-
'Generate_MC'
is for generating MC with
LatIntegration, ' Read_Root_runRecon'
is for reading in a digi root file and run the
reconstruction.
- Put the digi file name in
'digiRootReaderAlg.digiRootFile="digi.root".
- Working dir: Any directory you
want to be your working directory.
- Save your options (so you don't
have to fill them in again the next time).
- This will make you use the
current EM release used by the pipeline. You can of course choose to
use any release you want by changing the entries in the Glast Panel.
- Click on 'Run'.
An iconized xterm window will pop up and if you click on it you will see output from
LatIntegration.
There will also be a small message window saying it is trying to
connect.
- PS! It's
slightly slow the first time you run.
- After a while there will be a
message in the window saying that it has been given to Fred.
- At this point you should see three
arrows and a
red stop sign in
the Fred panel:
- Click on it right arrow to
start/go to the next event.
- The left arrow takes you back to
the previous event.
- The middle arrow refreshes the
event in case you have made any changes to for example the geometry
details you want to see.
- You can also directly type in the
event index or the 'run-eventNumber'.
- Click on the 'Stop'
button to kill the LatIntegration executable.
- To run Gleam/EM on a remote server and
FRED locally on your machine:
- It is possible to run GLEAM/EM on a
remote server like noric-new and at the same time run FRED locally on
your machine. They will communicate over the network.
The advantage is that as soon as the event is loaded everything you do
(like zooming, rotating etc) will be done locally. This may speed up
things considerably.
- Make sure that on your local machine
you have at least Ruby 1.8.1 and
FRED v0r97p1.
- Copy '/nfs/slac/g/svac/common/builds/Fred/RemoteServerScript/glastdrs.rb'
to your directory (any directory will do):
- Edit glastdrs.rb:
- Change 'jobOptions' to point to
your jobOptions.txt file.
- Change 'workingDir' to point to
your working directory.
- This will make you use the
current EM release used by the pipeline. You can of course choose to
use any release you want by changing the next three lines in the
script (there are comments in the script explaining how to do it).
- Log on to noric-new, and in the
directory where you copied over glastdrs.rb, do 'ruby
glastdrs.rb'.
- On your local machine (i.e. not on
noric-new), start Fred with the usual 'ruby fred.rb'.
- Click on the 'Glast'
panel, and then on 'Remote (DRB)'.
In the server address field, type in the IP address of the noric-new
machine where you launched the glastdrs.rb script, followed by
':9000' and hit 'Return'.
- You can get the IP address of
your noric-new machine by doing 'nslookup $HOST'
on the noric-new machine where you are running.
- For example, noric17 has the IP
address 134.79.86.67. In the 'Remote (DRB)'
field you then type '134.79.86.67:9000'
and hit 'Connect'.
- You should now have the usual
start and stop buttons in Fred. You can now close the Glast panel
and start looking at events.
- When you click on the
red 'Stop'
button you will not kill the remote
application (Gleam/EM) running on noric-new i.e. it is possible to
reconnect to it.
Some useful jobOption parameters are:
- Geometry levels:
- You can choose the level of detail
you want to see by changing the jobOptions parameter 'HepRepSvc.geometryDepth = 10;'
- The higher the number, the more
details you get, but the slower it will be.
- Note that you can also interactively
turn things on and off in FRED.
- Right geometry file:
- The full flight geometry is
available by default but just in case you need it: GlastDetSvc.xmlfile =
"$(XMLGEODBSROOT)/xml/latAssemby/latAssembySegVols/flightSegVols.xml";
- Other geometries like one and two tower geometries in the
grid are available as: GlastDetSvc.xmlfile =
"$(XMLGEODBSROOT)/xml/latAssembly/lat1TowerSegVols.xml"; and
GlastDetSvc.xmlfile =
"$(XMLGEODBSROOT)/xml/latAssembly/lat2TowerSegVols.xml";
- For single bay use:
GlastDetSvc.xmlfile =
"$(XMLGEODBSROOT)/xml/latAssembly/singleBay1TowerSegVols.xml";