12 return frag+
'_'+key+
'_'+step+suffix
15 return step+suffix+
'_'+key
19 for year
in upgradeKeys:
20 for i,key
in enumerate(upgradeKeys[year]):
21 numWF=numWFAll[year][i]
22 for frag,info
in upgradeFragments.items():
24 if (
"CE_E" in frag
or "CE_H" in frag)
and year==2017:
28 for specialType
in upgradeWFs.keys():
29 stepList[specialType] = []
31 for step
in upgradeProperties[year][key][
'ScenToRun']:
32 stepMaker = makeStepName
33 if 'Sim' in step
and 'Fast' not in step:
34 if 'HLBeamSpot' in step:
36 step =
'GenSimHLBeamSpot14' 37 if 'CloseByParticle' in frag
or 'CE_E' in frag
or 'CE_H' in frag:
38 step =
'GenSimHLBeamSpotHGCALCloseBy' 39 stepMaker = makeStepNameSim
41 stepMaker = makeStepNameSim
43 if 'HARVEST' in step: hasHarvest =
True 45 for specialType,specialWF
in upgradeWFs.items():
46 if (specialType !=
'baseline')
and ( (
'PU' in step
and step.replace(
'PU',
'')
in specialWF.PU)
or (step
in specialWF.steps) ):
47 stepList[specialType].
append(stepMaker(key,frag[:-4],step,specialWF.suffix))
49 if 'ProdLike' in specialType:
51 stepWoFakeHLT = step.replace(
'FakeHLT',
'')
52 stepList[specialType].
append(stepMaker(key,frag[:-4],stepWoFakeHLT.replace(
'RecoGlobal',
'MiniAOD').
replace(
'RecoNano',
'MiniAOD').
replace(
'Reco',
'MiniAOD'),specialWF.suffix))
53 if 'RecoNano' in stepWoFakeHLT:
54 stepList[specialType].
append(stepMaker(key,frag[:-4],stepWoFakeHLT.replace(
'RecoNano',
'Nano'),specialWF.suffix))
56 if 'HLT75e33' in specialType:
57 if 'RecoGlobal' in step:
58 stepList[specialType].
append(stepMaker(key,frag[:-4],step.replace(
'RecoGlobal',
'HLT75e33'),specialWF.suffix))
60 if 'PMX' in specialType:
62 s = step.replace(
'GenSim',
'Premix')+
'PU' 63 if step
in specialWF.PU:
64 stepMade = stepMaker(key,
'PREMIX',s,specialWF.suffix)
66 if 'S2' in specialType: stepList[specialType].
append(stepMade)
68 else: stepList[specialType][-1] = stepMade
70 stepList[specialType].
append(stepMaker(key,frag[:-4],step,
''))
72 for specialType,specialWF
in upgradeWFs.items():
74 if specialType==
"PMXS1":
75 stepList[specialType] = stepList[specialType][:1]
76 specialWF.workflow(workflows, numWF, info.dataset, stepList[specialType], key, hasHarvest)
def makeStepName(key, frag, step, suffix)
def replace(string, replacements)
portabletest::Matrix Matrix
def makeStepNameSim(key, frag, step, suffix)