Difference between revisions of "Calibration Train"

From GlueXWiki
Jump to: navigation, search
(Calibration Challenge)
(Procedures)
 
(47 intermediate revisions by the same user not shown)
Line 1: Line 1:
 
__TOC__
 
__TOC__
  
 +
= Processing Overview =
  
= Calibration Challenge =
+
* [[Old Calibration Train]]
  
* [[Calibration Challenge|Calibration Challenge 1]]
+
== Job Structure ==
  
= Organization =
+
Currently, two passes are planned:  One automated step, and one to produce outputs for calibration procedures that are still manual.
  
* The jobs will be submitted every Tuesday at noon, JLab time.
+
The calibrations/plugins that are run on each pass are:
* The jobs will be run from the gxproj3 account [parallel use with EventStore jobs]
+
* '''Pass 1'''
 +
** Run as many calibrations as possible on one file
 +
*# Pass 1: RF_online
 +
*# Pass 2: HLDetectorTiming,TOF_TDC_shift
 +
*# Pass 3: st_tw_corr_auto [don't commit]
 +
*# Pass 4: HLDetectorTiming, CDC_amp, BCAL_TDC_Timing [time offsets, need to update]
 +
* '''Pass 2'''
 +
** Process/skim full run
 +
** Calibrations: BCAL_attenlength_gainratio, BCAL_LEDonline, CDC_amp,CDC_TimeToDistance, FCALpedestals, FCALpulsepeak, FCAL_TimingOffsets, HLDetectorTiming, imaging, PSC_TW,  PS_timing, pedestals,ST_Propagation_Time
 +
** EVIO skims: FCAL pi0, BCAL pi0, BCAL-LED, FCAL-LED, random, sync
 +
** ROOT skims: TOF_calib
 +
** Other [Monitoring]: BCAL_LED, BCAL_inv_mass, imaging, p2pi_hists, p3pi_hists
 +
* '''Incoming'''
 +
** Tagger/PS workflow
 +
** BCAL LED monitoring
  
* The output of the jobs will be stored in ...
+
== Calibration run plan ==
  
= Run Ranges =
+
The two priority items are to recalibrate the TOF with the its new running conditions and to verify calibrations with the new fADC250 firmware.  All calibrations should be checked, in any case.
  
The following runs will be processed:
+
# Standalone calibrations (no forward tracking)
 +
#* ✓ RF time (Paul M.)
 +
#* Pedestals (System owners)
 +
#* BCAL Attenuation length/gain ratio (Mark D.)
 +
#* CDC time to distance (Mike S.)
 +
#* CDC gain (Naomi)
 +
#* ✓ SC timewalk (Mahmoud)
 +
#* TOF timing (Offsets/timewalks) (Beni)
 +
#* ✓ TAGM timing (Alex B.)
 +
#* ✓ TAGH timing (Nathan)
 +
#* ✓ PS timing (Nathan)
 +
#* ✓ Overall timing (rough) (Mike S./Sean)
 +
# Full tracking calibrations
 +
#* ✓ BCAL Effective velocities (George)
 +
#* ✓ Overall timing (Mike S./Sean)
 +
#* ✓ SC Propagation time (Mahmoud)
 +
# ✓ BCAL/FCAL pi0 calibrations (Adesh/Will M.)
  
'''RunPeriod-2015-03'''
+
All calibrations except the pi0 calibration should take no more than 1-3 2h runs of data.
* 2931, 3079, 3179, 3180, 3183, 3185
+
  
= Calibrations =
+
=== Frequency ===
  
=== Job Requirements ===
+
* Timing will be checked for each run.  The known variations are:
 +
** TOF (run-to-run)
 +
** Tagger (~<day, corrected in run-to-run in the spring)
 +
* CDC gains vary with temperature and pressure, can be averaged over a 1-2 hour run.
  
