CMS 3D CMS Logo

autoCondPhase2.py
Go to the documentation of this file.
1 import six
2 from Configuration.StandardSequences.CondDBESSource_cff import GlobalTag as essource
3 connectionString = essource.connect.value()
4 
5 SiPixelLARecord = "SiPixelLorentzAngleRcd"
6 SiPixelSimLARecord = "SiPixelLorentzAngleSimRcd"
7 SiPixelGenErrorRecord = "SiPixelGenErrorDBObjectRcd"
8 SiPixelTemplatesRecord = "SiPixelTemplateDBObjectRcd"
9 SiPixel2DTemplatesRecord = "SiPixel2DTemplateDBObjectRcd"
10 TrackerLARecord = "SiPhase2OuterTrackerLorentzAngleRcd"
11 TrackerSimLARecord = "SiPhase2OuterTrackerLorentzAngleSimRcd"
12 
13 
22 
23 #combines in a single dict of dict the tags defined below
24 allTags={}
25 
26 allTags["LA"] = {
27  'T15' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T15_v5_mc' ,SiPixelLARecord,connectionString, "", "2020-05-05 20:00:00.000"] ), ), #uH = 0.053/T (TBPX), uH=0.0/T (TEPX+TFPX)
28  'T21' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T15_v5_mc' ,SiPixelLARecord,connectionString, "", "2020-05-05 20:00:00.000"] ), ), #uH = 0.053/T (TBPX), uH=0.0/T (TEPX+TFPX)
29  'T22' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T15_v5_mc' ,SiPixelLARecord,connectionString, "", "2020-05-05 20:00:00.000"] ), ), #uH = 0.053/T (TBPX), uH=0.0/T (TEPX+TFPX)
30  'T23' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T19_v1_mc' ,SiPixelLARecord,connectionString, "", "2020-02-23 14:00:00.000"] ), ), #uH = 0.053/T (TBPX L3,L4), uH=0.0/T (TBPX L1,L2, TEPX+TFPX)
31 }
32 
33 allTags["LAWidth"] = {
34  'T15' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T15_mc_forWidthEmpty' ,SiPixelLARecord,connectionString, "forWidth", "2019-11-05 20:00:00.000"] ), ), # uH=0.0/T (fall-back to offset)
35  'T21' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T15_mc_forWidthEmpty' ,SiPixelLARecord,connectionString, "forWidth", "2019-11-05 20:00:00.000"] ), ), # uH=0.0/T (fall-back to offset)
36  'T22' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T15_mc_forWidthEmpty' ,SiPixelLARecord,connectionString, "forWidth", "2019-11-05 20:00:00.000"] ), ), # uH=0.0/T (fall-back to offset)
37  'T23' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T19_mc_forWidthEmpty' ,SiPixelLARecord,connectionString, "forWidth", "2020-02-23 14:00:00.000"] ), ), # uH=0.0/T (fall-back to offset)
38 }
39 
40 allTags["LAfromAlignment"] = {
41  'T15' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T15_mc_forWidthEmpty' ,SiPixelLARecord,connectionString, "fromAlignment", "2019-11-05 20:00:00.000"] ), ), # uH=0.0/T (not in use)
42  'T21' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T15_mc_forWidthEmpty' ,SiPixelLARecord,connectionString, "fromAlignment", "2019-11-05 20:00:00.000"] ), ), # uH=0.0/T (not in use)
43  'T22' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T15_mc_forWidthEmpty' ,SiPixelLARecord,connectionString, "fromAlignment", "2019-11-05 20:00:00.000"] ), ), # uH=0.0/T (not in use)
44  'T23' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T19_mc_forWidthEmpty' ,SiPixelLARecord,connectionString, "fromAlignment", "2020-02-23 14:00:00.000"] ), ), # uH=0.0/T (not in use)
45 }
46 
47 allTags["SimLA"] = {
48  'T15' : ( ','.join( [ 'SiPixelSimLorentzAngle_phase2_T15_v5_mc' ,SiPixelSimLARecord,connectionString, "", "2020-05-05 20:00:00.000"] ), ), #uH = 0.053/T (TBPX), uH=0.0/T (TEPX+TFPX)
49  'T21' : ( ','.join( [ 'SiPixelSimLorentzAngle_phase2_T15_v5_mc' ,SiPixelSimLARecord,connectionString, "", "2020-05-05 20:00:00.000"] ), ), #uH = 0.053/T (TBPX), uH=0.0/T (TEPX+TFPX)
50  'T22' : ( ','.join( [ 'SiPixelSimLorentzAngle_phase2_T15_v5_mc' ,SiPixelSimLARecord,connectionString, "", "2020-05-05 20:00:00.000"] ), ), #uH = 0.053/T (TBPX), uH=0.0/T (TEPX+TFPX)
51  'T23' : ( ','.join( [ 'SiPixelSimLorentzAngle_phase2_T19_v1_mc' ,SiPixelSimLARecord,connectionString, "", "2020-02-23 14:00:00.000"] ), ), #uH = 0.053/T (TBPX L3,L4), uH=0.0/T (TBPX L1,L2, TEPX+TFPX)
52 }
53 
54 allTags["GenError"] = {
55  'T15' : ( ','.join( [ 'SiPixelGenErrorDBObject_phase2_IT_v6.1.5_25x100_v2_mc' ,SiPixelGenErrorRecord,connectionString, "", "2020-10-16 10:00:00"] ), ), # cell is 25um (local-x) x 100um (local-y) , VBias=350V
56  'T21' : ( ','.join( [ 'SiPixelGenErrorDBObject_phase2_IT_v6.1.5_25x100_v2_mc',SiPixelGenErrorRecord,connectionString, "", "2020-10-16 10:00:00"] ), ), # cell is 25um (local-x) x 100um (local-y) , VBias=350V
57  'T22' : ( ','.join( [ 'SiPixelGenErrorDBObject_phase2_IT_v6.1.5_50x50_v4_mc' ,SiPixelGenErrorRecord,connectionString, "", "2020-10-19 23:00:00"] ), ), # cell is 50um (local-x) x 50um (local-y) , VBias=350V
58 }
59 
60 allTags["Template"] = {
61  'T15' : ( ','.join( [ 'SiPixelTemplateDBObject_phase2_IT_v6.1.5_25x100_v2_mc',SiPixelTemplatesRecord,connectionString, "", "2020-10-16 10:00:00"] ), ), # cell is 25um (local-x) x 100um (local-y) , VBias=350V
62  'T21' : ( ','.join( [ 'SiPixelTemplateDBObject_phase2_IT_v6.1.5_25x100_v2_mc',SiPixelTemplatesRecord,connectionString, "", "2020-10-16 10:00:00"] ), ), # cell is 25um (local-x) x 100um (local-y) , VBias=350V
63  'T22' : ( ','.join( [ 'SiPixelTemplateDBObject_phase2_IT_v6.1.5_50x50_v4_mc' ,SiPixelTemplatesRecord,connectionString, "", "2020-10-19 23:00:00"] ), ), # cell is 50um (local-x) x 50um (local-y) , VBias=350V
64 }
65 
66 
69 
70 '''
71 allTags["OTLA"] = {
72  'T15' : ( ','.join( [ 'SiPhase2OuterTrackerLorentzAngle_v0_mc' ,TrackerLARecord,connectionString, "", "2020-07-19 17:00:00.000"] ), ), #uH = 0.07/T
73  'T21' : ( ','.join( [ 'SiPhase2OuterTrackerLorentzAngle_v0_mc' ,TrackerLARecord,connectionString, "", "2020-07-19 17:00:00.000"] ), ), #uH = 0.07/T
74  'T22' : ( ','.join( [ 'SiPhase2OuterTrackerLorentzAngle_v0_mc' ,TrackerLARecord,connectionString, "", "2020-07-19 17:00:00.000"] ), ), #uH = 0.07/T
75  'T23' : ( ','.join( [ 'SiPhase2OuterTrackerLorentzAngle_v0_mc' ,TrackerLARecord,connectionString, "", "2020-07-19 17:00:00.000"] ), ), #uH = 0.07/T
76 }
77 
78 allTags["SimOTLA"] = {
79  'T15' : ( ','.join( [ 'SiPhase2OuterTrackerLorentzAngleSim_v0_mc' ,TrackerSimLARecord,connectionString, "", "2020-07-19 17:00:00.000"] ), ), #uH = 0.07/T
80  'T21' : ( ','.join( [ 'SiPhase2OuterTrackerLorentzAngleSim_v0_mc' ,TrackerSimLARecord,connectionString, "", "2020-07-19 17:00:00.000"] ), ), #uH = 0.07/T
81  'T22' : ( ','.join( [ 'SiPhase2OuterTrackerLorentzAngleSim_v0_mc' ,TrackerSimLARecord,connectionString, "", "2020-07-19 17:00:00.000"] ), ), #uH = 0.07/T
82  'T23' : ( ','.join( [ 'SiPhase2OuterTrackerLorentzAngleSim_v0_mc' ,TrackerSimLARecord,connectionString, "", "2020-07-19 17:00:00.000"] ), ), #uH = 0.07/T
83 }
84 '''
85 
88 
89 allTags["Template2Dnum"] = {
90  'T15' : ( ','.join( [ 'SiPixel2DTemplateDBObject_phase2_T15_v0_num' ,SiPixel2DTemplatesRecord,connectionString, "numerator", "2019-07-15 12:00:00.000"] ), ),
91 }
92 
93 allTags["Template2Dden"] = {
94  'T15' : ( ','.join( [ 'SiPixel2DTemplateDBObject_phase2_T15_v0_den' ,SiPixel2DTemplatesRecord,connectionString, "denominator", "2019-07-15 12:00:00.000"] ), ),
95 }
96 
97 # list of active tags to be replaced
98 activeKeys = ["LA","LAWidth","SimLA","LAfromAlignment","GenError","Template"]#,"SimOTLA","OTLA"]
99 
100 # list of geometries supported
101 activeDets = ["T15","T21","T22","T23"]
102 phase2GTs = {}
103 for det in activeDets:
104  appendedTags = ()
105  for key in activeKeys:
106  if (det in allTags[key]):
107  appendedTags += allTags[key][det]
108  else :
109  pass
110  phase2GTs["phase2_realistic_"+det] = ('phase2_realistic', appendedTags)
111 
112 # method called in autoCond
113 def autoCondPhase2(autoCond):
114  for key,val in six.iteritems(phase2GTs):
115  if len(val)==1 :
116  autoCond[key] = ( autoCond[val[0]] )
117  else:
118  autoCond[key] = ( autoCond[val[0]],) + val[1]
119 
120  return autoCond
join
static std::string join(char **cmd)
Definition: RemoteFile.cc:17
autoCondPhase2.autoCondPhase2
def autoCondPhase2(autoCond)
Active geometries: https://github.com/cms-sw/cmssw/blob/master/Configuration/Geometry/README....
Definition: autoCondPhase2.py:113
CondDBESSource_cff