- zchang's home page
- Posts
- 2023
- October (1)
- 2022
- 2021
- 2020
- 2019
- December (1)
- November (2)
- October (1)
- September (2)
- August (2)
- June (2)
- May (2)
- April (2)
- March (2)
- January (1)
- 2018
- 2017
- 2016
- December (1)
- October (4)
- September (1)
- August (3)
- July (1)
- June (2)
- May (4)
- April (1)
- March (4)
- February (1)
- 2015
- December (1)
- November (1)
- October (3)
- September (4)
- August (3)
- July (2)
- May (1)
- March (1)
- February (1)
- 2014
- December (2)
- November (1)
- October (1)
- September (8)
- August (2)
- July (1)
- June (1)
- May (2)
- April (1)
- March (1)
- February (1)
- January (1)
- 2013
- 2012
- My blog
- Post new blog entry
- All blogs
How to populate offline triggerThreshold and triggerDefinition tables
These two tables are used in StRoot/StTriggerUtilities to obtain the threshold, offline ID, onbits and offbits of a given trigger. They reside under Calibrations/trg/ in the offline DB directory. The offline tables get values from table dict and trigger respectively in the online database Conditions/rts.
In the online table, for every run the table has an entry, however in the offline table entry is distinct from beginTime. So for each run, before we populate the offline tables, we need to get the beginTime of runs that we want to populate. The beginTime is returned by providing a run, where it gets its values from table runDescriptor in online database RunLog. The sample code getBeginTime.C does this job, where it takes run number as its argument. The beginTime will be stored under directory beginTimes/ with file name starting with runnumber followed by ".beginTimes.txt".
Once you have get the beginTime for a given run, you can populate the tables by running code write_trigger_threshold.C and write_trigger_definition.C. Before you writing to these tables, make sure you have write access to the STAR offline tables. Both codes take a run number as their arguments.
After you have written new entries to these tables, you can use code read_trigger_threshold.C and read_trigger_definition.C. For reading these tables, you don't have to have write access to the tables. Therefore these codes can be used for reading previous entered entries. Both codes take a run number as their arguments as well.
All the sample codes can be found at CVS repository.
cvs co StRoot/StTriggerUtilities/macros/
or you can browse them at the link below.
http://www.star.bnl.gov/cgi-bin/protected/cvsweb.cgi/StRoot/StTriggerUtilities/macros/
Special notes
1. Please remember to check the correct port number to the online database server for different years. The port number is detailed at the following link.
https://drupal.star.bnl.gov/STAR/comp/db/onlinedb/online-server-port-map
2. Make sure the online database server is accessible, currently we are using db04.star.bnl.gov on rcaf (on other online nodes dbbak.starp.bnl.gov may also work).
- zchang's blog
- Login or register to post comments