-
Notifications
You must be signed in to change notification settings - Fork 0
SWTrigger
Unbiased definitions for Run3:
prod_numiunbiased_swizzle_inclusive_v5
prod_bnbunbiased_swizzle_inclusive_v5
prod_extunbiased_swizzle_inclusive_v5
These definitions cover a wide-range of times. To focus on more recent data-taking, we should only consider data taken between Feb 1st (run 14866) and May 2nd (run 16400)
Equivalent definitions, with these run-ranges, can be found below:
davidc_prod_numiunbiased_swizzle_inclusive_v5_runrange_14866_16400
davidc_prod_bnbunbiased_swizzle_inclusive_v5_runrange_14866_16400
davidc_prod_extunbiased_swizzle_inclusive_v5_runrange_14866_16400
Before using these definitions, you must pre-stage them with the command:
samweb prestage-dataset --defname="DEFNAME"
And, in general, please follow the best-practices on DocDB 14184 for job submission.
To setup and run the code:
source /grid/fermiapp/products/uboone/setup_uboone.sh
setup uboonecode v06_26_01_13 -q e10:debug
The fhicl file to be used can be found at the path
/uboone/app/users/davidc/numiSWt/swtrigger.fcl
The main section of code of relevance in this fhicl file is the last line:
physics.filters.swtrigger.NUMI_FEMBeamTriggerAlgo.TriggerThresPHMAX: 50
Which indicates the threshold (= PHMAX) to apply to the NuMI trigger condition, in ADCs. This is the value which should be scanned, in order to reproduce a plot such as the one below. To convert from ADCs to PE, simply divide by 20.
To produce the plot, one needs to access variables associated to the SW trigger output. The output of the larsoft job which runs when the fhicl file is executed is a ROOT file called "swtrigger_hist.root" which contains a TTree at the path
swtrigger/swtrigdata
Of the many branches in this TTree, only a few will be necessary for the study. An example of these is below:
root [5] swtrigdata->Scan("algopass:PHMAX:multiplicity")
***********************************************************
* Row * Instance * algopass * PHMAX * multiplic *
***********************************************************
* 0 * 0 * 1 * 51 * 2 *
* 1 * 0 * 1 * 72 * 2 *
* 2 * 0 * 1 * 57 * 2 *
* 3 * 0 * 1 * 52 * 1 *
* 4 * 0 * 1 * 52 * 2 *
* 5 * 0 * 1 * 50 * 1 *
* 6 * 0 * 1 * 50 * 1 *
* 7 * 0 * 1 * 59 * 2 *
* 8 * 0 * 1 * 50 * 2 *
* 9 * 0 * 1 * 55 * 1 *
Each entry is associated to an event. The variable "algopass" indicates whether a given event passes the software trigger with the PHMAX threshold imposed in the fhicl file. The ratio of passing events (==1) to all gives the fraction of events passing the SW trigger configuration. PHMAX gives the maximum ADC count on the waveform.
I would start by trying to run interactively on the files in the "numi" definition. If this does not take too much time, then you can repeat this for the various values of PHMAX which should be scanned. Error bars for the computed fractions can be calculated via Feldman Cousins. An example is provided here.
