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 TrackerDTCCablingRecord = "TrackerDetToDTCELinkCablingMapRcd"
11 
12 #combines in a single dict of dict the tags defined below
13 allTags={}
14 
15 
16 allTags["DTCCabling"] = {
17  "T6" : ( ','.join( [ 'TrackerDetToDTCELinkCablingMap__OT614_200_IT404_layer2_10G__T6__OTOnly' ,TrackerDTCCablingRecord, connectionString, "", "2020-03-27 11:30:00.000"] ), ), # DTC cabling map provided for T6 geometry (taken from http://ghugo.web.cern.ch/ghugo/layouts/cabling/OT614_200_IT404_layer2_10G/cablingOuter.html)
18 }
19 
20 #v5 versions of LA used to match versioning of pixel templates, but values are identical to v2
21 allTags["LA"] = {
22  'T6' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T6_v5_mc' ,SiPixelLARecord,connectionString, "", "2020-05-05 20:00:00.000"] ), ), #uH = 0.106/T (TBPX), uH=0.0/T (TEPX+TFPX)
23  'T14' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T14_v5_mc' ,SiPixelLARecord,connectionString, "", "2020-05-05 20:00:00.000"] ), ), #uH = 0.106/T (TBPX), uH=0.0/T (TEPX+TFPX)
24  '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)
25  'T19' : ( ','.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)
26 }
27 
28 allTags["LAWidth"] = {
29  'T6' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T6_mc_forWidthEmpty' ,SiPixelLARecord,connectionString, "forWidth", "2019-11-05 20:00:00.000"] ), ), # uH=0.0/T (fall-back to offset)
30  'T14' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T14_mc_forWidthEmpty' ,SiPixelLARecord,connectionString, "forWidth", "2019-11-05 20:00:00.000"] ), ), # uH=0.0/T (fall-back to offset)
31  '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)
32  'T19' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T19_mc_forWidthEmpty' ,SiPixelLARecord,connectionString, "forWidth", "2020-02-23 14:00:00.000"] ), ), # uH=0.0/T (fall-back to offset)
33 }
34 
35 allTags["LAfromAlignment"] = {
36  'T6' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T6_mc_forWidthEmpty' ,SiPixelLARecord,connectionString, "fromAlignment", "2019-11-05 20:00:00.000"] ), ), # uH=0.0/T (not in use)
37  'T14' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T14_mc_forWidthEmpty' ,SiPixelLARecord,connectionString, "fromAlignment", "2019-11-05 20:00:00.000"] ), ), # uH=0.0/T (not in use)
38  'T15' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T15_mc_forWidthEmpty' ,SiPixelLARecord,connectionString, "fromAlignment", "2019-11-05 20:00:00.000"] ), ), # uH=0.0/T (not in use)
39  'T19' : ( ','.join( [ 'SiPixelLorentzAngle_phase2_T19_mc_forWidthEmpty' ,SiPixelLARecord,connectionString, "fromAlignment", "2020-02-23 14:00:00.000"] ), ), # uH=0.0/T (not in use)
40 }
41 
42 #v5 versions of SimLA used to match versioning of pixel templates, but values are indentical to v2
43 allTags["SimLA"] = {
44  'T6' : ( ','.join( [ 'SiPixelSimLorentzAngle_phase2_T6_v5_mc' ,SiPixelSimLARecord,connectionString, "", "2020-05-05 20:00:00.000"] ), ), #uH = 0.106/T (TBPX), uH=0.0/T (TEPX+TFPX)
45  'T14' : ( ','.join( [ 'SiPixelSimLorentzAngle_phase2_T14_v5_mc' ,SiPixelSimLARecord,connectionString, "", "2020-05-05 20:00:00.000"] ), ), #uH = 0.106/T (TBPX), uH=0.0/T (TEPX+TFPX)
46  '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)
47  'T19' : ( ','.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)
48 }
49 
50 allTags["GenError"] = {
51  'T6' : ( ','.join( [ 'SiPixelGenErrorDBObject_phase2_T6_v5_mc' ,SiPixelGenErrorRecord,connectionString, "", "2020-05-02 23:00:00.000"] ), ), # cell is 25um (local-x) x 100um (local-y) , VBias=350V
52  'T14' : ( ','.join( [ 'SiPixelGenErrorDBObject_phase2_T14_v5_mc' ,SiPixelGenErrorRecord,connectionString, "", "2020-05-02 23:00:00.000"] ), ), # cell is 25um (local-x) x 100um (local-y) , VBias=350V
53  'T15' : ( ','.join( [ 'SiPixelGenErrorDBObject_phase2_T15_v5_mc' ,SiPixelGenErrorRecord,connectionString, "", "2020-05-02 23:00:00.000"] ), ), # cell is 25um (local-x) x 100um (local-y) , VBias=350V
54 }
55 
56 allTags["Template"] = {
57  'T6' : ( ','.join( [ 'SiPixelTemplateDBObject_phase2_T6_v5_mc' ,SiPixelTemplatesRecord,connectionString, "", "2020-05-02 23:00:00.000"] ), ), # cell is 25um (local-x) x 100um (local-y) , VBias=350V
58  'T14' : ( ','.join( [ 'SiPixelTemplateDBObject_phase2_T14_v5_mc',SiPixelTemplatesRecord,connectionString, "", "2020-05-02 23:00:00.000"] ), ), # cell is 25um (local-x) x 100um (local-y) , VBias=350V
59  'T15' : ( ','.join( [ 'SiPixelTemplateDBObject_phase2_T15_v5_mc',SiPixelTemplatesRecord,connectionString, "", "2020-05-02 23:00:00.000"] ), ), # cell is 25um (local-x) x 100um (local-y) , VBias=350V
60 }
61 
62 
65 
66 allTags["Template2Dnum"] = {
67  'T6' : ( ','.join( [ 'SiPixel2DTemplateDBObject_phase2_T6_v0_num' ,SiPixel2DTemplatesRecord,connectionString, "numerator", "2019-07-15 12:00:00.000"] ), ),
68  'T14' : ( ','.join( [ 'SiPixel2DTemplateDBObject_phase2_T14_v0_num' ,SiPixel2DTemplatesRecord,connectionString, "numerator", "2019-07-15 12:00:00.000"] ), ),
69  'T15' : ( ','.join( [ 'SiPixel2DTemplateDBObject_phase2_T15_v0_num' ,SiPixel2DTemplatesRecord,connectionString, "numerator", "2019-07-15 12:00:00.000"] ), ),
70 }
71 
72 allTags["Template2Dden"] = {
73  'T6' : ( ','.join( [ 'SiPixel2DTemplateDBObject_phase2_T6_v0_den' ,SiPixel2DTemplatesRecord,connectionString, "denominator", "2019-07-15 12:00:00.000"] ), ),
74  'T14' : ( ','.join( [ 'SiPixel2DTemplateDBObject_phase2_T14_v0_den' ,SiPixel2DTemplatesRecord,connectionString, "denominator", "2019-07-15 12:00:00.000"] ), ),
75  'T15' : ( ','.join( [ 'SiPixel2DTemplateDBObject_phase2_T15_v0_den' ,SiPixel2DTemplatesRecord,connectionString, "denominator", "2019-07-15 12:00:00.000"] ), ),
76 }
77 
78 # list of active tags to be replaced
79 activeKeys = ["DTCCabling","LA","LAWidth","SimLA","LAfromAlignment","GenError","Template"]
80 
81 # list of geometries supported
82 activeDets = ["T6","T14","T15","T19"]
83 phase2GTs = {}
84 for det in activeDets:
85  appendedTags = ()
86  for key in activeKeys:
87  if (det in allTags[key]):
88  appendedTags += allTags[key][det]
89  else :
90  pass
91  phase2GTs["phase2_realistic_"+det] = ('phase2_realistic', appendedTags)
92 
93 # method called in autoCond
94 def autoCondPhase2(autoCond):
95  for key,val in six.iteritems(phase2GTs):
96  if len(val)==1 :
97  autoCond[key] = ( autoCond[val[0]] )
98  else:
99  autoCond[key] = ( autoCond[val[0]],) + val[1]
100 
101  return autoCond
join
static std::string join(char **cmd)
Definition: RemoteFile.cc:17
autoCondPhase2.autoCondPhase2
def autoCondPhase2(autoCond)
As Outer Tracker in T6 is different from all the subsequent active ones (>=T14), this needs to be spe...
Definition: autoCondPhase2.py:94
CondDBESSource_cff