WESTGRID Checklist for Monte Carlo generation and analysis of MC and Data ========================================================================= Mina Nozar et al. April 9, 2006 Prior to running a full blown MC generation/analysis, or a Data analysis job, the following steps should be followd: 1) A directory structure for a given job should be created. 2) Input files (and Environment Variabes defined within), and executable versions should be checked. 3) A small test job (1000 events per MC run or Data file is sufficient) should be submitted. 4) The output log should be checked to make sure the intended executables and the correct calibration and input files were loaded. Data Analysis (example: set1, anal1) Directory structure setup and contents: - /global/home/e614/tbsroot/set1: SPOOLROOT for set1 job submission - SPOOLROOT/set1.info: Contains a short description of the set, the date of the setup, and the WG operator name responsible for setting up the job. - SPOOLROOT/common/set1anal1.kcm: Contains all MOFIA related namelists, commands, cut/selection settings, overriding of calibration file choice(s) for special systematic runs (via the USE statement). The kcm file (and the MOFIA namelist defaults) should be checked carefully for: - windowing and classification parameters - minimum decay time - crosstalk definition parameters Use $MOFIA_KCM/production_raw.kcm as a reference. - SPOOLROOT/set1anal1-EnvFile: The master "EnvFile" template, e614_EnvTmpFile, is in CVS, under $CVSROOT/westgrid/rundb-dev. An up-to-date copy of this files should always be kept under ~e614/rundb-dev and every WG job should always start with this file. The file contains Environment Variables used by the submission script, ~e614/bin/tbsub.pl. The script, tbsub.pl, by default copies ~e614/rundb-dev/e614_EnvTmpFile to SPOOLROOT/set1anal1-EnvFile. NOTE: Most of the Env. Variables set remain the same from job to job; however, some may have to be changed. For instance: MOFIA_OUTPATH /global/scratch/twist/systematics will most likely remain the same for the usual WG running while MOFIA_EXE /global/home/e614/rundb-dev/exe/photo_wg2.3icc may have to be changed. PBS parameters such as walltime and memory requirement are set here and should be checked/changed depending on the job. A WORD OF CAUTION: The default Environment Variable files set in ~e614/rundb-dev/e614_EnvTmpFile will be used by the script, unless overridden by the WG operator through the use of command line options in tbsub.pl. It is therefore advised that the WG operator look through the EnvFile, see a list of command line options "tbsub.pl -h" and either - override the Env. Var. settings by choosing the appropriate command line options during job submission. The operator is prompted whether the Env. Var. settings in the SPOOLROOT/set1anal1-EnvFile should be overridden with those specified by the operator via the choice of command line options. The user should answer "yes" before proceeding. or - copy ~e614/rundb-dev/e614_EnvTmpFile to SPOOLROOT/set1anal1-EnvFile and modify the Env. Var, settings by hand. During the job submission, the script will "find" an existing SPOOLROOT/set1anal1-EnvFile and will prompt the operator whether this file should be loaded. The user should answer "yes" before proceeding. - Calibration Files: /global/home/e614/e614soft/caldb_ascii ($CAL_DB) contains all required cfm database files (and the operator should confirm that the correct files are being used, according to cfm), including: - Detector geometry file - t0 parameters (global and wire-specific) - Alignment files - STR files: Map of drift times in DC, PC, (and TC) cells. - Map of TDC channels - Field map files MC generation and analysis (example: gen1, anal1) Directory structure setup and contents: - /global/home/e614/tbsroot/gen1: SPOOLROOT for gen1 job submission - SPOOLROOT/gen1.info: Contains a short description of the gen, the date of the setup, and the WG operator name responsible for setting up the job. Generation of MC: - SPOOLROOT/gen1.ffcards: Should be the "master" ffcard for the gen1 generation. All ffcard field settings should be checked by the operator, including: Global: - keeping all events we need, killing events/tracks only where necessary, according to volume, decay time, secondaries - Appropriate MC data banks are turned on as required Set-dependent: - field and field map - beam generation file and settings - Gas density (temperature and pressure) correspond to the data set being simulated - gas absorber (GABS) setting gives the correct stopping distribution compared to the corresponding data set - are all defaults correct, and all changes to defaults justified? - SPOOLROOT/common/e614.com: The script that gets executed by tbsub.pl: e614.com . The master e614.com for WG use is in cvs, $CVSROOT/westgrid/rundev-db/e614_WG.com. An up-to-date copy is kept in ~e614/rundb-dev/e614_WG.com The filename was chosen such that to distinguish it from the e614.com that is used on the TWIST desktops and cluster. This file contains the Environment Variable settings for input files to be used for MC generation. A copy of this file should be placed in SPOOLROOT/common/e614.com; check the master file for the global settings, and the local copy for set-dependent settings, including: - Detector geometry file - t0 parameters (global and wire-specific) - Alignment files - STR files: Map of drift times in DC, PC, (and TC) cells. - Map of TDC channels - Field value setting and field map files - Muon beam and beam positron generation files and settings - SPOOLROOT/gen1-EnvFile: As for data (see above "set1anal1-EnvFile"), but also make sure the correct MC executable is set. (The gen1anal1-EnvFile will be created automatically.) Analysis of MC: Same as for data analysis, except that in the kcm file, crosstalk removal should be off and necessary MC bank information is passed to trees.