Each calibration process should include the following:
+
All other calibrations have been seen (so far) to be stable on a ~several week timescale
* Plugin stored in standard location
+
** https://halldsvn.jlab.org/repos/trunk/sim-recon/src/plugins/Calibration
+
* ROOT/other scripts stored in standard location
+
** https://halldsvn.jlab.org/repos/trunk/sim-recon/src/scripts/calibrations ?
+
** Individual git repos?
+
* Output to files
+
* QA routines
+
  
=== What is Being Run ===  
+
=== To-dos ===
  
The following plugins are currently being run:
+
# <strike>Finish skim improvements</strike>
* RF_online (RF signal)
+
# Automate constant -> CCDB pipeline
* BCAL_TDC_Timing 
+
# Implement tracking database
* HLDetectorTiming 
+
* PSC_TW
+
  
Working on adding:
+
= Procedures =
* BCAL_attenlength_gainratio
+
* BCAL gains - /work/halld/home/wmcginle/Gain_Calib
+
* TOF calibrations - https://halldsvn.jlab.org/repos/trunk/home/zihlmann/TOF_calib/
+
  
= Code =
+
=== How to start a new run period ===
  
The current code can be obtained at
+
# Edit configuration file, e.g., $CALIBRATION_TRAIN/configs/data.config
<syntaxhighlight>
+
#* Change job name to the current run period and set resource limits
svn co https://halldsvn.jlab.org/repos/trunk/home/sdobbs/calibration_train/
+
# Edit $CALIBRATION_TRAIN/template/job_wrapper.sh
</syntaxhighlight>
+
#* Set run period and version number
 +
# Set up the files and directories
 +
#* e.g. python setup_run.py configs/data.config
 +
# Create workflows
 +
#* swif create -workflow GXCalib-2017-01-pass1
 +
#* swif create -workflow GXCalib-2017-01-pass2
 +
# Create SQLite CCDB
 +
#* $CCDB_HOME/scripts/mysql2sqlite/mysql2sqlite.sh -hhallddb.jlab.org -uccdb_user ccdb | sqlite3 ccdb.sqlite
 +
#* mv ccdb.sqlite somewhere
 +
# Launch pass1 jobs
 +
#* python run_jobs_p1.py 2017-01 run_lists/f17.test
  
The ROOT library directory can be found at:
+
= Calibration Outputs =
...
+
  
= Older Information =
+
== RunPeriod-2017-01 ==
  
== Proposal ==
+
{| class="wikitable"
 +
! Run Range
 +
! Version tag
 +
! Total # Jobs
 +
! Notes
 +
! Total Skim Size (TB)
 +
! BCAL pi0 (GB)
 +
! BCAL LED (GB)
 +
! FCAL pi0 (GB)
 +
! FCAL LED (GB)
 +
! PS Skim (TB)
 +
! TOF Skim (TB)
 +
|-
 +
| 30274 - 30621
 +
| ver01
 +
| 13362
 +
|
 +
| 11.2
 +
| 338
 +
| 74
 +
| 862
 +
| 147
 +
| 6.36
 +
| 1.63
 +
|-
 +
| 30622 - 30959
 +
| ver02
 +
| 13783
 +
| looser BCAL pi0 cuts
 +
| 23.3
 +
| 2379
 +
| 131
 +
| 1703
 +
| 297
 +
| 12.7
 +
| 3.36
 +
|-
 +
| 30960 -
 +
| ver03
 +
| 14869
 +
| looser BCAL pi0 cuts
 +
| 13.4
 +
| 1368
 +
| 71
 +
| 1000
 +
| 142
 +
| 7.47
 +
| 1.99
 +
|}
  
