forked from cms-sw/cmssw
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* adding a customized pileup,geometry,and other options skeleton producer * adding an explanation to README * adding check for string start
- Loading branch information
Showing
2 changed files
with
131 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
122 changes: 122 additions & 0 deletions
122
templates/python/produceSkeletons_D41_NoSmear_PU_AVE_200_BX_25ns_aged.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,122 @@ | ||
#!/bin/sh | ||
|
||
# This is the shell script that will generate all the skeletons using cmsDriver commands. | ||
# The commands included have been taken from runTheMatrix with the following command: | ||
# | ||
# runTheMatrix.py -w upgrade -l 20634.0 --command="--no_exec" --dryRun | ||
# | ||
# The reconstruction as part of the ticl framework is injected into the RECO_fragment. | ||
# | ||
# For all commands remove --filein and --fileout options. | ||
# Add python_filename option | ||
# | ||
# The first command combines step1 and step2 (GSD): | ||
# - mix in pileup | ||
# - run up to DIGI...HLT:@fake2 | ||
# The following changes are implemented on top: | ||
# --beamspot HLLHC14TeV ➜ --beamspot NoSmear | ||
# --eventcontent FEVTDEBUG ➜ --eventcontent FEVTDEBUGHLT | ||
# Removed --relval option. | ||
# | ||
# The second command is step3 removing overlap with step2 (RECO): | ||
# - remove pileup part | ||
# - remove MINIAODSIM from event content and data tier | ||
# - remove PAT from steps (-s) | ||
# - remove @miniAODValidation from VALIDATION step | ||
# - remove @miniAODDQM from DQM step | ||
# | ||
# The third command is a copy of the second only re-running RECO (for NTUP): | ||
# - remove DQM from event content | ||
# - remove DQMIO from data tier | ||
# - add --processName=NTUP option | ||
# | ||
# Those commands should be regularly checked and, in case of changes, propagated into this script! | ||
|
||
action() { | ||
# default arguments | ||
local inject_ticl="1" | ||
local geometry="Extended2026D41" | ||
local pileup_input="das:/RelValMinBias_14TeV/CMSSW_10_6_0_patch2-106X_upgrade2023_realistic_v3_2023D41noPU-v1/GEN-SIM" | ||
local custom="" | ||
|
||
# parse arguments | ||
for arg in "$@"; do | ||
if [ "$arg" = ^"ticl" ]; then | ||
inject_ticl="1" | ||
elif [ "$arg" = ^"no-ticl" ]; then | ||
inject_ticl="0" | ||
elif [[ $arg =~ ^"geometry" ]]; then | ||
geometry=${arg/geometry=/} | ||
echo "Geometry will be modified to $geometry" | ||
elif [[ $arg =~ ^"custom" ]]; then | ||
custom=${arg/custom=/} | ||
echo "Custom options $custom" | ||
elif [[ $arg =~ ^"pileup_input" ]]; then | ||
pileup_input=${arg/pileup_input=/} | ||
#if das is not given try to build the list of files by listing the local directory given | ||
if [[ ${pileup_input} != *"das:"* ]]; then | ||
pileup_input=`find ${pileup_input} -iname "*.root" -printf "file:%h/%f,"` | ||
pileup_input=${pileup_input::-1} | ||
fi | ||
echo "Pileup input modified to ${pileup_input}" | ||
else | ||
2>&1 echo "unknown argument: $arg" | ||
return "1" | ||
fi | ||
done | ||
|
||
cmsDriver.py TTbar_14TeV_TuneCUETP8M1_cfi \ | ||
--conditions auto:phase2_realistic \ | ||
-n 10 \ | ||
--era Phase2C8 \ | ||
--eventcontent FEVTDEBUGHLT \ | ||
-s GEN,SIM,DIGI:pdigi_valid,L1,L1TrackTrigger,DIGI2RAW,HLT:@fake2 \ | ||
--datatier GEN-SIM \ | ||
--beamspot NoSmear \ | ||
${custom} \ | ||
--geometry ${geometry} \ | ||
--pileup AVE_200_BX_25ns \ | ||
--pileup_input ${pileup_input} \ | ||
--no_exec \ | ||
--python_filename=GSD_fragment.py | ||
|
||
|
||
cmsDriver.py step3 \ | ||
--conditions auto:phase2_realistic \ | ||
-n 10 \ | ||
--era Phase2C8 \ | ||
--eventcontent FEVTDEBUGHLT,DQM \ | ||
--runUnscheduled \ | ||
-s RAW2DIGI,L1Reco,RECO,RECOSIM,VALIDATION:@phase2Validation,DQM:@phase2 \ | ||
--datatier GEN-SIM-RECO,DQMIO \ | ||
--geometry ${geometry} \ | ||
--no_exec \ | ||
--python_filename=RECO_fragment.py | ||
|
||
|
||
if [ "$inject_ticl" = "1" ]; then | ||
echo -e "\ninject ticl into RECO_fragment.py" | ||
./inject_ticl.sh RECO_fragment.py | ||
if [ "$?" = "0" ]; then | ||
echo | ||
else | ||
2>&1 echo "ticl injection failed" | ||
return "2" | ||
fi | ||
fi | ||
|
||
|
||
cmsDriver.py step3 \ | ||
--conditions auto:phase2_realistic \ | ||
-n 10 \ | ||
--era Phase2C8 \ | ||
--eventcontent FEVTDEBUGHLT \ | ||
--runUnscheduled \ | ||
-s RAW2DIGI,L1Reco,RECO,RECOSIM \ | ||
--datatier GEN-SIM-RECO \ | ||
--geometry ${geometry} \ | ||
--no_exec \ | ||
--processName=NTUP \ | ||
--python_filename=NTUP_fragment.py | ||
} | ||
action "$@" |