@@ -457,14 +457,18 @@ def getDPL_global_options(bigshm=False):
457457
458458 simsoption = ' --sims ' + ('bkg,' + signalprefix if doembedding else signalprefix )
459459
460+ # each digitization should be done for a different bunch crossing range, depending on the timeframe id
461+ orbitsPerTF = 256
462+ startOrbit = (tf - 1 )* orbitsPerTF
463+ globaldigitizeroptions = '--configKeyValues "HBFUtils.orbitFirstSampled=' + str (startOrbit ) \
464+ + ';HBFUtils.nHBFPerTF=' + str (orbitsPerTF ) + '"'
465+
460466 # This task creates the basic setup for all digitizers! all digitization configKeyValues need to be given here
461- # ContextTask=createTask(name='digicontext_'+str(tf), needs=[SGNtask['name'], LinkGRPFileTask['name']], tf=tf,
462- # cwd=timeframeworkdir, lab=["DIGI"], cpu='1')
463- # ContextTask['cmd'] = 'o2-sim-digitizer-workflow --only-context --interactionRate ' + str(INTRATE) + ' ' + getDPL_global_options() + ' -n ' + str(args.ns) + simsoption
464- # workflow['stages'].append(ContextTask)
465467 ContextTask = createTask (name = 'digicontext_' + str (tf ), needs = [SGNtask ['name' ], LinkGRPFileTask ['name' ]], tf = tf , cwd = timeframeworkdir , lab = ["DIGI" ], cpu = '1' )
466468 # this is just to have the digitizer ini file
467- ContextTask ['cmd' ] = 'o2-sim-digitizer-workflow --only-context --interactionRate ' + str (INTRATE ) + ' ' + getDPL_global_options () + ' -n ' + str (args .ns ) + simsoption
469+ ContextTask ['cmd' ] = 'o2-sim-digitizer-workflow --only-context --interactionRate ' + str (INTRATE ) \
470+ + ' ' + getDPL_global_options () + ' -n ' + str (args .ns ) + simsoption \
471+ + ' ' + globaldigitizeroptions
468472
469473 # in case of embedding we engineer the context directly and allow the user to provide an embedding pattern
470474 # The :r flag means to shuffle the background events randomly
0 commit comments