* Use case: Streamline tape library usage, provide common environment for production and development
+
* Skim files can be found in the following directory: /cache/halld/RunPeriod-2017-01/calib/ver01
** Example: Users develop plugins on their favorite files/run, use this for running over larger data
+
** BCAL-LED - BCAL LED triggered events
* Run every week (Wednesday to avoid conflict with monitoring?)
+
** BCAL_pi0 - BCAL pi0 candidates
* Uses subset of runs
+
** FCAL-LED - FCAL LED triggered events
* Users provide:
+
** FCAL_pi0 - FCAL pi0 candidates
** DANA plugin
+
** PS - PS triggered events
** Optional post-processing scripts to be run after every/all runs
+
** random - random (out-of-time) triggered events
*** Curated in SVN
+
** sync - TS sync events
* Results stored in standard location(s)
+
** TOF - TOF calibration ROOT skim
** Possible results: ROOT files, images, calibration constants, web pages
+
* Uses SWIF? (buzzword compliance)
+
* Uses GlueX project account (gxproj3? 4? 5?)
+
  
== Runs to Use ==
+
<!--
 +
ver01:
 +
/mss/halld/RunPeriod-2017-01/calib/ver01/hists
 +
total = 1673.9482654 GB
 +
/mss/halld/RunPeriod-2017-01/calib/ver01/BCAL-LED
 +
total = 74.0351243354 GB
 +
/mss/halld/RunPeriod-2017-01/calib/ver01/BCAL_pi0
 +
total = 338.330394119 GB
 +
/mss/halld/RunPeriod-2017-01/calib/ver01/FCAL-LED
 +
total = 146.729467098 GB
 +
/mss/halld/RunPeriod-2017-01/calib/ver01/FCAL_pi0
 +
total = 862.115063164 GB
 +
/mss/halld/RunPeriod-2017-01/calib/ver01/PS
 +
total = 6364.3464742 GB
 +
/mss/halld/RunPeriod-2017-01/calib/ver01/TOF
 +
total = 1636.12805751 GB
 +
/mss/halld/RunPeriod-2017-01/calib/ver01/random
 +
total = 128.437043864 GB
 +
/mss/halld/RunPeriod-2017-01/calib/ver01/sync
 +
total = 3.4401245974 GB
  
Several possibilities:
 
  
# Large/Popular Runs
+
ver02:
#* Fall 2014: 1514, 1769, 1777, 1787, 1803, 1807, 1810, 1825, 1847, 1852, 1854, 1871, 1872, 2138, 2206, 2207, 2209, 2223, 2397
+
#* Spring 2015: 2931, 3079, 3179, 3180, 3183, 3185
+
# Other big sets of runs:
+
#* Fall 2014: 1516-1520, 1769-1777, 1900, 2179-2184, 2205, 2228, 2407-2409, 2416-2420
+
#* Look for groups of runs with similar conditions
+
# Others
+
  
  
 
+
ver03:
This also raises the question: what are the good runs?
+
-->
 
+
One proposal:
+
* Tag each run in monitoring database with one of three values:
+
*# 0 - non-production quality
+
*# 1 - production quality
+
*# 2 - production quality, used for calibrations
+
* Idea is that > 1 means that the run is good to use for physics
+
** Finer grained information can be stored in RCDB
+
* To determine production quality, develop quality metrics for each subdetector, use combination of quality metrics and eye test
+

Latest revision as of 23:53, 16 January 2018

Processing Overview

Job Structure

Currently, two passes are planned: One automated step, and one to produce outputs for calibration procedures that are still manual.

