diff --git a/README.md b/README.md index 7e1e411fc36cc..7e19c8a1b088a 100644 --- a/README.md +++ b/README.md @@ -52,6 +52,15 @@ The processing of TICL iterations is added into the RECO fragment by default. To ./produceSkeletons_D41_NoSmear_noPU.sh no-ticl ``` +Other options like changing the pileup source, calling --customise on cmsDriver or changing geometry can be passed with the following script + +```shell +./produceSkeletons_D41_NoSmear_PU_AVE_200_BX_25ns_aged.sh \ + pileup_input=/eos/cms//store/group/dpg_hgcal/comm_hgcal/deguio/pu_library/V11/GEN-SIM \ + custom="--customise SLHCUpgradeSimulations/Configuration/aging.agedHGCal" \ + geometry=Extended2026D46 +``` + ## Available guns and processes The production tools allow you to generate a plethora of processes (links lead to implementation in CMSSW): diff --git a/templates/python/produceSkeletons_D41_NoSmear_PU_AVE_200_BX_25ns_aged.sh b/templates/python/produceSkeletons_D41_NoSmear_PU_AVE_200_BX_25ns_aged.sh new file mode 100755 index 0000000000000..a3c1ac8ed0219 --- /dev/null +++ b/templates/python/produceSkeletons_D41_NoSmear_PU_AVE_200_BX_25ns_aged.sh @@ -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 "$@"