CMS 3D CMS Logo

autoAlca.py
Go to the documentation of this file.
1 AlCaRecoMatrix = {
2  "AlCaLumiPixelsCountsExpress" : "AlCaPCCRandom",
3  "AlCaLumiPixelsCountsPrompt" : "AlCaPCCZeroBias+RawPCCProducer",
4  # These two (AlCaPhiSym, AlCaP0) cannot run on RAW, they are just meant to run on the dedicated AlcaRAW so they do not enter the allForPrompt list
5  "AlCaPhiSym" : "",
6  "AlCaP0" : "",
7  "AlCaPPSExpress" : "PPSCalMaxTracks", # Express producer
8  "AlCaPPSPrompt" : "PPSCalMaxTracks", # Prompt producer
9  "Commissioning" : "HcalCalIsoTrk+TkAlMinBias+SiStripCalMinBias+HcalCalIsolatedBunchSelector",
10  "Cosmics" : "SiPixelCalCosmics+SiStripCalCosmics+TkAlCosmics0T+MuAlGlobalCosmics",
11  "DoubleMuon" : "TkAlZMuMu+TkAlDiMuonAndVertex+MuAlCalIsolatedMu",
12  "DoubleMuonLowMass" : "TkAlJpsiMuMu+TkAlUpsilonMuMu",
13  "EGamma" : "EcalESAlign+EcalUncalWElectron+EcalUncalZElectron+HcalCalIsoTrkProducerFilter+HcalCalIterativePhiSym",
14  "Express" : "SiStripCalZeroBias+TkAlMinBias+SiStripPCLHistos+SiStripCalMinBias+SiStripCalMinBiasAAG+Hotline+SiPixelCalZeroBias",
15  "ExpressAlignment" : "TkAlMinBias",
16  "ExpressCosmics" : "SiStripPCLHistos+SiStripCalZeroBias+TkAlCosmics0T+SiPixelCalZeroBias+SiPixelCalCosmics",
17  "HcalNZS" : "HcalCalMinBias",
18  "HLTPhysics" : "TkAlMinBias",
19  "JetHT" : "HcalCalIsoTrkProducerFilter+TkAlJetHT",
20  "JetMET" : "HcalCalIsoTrkProducerFilter+TkAlJetHT+HcalCalNoise",
21  "MinimumBias" : "SiStripCalZeroBias+SiStripCalMinBias+TkAlMinBias",
22  "MET" : "HcalCalNoise",
23  "Muon" : "TkAlZMuMu+TkAlDiMuonAndVertex+MuAlCalIsolatedMu+SiPixelCalSingleMuonLoose+SiPixelCalSingleMuonTight+TkAlMuonIsolated+HcalCalHO+HcalCalIterativePhiSym+HcalCalHBHEMuonProducerFilter",
24  "NoBPTX" : "TkAlCosmicsInCollisions",
25  "ParkingDoubleMuonLowMass" : "TkAlJpsiMuMu+TkAlUpsilonMuMu",
26  "SingleMuon" : "SiPixelCalSingleMuonLoose+SiPixelCalSingleMuonTight+TkAlMuonIsolated+MuAlCalIsolatedMu+HcalCalHO+HcalCalIterativePhiSym+HcalCalHBHEMuonProducerFilter",
27  "SpecialHLTPhysics" : "LumiPixelsMinBias",
28  "StreamExpress" : "SiStripCalZeroBias+TkAlMinBias+SiStripPCLHistos+SiStripCalMinBias+SiStripCalMinBiasAAG+Hotline+SiPixelCalZeroBias+SiPixelCalSingleMuon",
29  "StreamExpressHI" : "SiStripCalZeroBias+TkAlMinBiasHI+SiStripPCLHistos+SiStripCalMinBias+SiStripCalMinBiasAAG+SiPixelCalZeroBias",
30  # These (TestEnablesTracker, TestEnablesEcalHcal) are in the AlCaRecoMatrix, but no RelVals are produced
31  # 'TestEnablesTracker' : 'TkAlLAS'
32  # 'TestEnablesEcalHcal' : 'HcalCalPedestal'
33  "ZeroBias" : "HcalCalIsolatedBunchSelector+SiStripCalZeroBias+TkAlMinBias+SiStripCalMinBias",
34  }
35 
36 
37 def buildList(pdList, matrix):
38  """Takes a list of primary datasets (PDs) and the AlCaRecoMatrix (a dictinary) and returns a string with all the AlCaRecos for the selected PDs separated by the '+' character without duplicates."""
39  alCaRecoList = []
40  for pd in pdList:
41  alCaRecoList.extend(matrix[pd].split("+"))
42  # remove duplicates converting to a set
43  alCaRecoList = set(alCaRecoList)
44  stringList = ''
45  for alCaReco in alCaRecoList:
46  if stringList == '':
47  stringList += alCaReco
48  else:
49  stringList += '+'+alCaReco
50  return stringList
51 
52 # Update the lists anytime a new PD is added to the matrix
53 autoAlca = { 'allForPrompt' : buildList(['Commissioning', 'EGamma', 'HLTPhysics', 'HcalNZS', 'JetMET', 'Muon', 'NoBPTX', 'ParkingDoubleMuonLowMass', 'ZeroBias'], AlCaRecoMatrix),
54  'allForExpress' : buildList(['StreamExpress'], AlCaRecoMatrix),
55  'allForExpressHI' : buildList(['StreamExpressHI'], AlCaRecoMatrix),
56  'allForPromptCosmics' : buildList(['Cosmics'], AlCaRecoMatrix),
57  'allForExpressCosmics' : buildList(['ExpressCosmics'], AlCaRecoMatrix) }
58 autoAlca.update(AlCaRecoMatrix)
59 
60 # list of AlCa sequences that have modules that do not support concurrent LuminosityBlocks
61 AlCaNoConcurrentLumis = [
62  'PromptCalibProd', # AlcaBeamSpotProducer
63  'PromptCalibProdSiPixelAli', # AlignmentProducerAsAnalyzer, MillePedeFileConverter
64  'PromptCalibProdBeamSpotHP', # AlcaBeamSpotProducer
65  'PromptCalibProdBeamSpotHPLowPU', # AlcaBeamSpotProducer
66 ]
def buildList(pdList, matrix)
Definition: autoAlca.py:37