Skip to content

Commit c19817b

Browse files
committed
anchorMC: Take away need to specify NSIGEVENTS
It should be enough, and less confusing, to just specify the number of timeframes to be simulated (as well as potentially the timeframe length in orbits). So we now do the setting for NSIGEVENTS internally (the o2dpg_sim_workflow script still needs it) but keep the option to provide it for expert studies. Also taking away the need to provide CYCLE (which is mostly 0 in any case).
1 parent 0c505a9 commit c19817b

File tree

1 file changed

+13
-4
lines changed

1 file changed

+13
-4
lines changed

MC/run/ANCHOR/anchorMC.sh

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,7 @@ print_help()
4545
echo
4646
echo "as well as:"
4747
echo "NTIMEFRAMES,"
48-
echo "NSIGEVENTS,"
4948
echo "SPLITID,"
50-
echo "CYCLE,"
5149
echo "PRODSPLIT."
5250
echo
5351
echo "Optional are:"
@@ -62,6 +60,8 @@ print_help()
6260
echo "ALIEN_JDL_INVERT_IRFRAME_SELECTION, invertes the choice of ALIEN_JDL_RUN_TIME_SPAN_FILE"
6361
echo "ALIEN_JDL_CCDB_CONDITION_NOT_AFTER, sets the condition_not_after timestamp for CCDB queries"
6462
echo "DISABLE_QC, set this to disable QC, e.g. to 1"
63+
echo "CYCLE, to set a cycle number different than 0"
64+
echo "NSIGEVENTS, to enforce a specific upper limit of events in a timeframe (not counting orbit-early) events"
6565
}
6666

6767
# Prevent the script from being soured to omit unexpected surprises when exit is used
@@ -142,11 +142,20 @@ fi
142142
[ -z "${ALIEN_JDL_LPMANCHORYEAR}" ] && { echo_error "Set ALIEN_JDL_LPMANCHORYEAR or ANCHORYEAR" ; exit 1 ; }
143143

144144
[ -z "${NTIMEFRAMES}" ] && { echo_error "Set NTIMEFRAMES" ; exit 1 ; }
145-
[ -z "${NSIGEVENTS}" ] && { echo_error "Set NSIGEVENTS" ; exit 1 ; }
146145
[ -z "${SPLITID}" ] && { echo_error "Set SPLITID" ; exit 1 ; }
147-
[ -z "${CYCLE}" ] && { echo_error "Set CYCLE" ; exit 1 ; }
148146
[ -z "${PRODSPLIT}" ] && { echo_error "Set PRODSPLIT" ; exit 1 ; }
149147

148+
# The number of signal events can be given, but should be useful only in
149+
# certain expert modes. In the default case, the final event number is determined by the timeframe length.
150+
if [ -z "${NSIGEVENTS}" ]; then
151+
NSIGEVENTS=10000 # this is just some big number; In the simulation the event number is the minimum of this number and what fits into a single timeframe
152+
# based on the interaction rate. The number is a reasonable upper limit related to ~5696 collisions that fit into 32 LHC orbits at 2MHz interaction rate.
153+
fi
154+
155+
if [ -z "${CYCLE}" ]; then
156+
echo_info "No CYCLE number given ... defaulting to 0"
157+
CYCLE=0
158+
fi
150159

151160
# this generates an exact reproducer script for this job
152161
# that can be used locally for debugging etc.

0 commit comments

Comments
 (0)