The calibrations/plugins that are run on each pass are:

  • Pass 1
    • Run as many calibrations as possible on one file
    1. Pass 1: RF_online
    2. Pass 2: HLDetectorTiming,TOF_TDC_shift
    3. Pass 3: st_tw_corr_auto [don't commit]
    4. Pass 4: HLDetectorTiming, CDC_amp, BCAL_TDC_Timing [time offsets, need to update]
  • Pass 2
    • Process/skim full run
    • Calibrations: BCAL_attenlength_gainratio, BCAL_LEDonline, CDC_amp,CDC_TimeToDistance, FCALpedestals, FCALpulsepeak, FCAL_TimingOffsets, HLDetectorTiming, imaging, PSC_TW, PS_timing, pedestals,ST_Propagation_Time
    • EVIO skims: FCAL pi0, BCAL pi0, BCAL-LED, FCAL-LED, random, sync
    • ROOT skims: TOF_calib
    • Other [Monitoring]: BCAL_LED, BCAL_inv_mass, imaging, p2pi_hists, p3pi_hists
  • Incoming
    • Tagger/PS workflow
    • BCAL LED monitoring

Calibration run plan

The two priority items are to recalibrate the TOF with the its new running conditions and to verify calibrations with the new fADC250 firmware. All calibrations should be checked, in any case.

  1. Standalone calibrations (no forward tracking)
    • ✓ RF time (Paul M.)
    • Pedestals (System owners)
    • BCAL Attenuation length/gain ratio (Mark D.)
    • CDC time to distance (Mike S.)
    • CDC gain (Naomi)
    • ✓ SC timewalk (Mahmoud)
    • TOF timing (Offsets/timewalks) (Beni)
    • ✓ TAGM timing (Alex B.)
    • ✓ TAGH timing (Nathan)
    • ✓ PS timing (Nathan)
    • ✓ Overall timing (rough) (Mike S./Sean)
  2. Full tracking calibrations
    • ✓ BCAL Effective velocities (George)
    • ✓ Overall timing (Mike S./Sean)
    • ✓ SC Propagation time (Mahmoud)
  3. ✓ BCAL/FCAL pi0 calibrations (Adesh/Will M.)

All calibrations except the pi0 calibration should take no more than 1-3 2h runs of data.

Frequency

  • Timing will be checked for each run. The known variations are:
    • TOF (run-to-run)
    • Tagger (~<day, corrected in run-to-run in the spring)
  • CDC gains vary with temperature and pressure, can be averaged over a 1-2 hour run.

All other calibrations have been seen (so far) to be stable on a ~several week timescale

To-dos

  1. Finish skim improvements
  2. Automate constant -> CCDB pipeline
  3. Implement tracking database

Procedures

How to start a new run period

  1. Edit configuration file, e.g., $CALIBRATION_TRAIN/configs/data.config
    • Change job name to the current run period and set resource limits
  2. Edit $CALIBRATION_TRAIN/template/job_wrapper.sh
    • Set run period and version number
  3. Set up the files and directories
    • e.g. python setup_run.py configs/data.config
  4. Create workflows
    • swif create -workflow GXCalib-2017-01-pass1
    • swif create -workflow GXCalib-2017-01-pass2
  5. Create SQLite CCDB
    • $CCDB_HOME/scripts/mysql2sqlite/mysql2sqlite.sh -hhallddb.jlab.org -uccdb_user ccdb | sqlite3 ccdb.sqlite
    • mv ccdb.sqlite somewhere
  6. Launch pass1 jobs
    • python run_jobs_p1.py 2017-01 run_lists/f17.test

Calibration Outputs

RunPeriod-2017-01

Run Range Version tag Total # Jobs Notes Total Skim Size (TB) BCAL pi0 (GB) BCAL LED (GB) FCAL pi0 (GB) FCAL LED (GB) PS Skim (TB) TOF Skim (TB)
30274 - 30621 ver01 13362 11.2 338 74 862 147 6.36 1.63
30622 - 30959 ver02 13783 looser BCAL pi0 cuts 23.3 2379 131 1703 297 12.7 3.36
30960 - ver03 14869 looser BCAL pi0 cuts 13.4 1368 71 1000 142 7.47 1.99
  • Skim files can be found in the following directory: /cache/halld/RunPeriod-2017-01/calib/ver01
    • BCAL-LED - BCAL LED triggered events
    • BCAL_pi0 - BCAL pi0 candidates
    • FCAL-LED - FCAL LED triggered events
    • FCAL_pi0 - FCAL pi0 candidates
    • PS - PS triggered events
    • random - random (out-of-time) triggered events
    • sync - TS sync events
    • TOF - TOF calibration ROOT skim